From: Dmitry Baryshkov Date: Sat, 31 May 2008 15:16:54 +0000 (+0100) Subject: [ARM] 5072/1: corgi_pm: don't register devices on non-corgi machines X-Git-Tag: v2.6.27-rc1~1095^2^2~7^3~4 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=043fbc099af0fc0ec94112c7235b7544147149f4;p=linux-2.6 [ARM] 5072/1: corgi_pm: don't register devices on non-corgi machines Signed-off-by: Dmitry Baryshkov Acked-by: Richard Purdie Signed-off-by: Russell King --- diff --git a/arch/arm/mach-pxa/corgi_pm.c b/arch/arm/mach-pxa/corgi_pm.c index 53c4499ebd..e91c0f26c4 100644 --- a/arch/arm/mach-pxa/corgi_pm.c +++ b/arch/arm/mach-pxa/corgi_pm.c @@ -229,6 +229,10 @@ static int __devinit corgipm_init(void) { int ret; + if (!machine_is_corgi() && !machine_is_shepherd() + && !machine_is_husky()) + return -ENODEV; + corgipm_device = platform_device_alloc("sharpsl-pm", -1); if (!corgipm_device) return -ENOMEM;