summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-ux500/board-mop500.c
diff options
context:
space:
mode:
authorLee Jones <lee.jones@linaro.org>2012-02-06 11:22:25 -0800
committerArnd Bergmann <arnd@arndb.de>2012-02-13 06:31:44 +0000
commitb024a0c804356d90b13c072c8bbb444d9e745a66 (patch)
tree5e0ef411be516b6b9a176f0e9b84ccd665bdcd3e /arch/arm/mach-ux500/board-mop500.c
parenteda413c228e227d888bc13d210e7c4c6aa62a682 (diff)
downloadlinux-b024a0c804356d90b13c072c8bbb444d9e745a66.tar.gz
linux-b024a0c804356d90b13c072c8bbb444d9e745a66.tar.xz
linux-b024a0c804356d90b13c072c8bbb444d9e745a66.zip
ARM: ux500: move top level platform devices in sysfs to /sys/devices/socX
At the request of Arnd Bergmann this patch moves all SoC platform devices found in sysfs from /sys/devices/platform to /sys/devices/soc<SoCNum>/. It is believed as the devices are SoC specific and a /sys/devices/soc node has recently become available, that this would be a more appropriate place to display the data. Signed-off-by: Lee Jones <lee.jones@linaro.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mach-ux500/board-mop500.c')
-rw-r--r--arch/arm/mach-ux500/board-mop500.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/arm/mach-ux500/board-mop500.c b/arch/arm/mach-ux500/board-mop500.c
index f9ce2a1211c9..04afcdf8b0cf 100644
--- a/arch/arm/mach-ux500/board-mop500.c
+++ b/arch/arm/mach-ux500/board-mop500.c
@@ -610,6 +610,7 @@ static void __init mop500_init_machine(void)
{
struct device *parent = NULL;
int i2c0_devs;
+ int i;
mop500_gpio_keys[0].gpio = GPIO_PROX_SENSOR;
@@ -617,6 +618,9 @@ static void __init mop500_init_machine(void)
mop500_pins_init();
+ for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
+ mop500_platform_devs[i]->dev.parent = parent;
+
platform_add_devices(mop500_platform_devs,
ARRAY_SIZE(mop500_platform_devs));
@@ -639,11 +643,15 @@ static void __init snowball_init_machine(void)
{
struct device *parent = NULL;
int i2c0_devs;
+ int i;
parent = u8500_init_devices();
snowball_pins_init();
+ for (i = 0; i < ARRAY_SIZE(snowball_platform_devs); i++)
+ snowball_platform_devs[i]->dev.parent = parent;
+
platform_add_devices(snowball_platform_devs,
ARRAY_SIZE(snowball_platform_devs));
@@ -665,6 +673,7 @@ static void __init hrefv60_init_machine(void)
{
struct device *parent = NULL;
int i2c0_devs;
+ int i;
/*
* The HREFv60 board removed a GPIO expander and routed
@@ -677,6 +686,9 @@ static void __init hrefv60_init_machine(void)
hrefv60_pins_init();
+ for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
+ mop500_platform_devs[i]->dev.parent = parent;
+
platform_add_devices(mop500_platform_devs,
ARRAY_SIZE(mop500_platform_devs));