From 4311d9654c66b7cc7147035b8ec74f41ddffa650 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Thu, 23 Oct 2014 13:18:53 +0200 Subject: ARM: shmobile: armadillo800eva legacy: Add missing A3SP pm domain devices MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Commit 802a5639aa7041b2 ("ARM: shmobile: r8a7740: add A3SP pm domain support") added the A3SP power domain, but forgot to hook up the TPU, SDHI0/1, and MMCIF hardware blocks. Note: As the default PM QoS latency constraint for SDHI is only 100 µs (cfr. commit c419e611c3c59c0e ("tmio_mmc / PM: Use PM QoS latency constraint"), while DEFAULT_DEV_LATENCY_NS is 250000, suspend fails with -EBUSY, unless the constraint is increased first to more than 500 µs using e.g. echo 501 > /sys/devices/platform/sh_mobile_sdhi.0/power/pm_qos_resume_latency_us Signed-off-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm/mach-shmobile/board-armadillo800eva.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'arch/arm/mach-shmobile/board-armadillo800eva.c') diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index e70983534403..4bc202dd828a 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -1234,8 +1234,11 @@ static void __init eva_init(void) static struct pm_domain_device domain_devices[] __initdata = { { "A4LC", &lcdc0_device }, { "A4LC", &hdmi_lcdc_device }, + { "A3SP", &pwm_device }, + { "A3SP", &sdhi0_device }, + { "A3SP", &sh_mmcif_device }, }; - struct platform_device *usb = NULL; + struct platform_device *usb = NULL, *sdhi1 = NULL; regulator_register_always_on(0, "fixed-3.3V", fixed3v3_power_consumers, ARRAY_SIZE(fixed3v3_power_consumers), 3300000); @@ -1304,6 +1307,7 @@ static void __init eva_init(void) platform_device_register(&vcc_sdhi1); platform_device_register(&sdhi1_device); + sdhi1 = &sdhi1_device; } @@ -1324,6 +1328,8 @@ static void __init eva_init(void) ARRAY_SIZE(domain_devices)); if (usb) rmobile_add_device_to_domain("A3SP", usb); + if (sdhi1) + rmobile_add_device_to_domain("A3SP", sdhi1); r8a7740_pm_init(); } -- cgit v1.2.3 From 671c522a69fc6fa6960ada4c55bc7186f7d89a3a Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Thu, 23 Oct 2014 13:18:54 +0200 Subject: ARM: shmobile: armadillo800eva legacy: Add missing A4S pm domain devices Commit 8459293c27bcd13a ("ARM: shmobile: r8a7740: add A4S pm domain support") added the A4S power domain, but forgot to hook up the GbEther hardware block. Signed-off-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm/mach-shmobile/board-armadillo800eva.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/arm/mach-shmobile/board-armadillo800eva.c') diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index 4bc202dd828a..0aa5bbdbd153 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -1234,6 +1234,7 @@ static void __init eva_init(void) static struct pm_domain_device domain_devices[] __initdata = { { "A4LC", &lcdc0_device }, { "A4LC", &hdmi_lcdc_device }, + { "A4S", &sh_eth_device }, { "A3SP", &pwm_device }, { "A3SP", &sdhi0_device }, { "A3SP", &sh_mmcif_device }, -- cgit v1.2.3 From 77192e1e25a57a519df30015b29c046bd6a769fc Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Thu, 23 Oct 2014 13:18:57 +0200 Subject: ARM: shmobile: r8a7740/armadillo legacy: Add A4MP pm domain support Add support for the A4MP power domain, and hook up the HDMI-Link and FSI hardware blocks. This domain also contains the SPU2, FMSI, and BBIF2 hardware blocks, but these are currently not used by any driver. Signed-off-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm/mach-shmobile/board-armadillo800eva.c | 2 ++ arch/arm/mach-shmobile/pm-r8a7740.c | 3 +++ 2 files changed, 5 insertions(+) (limited to 'arch/arm/mach-shmobile/board-armadillo800eva.c') diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index 0aa5bbdbd153..e06444370a86 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -1234,6 +1234,8 @@ static void __init eva_init(void) static struct pm_domain_device domain_devices[] __initdata = { { "A4LC", &lcdc0_device }, { "A4LC", &hdmi_lcdc_device }, + { "A4MP", &hdmi_device }, + { "A4MP", &fsi_device }, { "A4S", &sh_eth_device }, { "A3SP", &pwm_device }, { "A3SP", &sdhi0_device }, diff --git a/arch/arm/mach-shmobile/pm-r8a7740.c b/arch/arm/mach-shmobile/pm-r8a7740.c index 932c2a621e81..081a4f9726a0 100644 --- a/arch/arm/mach-shmobile/pm-r8a7740.c +++ b/arch/arm/mach-shmobile/pm-r8a7740.c @@ -36,6 +36,9 @@ static struct rmobile_pm_domain r8a7740_pm_domains[] = { { .genpd.name = "A4LC", .bit_shift = 1, + }, { + .genpd.name = "A4MP", + .bit_shift = 2, }, { .genpd.name = "A3RV", .bit_shift = 6, -- cgit v1.2.3 From 1618a677046b0391621708734f56886233210047 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Thu, 23 Oct 2014 13:18:59 +0200 Subject: ARM: shmobile: r8a7740/armadillo legacy: Add A4R pm domain support Add support for the A4R power domain, and hook up the A3RV subdomain, and the CEU0, TMU0, and IIC0 hardware blocks. This domain also contains the Realtime CPU (SH-4A), Realtime CPU debug modules, H-UDI, RT-SHwy, INTCS, RT-HPB, VIO6C, JPU, RTDMAC1/2, SSP, MSIOF0, CMT0, ICB, DREQPAK (RT), 2DDMAC, IPMMUI, and 2DG hardware blocks, but these are currently not used by any driver. Signed-off-by: Simon Horman --- arch/arm/mach-shmobile/board-armadillo800eva.c | 1 + arch/arm/mach-shmobile/pm-r8a7740.c | 4 ++++ arch/arm/mach-shmobile/setup-r8a7740.c | 2 ++ 3 files changed, 7 insertions(+) (limited to 'arch/arm/mach-shmobile/board-armadillo800eva.c') diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index e06444370a86..25813dac77d9 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c @@ -1236,6 +1236,7 @@ static void __init eva_init(void) { "A4LC", &hdmi_lcdc_device }, { "A4MP", &hdmi_device }, { "A4MP", &fsi_device }, + { "A4R", &ceu0_device }, { "A4S", &sh_eth_device }, { "A3SP", &pwm_device }, { "A3SP", &sdhi0_device }, diff --git a/arch/arm/mach-shmobile/pm-r8a7740.c b/arch/arm/mach-shmobile/pm-r8a7740.c index 8b1af2a585ab..74e6a67a28d3 100644 --- a/arch/arm/mach-shmobile/pm-r8a7740.c +++ b/arch/arm/mach-shmobile/pm-r8a7740.c @@ -54,6 +54,9 @@ static struct rmobile_pm_domain r8a7740_pm_domains[] = { .bit_shift = 3, .gov = &pm_domain_always_on_gov, .suspend = r8a7740_pd_d4_suspend, + }, { + .genpd.name = "A4R", + .bit_shift = 5, }, { .genpd.name = "A3RV", .bit_shift = 6, @@ -78,6 +81,7 @@ static struct rmobile_pm_domain r8a7740_pm_domains[] = { void __init r8a7740_init_pm_domains(void) { rmobile_init_domains(r8a7740_pm_domains, ARRAY_SIZE(r8a7740_pm_domains)); + pm_genpd_add_subdomain_names("A4R", "A3RV"); pm_genpd_add_subdomain_names("A4S", "A3SP"); pm_genpd_add_subdomain_names("A4S", "A3SG"); } diff --git a/arch/arm/mach-shmobile/setup-r8a7740.c b/arch/arm/mach-shmobile/setup-r8a7740.c index dbf8a93ccc4f..b77c226ab891 100644 --- a/arch/arm/mach-shmobile/setup-r8a7740.c +++ b/arch/arm/mach-shmobile/setup-r8a7740.c @@ -746,6 +746,8 @@ static void r8a7740_i2c_workaround(struct platform_device *pdev) void __init r8a7740_add_standard_devices(void) { static struct pm_domain_device domain_devices[] __initdata = { + { "A4R", &tmu0_device }, + { "A4R", &i2c0_device }, { "A4S", &irqpin0_device }, { "A4S", &irqpin1_device }, { "A4S", &irqpin2_device }, -- cgit v1.2.3