Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: dts: Configure omap4 and 5 l4_abe for genpd and drop platform data

We can power off l4_abe domain when not in use when we configure it for
genpd. And with that change, we can now also drop the old unused legacy
platform data.

Note that we also need to now use "simple-pm-bus" instead of "simple-bus"
for PM runtime to get enabled for the bus.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Acked-by: Santosh Shilimkar <ssantosh@kernel.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>

+20 -68
+4 -2
arch/arm/boot/dts/omap4-l4-abe.dtsi
··· 1 1 &l4_abe { /* 0x40100000 */ 2 - compatible = "ti,omap4-l4-abe", "simple-bus"; 2 + compatible = "ti,omap4-l4-abe", "simple-pm-bus"; 3 3 reg = <0x40100000 0x400>, 4 4 <0x40100400 0x400>; 5 5 reg-names = "la", "ap"; 6 + power-domains = <&prm_abe>; 7 + /* OMAP4_L4_ABE_CLKCTRL is read-only */ 6 8 #address-cells = <1>; 7 9 #size-cells = <1>; 8 10 ranges = <0x00000000 0x40100000 0x100000>, /* segment 0 */ 9 11 <0x49000000 0x49000000 0x100000>; 10 12 segment@0 { /* 0x40100000 */ 11 - compatible = "simple-bus"; 13 + compatible = "simple-pm-bus"; 12 14 #address-cells = <1>; 13 15 #size-cells = <1>; 14 16 ranges =
+6
arch/arm/boot/dts/omap4.dtsi
··· 658 658 #reset-cells = <1>; 659 659 }; 660 660 661 + prm_abe: prm@500 { 662 + compatible = "ti,omap4-prm-inst", "ti,omap-prm-inst"; 663 + reg = <0x500 0x100>; 664 + #power-domain-cells = <0>; 665 + }; 666 + 661 667 prm_core: prm@700 { 662 668 compatible = "ti,omap4-prm-inst", "ti,omap-prm-inst"; 663 669 reg = <0x700 0x100>;
+4 -2
arch/arm/boot/dts/omap5-l4-abe.dtsi
··· 1 1 &l4_abe { /* 0x40100000 */ 2 - compatible = "ti,omap5-l4-abe", "simple-bus"; 2 + compatible = "ti,omap5-l4-abe", "simple-pm-bus"; 3 3 reg = <0x40100000 0x400>, 4 4 <0x40100400 0x400>; 5 5 reg-names = "la", "ap"; 6 + power-domains = <&prm_abe>; 7 + /* OMAP5_L4_ABE_CLKCTRL is read-only */ 6 8 #address-cells = <1>; 7 9 #size-cells = <1>; 8 10 ranges = <0x00000000 0x40100000 0x100000>, /* segment 0 */ 9 11 <0x49000000 0x49000000 0x100000>; 10 12 segment@0 { /* 0x40100000 */ 11 - compatible = "simple-bus"; 13 + compatible = "simple-pm-bus"; 12 14 #address-cells = <1>; 13 15 #size-cells = <1>; 14 16 ranges =
+6
arch/arm/boot/dts/omap5.dtsi
··· 674 674 #reset-cells = <1>; 675 675 }; 676 676 677 + prm_abe: prm@500 { 678 + compatible = "ti,omap5-prm-inst", "ti,omap-prm-inst"; 679 + reg = <0x500 0x100>; 680 + #power-domain-cells = <0>; 681 + }; 682 + 677 683 prm_core: prm@700 { 678 684 compatible = "ti,omap5-prm-inst", "ti,omap-prm-inst"; 679 685 reg = <0x700 0x100>;
-33
arch/arm/mach-omap2/omap_hwmod_44xx_data.c
··· 124 124 .name = "l4", 125 125 }; 126 126 127 - /* l4_abe */ 128 - static struct omap_hwmod omap44xx_l4_abe_hwmod = { 129 - .name = "l4_abe", 130 - .class = &omap44xx_l4_hwmod_class, 131 - .clkdm_name = "abe_clkdm", 132 - .prcm = { 133 - .omap4 = { 134 - .clkctrl_offs = OMAP4_CM1_ABE_L4ABE_CLKCTRL_OFFSET, 135 - .context_offs = OMAP4_RM_ABE_AESS_CONTEXT_OFFSET, 136 - .lostcontext_mask = OMAP4430_LOSTMEM_AESSMEM_MASK, 137 - .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 138 - }, 139 - }, 140 - }; 141 - 142 127 /* l4_cfg */ 143 128 static struct omap_hwmod omap44xx_l4_cfg_hwmod = { 144 129 .name = "l4_cfg", ··· 756 771 .user = OCP_USER_MPU | OCP_USER_SDMA, 757 772 }; 758 773 759 - /* l3_main_1 -> l4_abe */ 760 - static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_abe = { 761 - .master = &omap44xx_l3_main_1_hwmod, 762 - .slave = &omap44xx_l4_abe_hwmod, 763 - .clk = "l3_div_ck", 764 - .user = OCP_USER_MPU | OCP_USER_SDMA, 765 - }; 766 - 767 - /* mpu -> l4_abe */ 768 - static struct omap_hwmod_ocp_if omap44xx_mpu__l4_abe = { 769 - .master = &omap44xx_mpu_hwmod, 770 - .slave = &omap44xx_l4_abe_hwmod, 771 - .clk = "ocp_abe_iclk", 772 - .user = OCP_USER_MPU | OCP_USER_SDMA, 773 - }; 774 - 775 774 /* l3_main_1 -> l4_cfg */ 776 775 static struct omap_hwmod_ocp_if omap44xx_l3_main_1__l4_cfg = { 777 776 .master = &omap44xx_l3_main_1_hwmod, ··· 957 988 &omap44xx_l3_main_1__l3_main_3, 958 989 &omap44xx_l3_main_2__l3_main_3, 959 990 &omap44xx_l4_cfg__l3_main_3, 960 - &omap44xx_l3_main_1__l4_abe, 961 - &omap44xx_mpu__l4_abe, 962 991 &omap44xx_l3_main_1__l4_cfg, 963 992 &omap44xx_l3_main_2__l4_per, 964 993 &omap44xx_l4_cfg__l4_wkup,
-31
arch/arm/mach-omap2/omap_hwmod_54xx_data.c
··· 121 121 .name = "l4", 122 122 }; 123 123 124 - /* l4_abe */ 125 - static struct omap_hwmod omap54xx_l4_abe_hwmod = { 126 - .name = "l4_abe", 127 - .class = &omap54xx_l4_hwmod_class, 128 - .clkdm_name = "abe_clkdm", 129 - .prcm = { 130 - .omap4 = { 131 - .clkctrl_offs = OMAP54XX_CM_ABE_L4_ABE_CLKCTRL_OFFSET, 132 - .flags = HWMOD_OMAP4_NO_CONTEXT_LOSS_BIT, 133 - }, 134 - }, 135 - }; 136 - 137 124 /* l4_cfg */ 138 125 static struct omap_hwmod omap54xx_l4_cfg_hwmod = { 139 126 .name = "l4_cfg", ··· 382 395 .user = OCP_USER_MPU | OCP_USER_SDMA, 383 396 }; 384 397 385 - /* l3_main_1 -> l4_abe */ 386 - static struct omap_hwmod_ocp_if omap54xx_l3_main_1__l4_abe = { 387 - .master = &omap54xx_l3_main_1_hwmod, 388 - .slave = &omap54xx_l4_abe_hwmod, 389 - .clk = "abe_iclk", 390 - .user = OCP_USER_MPU | OCP_USER_SDMA, 391 - }; 392 - 393 - /* mpu -> l4_abe */ 394 - static struct omap_hwmod_ocp_if omap54xx_mpu__l4_abe = { 395 - .master = &omap54xx_mpu_hwmod, 396 - .slave = &omap54xx_l4_abe_hwmod, 397 - .clk = "abe_iclk", 398 - .user = OCP_USER_MPU | OCP_USER_SDMA, 399 - }; 400 - 401 398 /* l3_main_1 -> l4_cfg */ 402 399 static struct omap_hwmod_ocp_if omap54xx_l3_main_1__l4_cfg = { 403 400 .master = &omap54xx_l3_main_1_hwmod, ··· 449 478 &omap54xx_l3_main_1__l3_main_3, 450 479 &omap54xx_l3_main_2__l3_main_3, 451 480 &omap54xx_l4_cfg__l3_main_3, 452 - &omap54xx_l3_main_1__l4_abe, 453 - &omap54xx_mpu__l4_abe, 454 481 &omap54xx_l3_main_1__l4_cfg, 455 482 &omap54xx_l3_main_2__l4_per, 456 483 &omap54xx_l3_main_1__l4_wkup,