diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2008-04-24 15:13:36 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-06-02 13:49:14 +0100 |
commit | 720046de27ec2a96d4497dbca8ee98657efa059c (patch) | |
tree | 24d8fc344e16970be7cc4817a09f40c3bbd2ea73 /arch/arm | |
parent | 1a7e612fa5ea0311232bd5418a40ec7280557789 (diff) | |
download | linux-720046de27ec2a96d4497dbca8ee98657efa059c.tar.gz linux-720046de27ec2a96d4497dbca8ee98657efa059c.tar.bz2 linux-720046de27ec2a96d4497dbca8ee98657efa059c.zip |
[ARM] pxa: don't register lpd270 cpld_irq sysdev if !lpd270
Don't register the LPD270 cpld_irq system device when we're not running
on a LPD270 machine - "cpld_irq" is also registered (separately) by
Lubbock and Mainstone.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-pxa/lpd270.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/arch/arm/mach-pxa/lpd270.c b/arch/arm/mach-pxa/lpd270.c index a20e4b1649d6..6fd7b8b753fc 100644 --- a/arch/arm/mach-pxa/lpd270.c +++ b/arch/arm/mach-pxa/lpd270.c @@ -134,9 +134,12 @@ static struct sys_device lpd270_irq_device = { static int __init lpd270_irq_device_init(void) { - int ret = sysdev_class_register(&lpd270_irq_sysclass); - if (ret == 0) - ret = sysdev_register(&lpd270_irq_device); + int ret = -ENODEV; + if (machine_is_logicpd_pxa270()) { + ret = sysdev_class_register(&lpd270_irq_sysclass); + if (ret == 0) + ret = sysdev_register(&lpd270_irq_device); + } return ret; } |