diff options
author | Arnd Bergmann <arnd@arndb.de> | 2014-09-11 09:46:38 +0200 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2014-09-11 09:46:38 +0200 |
commit | 9136ce889254ed51a00a41194befee8ecb2eda36 (patch) | |
tree | 47bd95b2a1d9a881779f8ced5c0d74cda70680e8 /arch/arm/mach-shmobile | |
parent | c40c4028f048a077a8950fd95e5d8901f773a63f (diff) | |
parent | 834720dbf03819a8b2d0ba5fbe01d008267f9da6 (diff) |
Merge tag 'renesas-pm-cleanups-for-v3.18' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas into next/cleanup
Pull "Renesas ARM Based SoC PM Cleanups for v3.18" from Simon Horman:
* Make domain_devices[] static __initdata
* Add and use rmobile_add_devices_to_domain
Signed-off-by: Arnd Bergmann <ardn@arndb.de>
* tag 'renesas-pm-cleanups-for-v3.18' of git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas:
ARM: shmobile: armadillo800eva legacy: Use rmobile_add_devices_to_domains()
ARM: shmobile: r8a7740: Clean up pm domain table
ARM: shmobile: r8a7740: Use rmobile_add_devices_to_domains()
ARM: shmobile: sh7372: Make domain_devices[] static __initdata
ARM: shmobile: mackerel: Make domain_devices[] static __initdata
Diffstat (limited to 'arch/arm/mach-shmobile')
-rw-r--r-- | arch/arm/mach-shmobile/board-armadillo800eva.c | 8 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/board-mackerel.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/pm-r8a7740.c | 10 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/setup-r8a7740.c | 26 | ||||
-rw-r--r-- | arch/arm/mach-shmobile/setup-sh7372.c | 2 |
5 files changed, 27 insertions, 21 deletions
diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index 6dbaad611a92..e70983534403 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -1231,6 +1231,10 @@ clock_error: #define GPIO_PORT8CR IOMEM(0xe6050008) static void __init eva_init(void) { + static struct pm_domain_device domain_devices[] __initdata = { + { "A4LC", &lcdc0_device }, + { "A4LC", &hdmi_lcdc_device }, + }; struct platform_device *usb = NULL; regulator_register_always_on(0, "fixed-3.3V", fixed3v3_power_consumers, @@ -1316,8 +1320,8 @@ static void __init eva_init(void) platform_add_devices(eva_devices, ARRAY_SIZE(eva_devices)); - rmobile_add_device_to_domain("A4LC", &lcdc0_device); - rmobile_add_device_to_domain("A4LC", &hdmi_lcdc_device); + rmobile_add_devices_to_domains(domain_devices, + ARRAY_SIZE(domain_devices)); if (usb) rmobile_add_device_to_domain("A3SP", usb); diff --git a/arch/arm/mach-shmobile/board-mackerel.c b/arch/arm/mach-shmobile/board-mackerel.c index 79f448e93abb..d47b2623267b 100644 --- a/arch/arm/mach-shmobile/board-mackerel.c +++ b/arch/arm/mach-shmobile/board-mackerel.c @@ -1420,7 +1420,7 @@ static const struct pinctrl_map mackerel_pinctrl_map[] = { #define USCCR1 IOMEM(0xE6058144) static void __init mackerel_init(void) { - struct pm_domain_device domain_devices[] = { + static struct pm_domain_device domain_devices[] __initdata = { { "A4LC", &lcdc_device, }, { "A4LC", &hdmi_lcdc_device, }, { "A4LC", &meram_device, }, diff --git a/arch/arm/mach-shmobile/pm-r8a7740.c b/arch/arm/mach-shmobile/pm-r8a7740.c index a0d44d537fa0..3d507149a6c4 100644 --- a/arch/arm/mach-shmobile/pm-r8a7740.c +++ b/arch/arm/mach-shmobile/pm-r8a7740.c @@ -34,23 +34,21 @@ static int r8a7740_pd_a3sp_suspend(void) static struct rmobile_pm_domain r8a7740_pm_domains[] = { { + .genpd.name = "A4LC", + .bit_shift = 1, + }, { .genpd.name = "A4S", .bit_shift = 10, .gov = &pm_domain_always_on_gov, .no_debug = true, .suspend = r8a7740_pd_a4s_suspend, - }, - { + }, { .genpd.name = "A3SP", .bit_shift = 11, .gov = &pm_domain_always_on_gov, .no_debug = true, .suspend = r8a7740_pd_a3sp_suspend, }, - { - .genpd.name = "A4LC", - .bit_shift = 1, - }, }; void __init r8a7740_init_pm_domains(void) diff --git a/arch/arm/mach-shmobile/setup-r8a7740.c b/arch/arm/mach-shmobile/setup-r8a7740.c index 3d5eacaba3e6..30df532fcaa0 100644 --- a/arch/arm/mach-shmobile/setup-r8a7740.c +++ b/arch/arm/mach-shmobile/setup-r8a7740.c @@ -747,6 +747,19 @@ static void r8a7740_i2c_workaround(struct platform_device *pdev) void __init r8a7740_add_standard_devices(void) { + static struct pm_domain_device domain_devices[] __initdata = { + { "A3SP", &scif0_device }, + { "A3SP", &scif1_device }, + { "A3SP", &scif2_device }, + { "A3SP", &scif3_device }, + { "A3SP", &scif4_device }, + { "A3SP", &scif5_device }, + { "A3SP", &scif6_device }, + { "A3SP", &scif7_device }, + { "A3SP", &scif8_device }, + { "A3SP", &i2c1_device }, + }; + /* I2C work-around */ r8a7740_i2c_workaround(&i2c0_device); r8a7740_i2c_workaround(&i2c1_device); @@ -762,17 +775,8 @@ void __init r8a7740_add_standard_devices(void) ARRAY_SIZE(r8a7740_late_devices)); /* add devices to PM domain */ - - rmobile_add_device_to_domain("A3SP", &scif0_device); - rmobile_add_device_to_domain("A3SP", &scif1_device); - rmobile_add_device_to_domain("A3SP", &scif2_device); - rmobile_add_device_to_domain("A3SP", &scif3_device); - rmobile_add_device_to_domain("A3SP", &scif4_device); - rmobile_add_device_to_domain("A3SP", &scif5_device); - rmobile_add_device_to_domain("A3SP", &scif6_device); - rmobile_add_device_to_domain("A3SP", &scif7_device); - rmobile_add_device_to_domain("A3SP", &scif8_device); - rmobile_add_device_to_domain("A3SP", &i2c1_device); + rmobile_add_devices_to_domains(domain_devices, + ARRAY_SIZE(domain_devices)); } void __init r8a7740_add_early_devices(void) diff --git a/arch/arm/mach-shmobile/setup-sh7372.c b/arch/arm/mach-shmobile/setup-sh7372.c index 9cdfcdfd38fc..a04fa5fd00fd 100644 --- a/arch/arm/mach-shmobile/setup-sh7372.c +++ b/arch/arm/mach-shmobile/setup-sh7372.c @@ -927,7 +927,7 @@ static struct platform_device *sh7372_late_devices[] __initdata = { void __init sh7372_add_standard_devices(void) { - struct pm_domain_device domain_devices[] = { + static struct pm_domain_device domain_devices[] __initdata = { { "A3RV", &vpu_device, }, { "A4MP", &spu0_device, }, { "A4MP", &spu1_device, }, |