projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ARM: imx: Provide correct number of resources when registering gpio devices
[linux-2.6-microblaze.git]
/
arch
/
arm
/
mach-imx
/
devices
/
platform-gpio-mxc.c
diff --git
a/arch/arm/mach-imx/devices/platform-gpio-mxc.c
b/arch/arm/mach-imx/devices/platform-gpio-mxc.c
index
78628ef
..
355de84
100644
(file)
--- a/
arch/arm/mach-imx/devices/platform-gpio-mxc.c
+++ b/
arch/arm/mach-imx/devices/platform-gpio-mxc.c
@@
-24,7
+24,8
@@
struct platform_device *__init mxc_register_gpio(char *name, int id,
.flags = IORESOURCE_IRQ,
},
};
.flags = IORESOURCE_IRQ,
},
};
+ unsigned int nres;
- return platform_device_register_resndata(&mxc_aips_bus,
-
name, id, res, ARRAY_SIZE(res)
, NULL, 0);
+ nres = irq_high ? ARRAY_SIZE(res) : ARRAY_SIZE(res) - 1;
+
return platform_device_register_resndata(&mxc_aips_bus, name, id, res, nres
, NULL, 0);
}
}