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

ARM: OMAP2+: Drop legacy platform data for dra7 dwc3

We can now probe devices with ti-sysc interconnect driver and dts
data. Let's drop the related platform data and custom ti,hwmods
dts property.

As we're just dropping data, and the early platform data init
is based on the custom ti,hwmods property, we want to drop both
the platform data and ti,hwmods property in a single patch.

Signed-off-by: Tony Lindgren <tony@atomide.com>

+41 -176
-4
arch/arm/boot/dts/dra7-l4.dtsi
··· 4007 4007 4008 4008 target-module@80000 { /* 0x48880000, ap 83 0e.1 */ 4009 4009 compatible = "ti,sysc-omap4", "ti,sysc"; 4010 - ti,hwmods = "usb_otg_ss1"; 4011 4010 reg = <0x80000 0x4>, 4012 4011 <0x80010 0x4>; 4013 4012 reg-names = "rev", "sysc"; ··· 4056 4057 4057 4058 target-module@c0000 { /* 0x488c0000, ap 79 06.0 */ 4058 4059 compatible = "ti,sysc-omap4", "ti,sysc"; 4059 - ti,hwmods = "usb_otg_ss2"; 4060 4060 reg = <0xc0000 0x4>, 4061 4061 <0xc0010 0x4>; 4062 4062 reg-names = "rev", "sysc"; ··· 4106 4108 4107 4109 usb3_tm: target-module@100000 { /* 0x48900000, ap 85 04.0 */ 4108 4110 compatible = "ti,sysc-omap4", "ti,sysc"; 4109 - ti,hwmods = "usb_otg_ss3"; 4110 4111 reg = <0x100000 0x4>, 4111 4112 <0x100010 0x4>; 4112 4113 reg-names = "rev", "sysc"; ··· 4154 4157 4155 4158 usb4_tm: target-module@140000 { /* 0x48940000, ap 75 3c.0 */ 4156 4159 compatible = "ti,sysc-omap4", "ti,sysc"; 4157 - ti,hwmods = "usb_otg_ss4"; 4158 4160 reg = <0x140000 0x4>, 4159 4161 <0x140010 0x4>; 4160 4162 reg-names = "rev", "sysc";
+39 -19
arch/arm/boot/dts/dra74x.dtsi
··· 49 49 reg = <0x41500000 0x100>; 50 50 }; 51 51 52 - omap_dwc3_4: omap_dwc3_4@48940000 { 53 - compatible = "ti,dwc3"; 54 - ti,hwmods = "usb_otg_ss4"; 55 - reg = <0x48940000 0x10000>; 56 - interrupts = <GIC_SPI 346 IRQ_TYPE_LEVEL_HIGH>; 52 + target-module@48940000 { 53 + compatible = "ti,sysc-omap4", "ti,sysc"; 54 + reg = <0x48940000 0x4>, 55 + <0x48940010 0x4>; 56 + reg-names = "rev", "sysc"; 57 + ti,sysc-mask = <SYSC_OMAP4_DMADISABLE>; 58 + ti,sysc-midle = <SYSC_IDLE_FORCE>, 59 + <SYSC_IDLE_NO>, 60 + <SYSC_IDLE_SMART>, 61 + <SYSC_IDLE_SMART_WKUP>; 62 + ti,sysc-sidle = <SYSC_IDLE_FORCE>, 63 + <SYSC_IDLE_NO>, 64 + <SYSC_IDLE_SMART>, 65 + <SYSC_IDLE_SMART_WKUP>; 66 + clocks = <&l3init_clkctrl DRA7_L3INIT_USB_OTG_SS4_CLKCTRL 0>; 67 + clock-names = "fck"; 57 68 #address-cells = <1>; 58 69 #size-cells = <1>; 59 - utmi-mode = <2>; 60 - ranges; 61 - status = "disabled"; 62 - usb4: usb@48950000 { 63 - compatible = "snps,dwc3"; 64 - reg = <0x48950000 0x17000>; 65 - interrupts = <GIC_SPI 345 IRQ_TYPE_LEVEL_HIGH>, 66 - <GIC_SPI 345 IRQ_TYPE_LEVEL_HIGH>, 67 - <GIC_SPI 346 IRQ_TYPE_LEVEL_HIGH>; 68 - interrupt-names = "peripheral", 69 - "host", 70 - "otg"; 71 - maximum-speed = "high-speed"; 72 - dr_mode = "otg"; 70 + ranges = <0x0 0x48940000 0x20000>; 71 + 72 + omap_dwc3_4: omap_dwc3_4@0 { 73 + compatible = "ti,dwc3"; 74 + reg = <0 0x10000>; 75 + interrupts = <GIC_SPI 346 IRQ_TYPE_LEVEL_HIGH>; 76 + #address-cells = <1>; 77 + #size-cells = <1>; 78 + utmi-mode = <2>; 79 + ranges; 80 + status = "disabled"; 81 + usb4: usb@10000 { 82 + compatible = "snps,dwc3"; 83 + reg = <0x10000 0x17000>; 84 + interrupts = <GIC_SPI 345 IRQ_TYPE_LEVEL_HIGH>, 85 + <GIC_SPI 345 IRQ_TYPE_LEVEL_HIGH>, 86 + <GIC_SPI 346 IRQ_TYPE_LEVEL_HIGH>; 87 + interrupt-names = "peripheral", 88 + "host", 89 + "otg"; 90 + maximum-speed = "high-speed"; 91 + dr_mode = "otg"; 92 + }; 73 93 }; 74 94 }; 75 95
+2 -153
arch/arm/mach-omap2/omap_hwmod_7xx_data.c
··· 492 492 }; 493 493 494 494 /* 495 - * 'usb_otg_ss' class 496 - * 497 - */ 498 - 499 - static struct omap_hwmod_class_sysconfig dra7xx_usb_otg_ss_sysc = { 500 - .rev_offs = 0x0000, 501 - .sysc_offs = 0x0010, 502 - .sysc_flags = (SYSC_HAS_DMADISABLE | SYSC_HAS_MIDLEMODE | 503 - SYSC_HAS_SIDLEMODE), 504 - .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART | 505 - SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO | 506 - MSTANDBY_SMART | MSTANDBY_SMART_WKUP), 507 - .sysc_fields = &omap_hwmod_sysc_type2, 508 - }; 509 - 510 - static struct omap_hwmod_class dra7xx_usb_otg_ss_hwmod_class = { 511 - .name = "usb_otg_ss", 512 - .sysc = &dra7xx_usb_otg_ss_sysc, 513 - }; 514 - 515 - /* usb_otg_ss1 */ 516 - static struct omap_hwmod_opt_clk usb_otg_ss1_opt_clks[] = { 517 - { .role = "refclk960m", .clk = "usb_otg_ss1_refclk960m" }, 518 - }; 519 - 520 - static struct omap_hwmod dra7xx_usb_otg_ss1_hwmod = { 521 - .name = "usb_otg_ss1", 522 - .class = &dra7xx_usb_otg_ss_hwmod_class, 523 - .clkdm_name = "l3init_clkdm", 524 - .main_clk = "dpll_core_h13x2_ck", 525 - .flags = HWMOD_CLKDM_NOAUTO, 526 - .prcm = { 527 - .omap4 = { 528 - .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS1_CLKCTRL_OFFSET, 529 - .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS1_CONTEXT_OFFSET, 530 - .modulemode = MODULEMODE_HWCTRL, 531 - }, 532 - }, 533 - .opt_clks = usb_otg_ss1_opt_clks, 534 - .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss1_opt_clks), 535 - }; 536 - 537 - /* usb_otg_ss2 */ 538 - static struct omap_hwmod_opt_clk usb_otg_ss2_opt_clks[] = { 539 - { .role = "refclk960m", .clk = "usb_otg_ss2_refclk960m" }, 540 - }; 541 - 542 - static struct omap_hwmod dra7xx_usb_otg_ss2_hwmod = { 543 - .name = "usb_otg_ss2", 544 - .class = &dra7xx_usb_otg_ss_hwmod_class, 545 - .clkdm_name = "l3init_clkdm", 546 - .main_clk = "dpll_core_h13x2_ck", 547 - .flags = HWMOD_CLKDM_NOAUTO, 548 - .prcm = { 549 - .omap4 = { 550 - .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS2_CLKCTRL_OFFSET, 551 - .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS2_CONTEXT_OFFSET, 552 - .modulemode = MODULEMODE_HWCTRL, 553 - }, 554 - }, 555 - .opt_clks = usb_otg_ss2_opt_clks, 556 - .opt_clks_cnt = ARRAY_SIZE(usb_otg_ss2_opt_clks), 557 - }; 558 - 559 - /* usb_otg_ss3 */ 560 - static struct omap_hwmod dra7xx_usb_otg_ss3_hwmod = { 561 - .name = "usb_otg_ss3", 562 - .class = &dra7xx_usb_otg_ss_hwmod_class, 563 - .clkdm_name = "l3init_clkdm", 564 - .main_clk = "dpll_core_h13x2_ck", 565 - .prcm = { 566 - .omap4 = { 567 - .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS3_CLKCTRL_OFFSET, 568 - .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS3_CONTEXT_OFFSET, 569 - .modulemode = MODULEMODE_HWCTRL, 570 - }, 571 - }, 572 - }; 573 - 574 - /* usb_otg_ss4 */ 575 - static struct omap_hwmod dra7xx_usb_otg_ss4_hwmod = { 576 - .name = "usb_otg_ss4", 577 - .class = &dra7xx_usb_otg_ss_hwmod_class, 578 - .clkdm_name = "l3init_clkdm", 579 - .main_clk = "dpll_core_h13x2_ck", 580 - .prcm = { 581 - .omap4 = { 582 - .clkctrl_offs = DRA7XX_CM_L3INIT_USB_OTG_SS4_CLKCTRL_OFFSET, 583 - .context_offs = DRA7XX_RM_L3INIT_USB_OTG_SS4_CONTEXT_OFFSET, 584 - .modulemode = MODULEMODE_HWCTRL, 585 - }, 586 - }, 587 - }; 588 - 589 - /* 590 495 * 'vcp' class 591 496 * 592 497 */ ··· 718 813 .user = OCP_USER_MPU | OCP_USER_SDMA, 719 814 }; 720 815 721 - /* l4_per3 -> usb_otg_ss1 */ 722 - static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss1 = { 723 - .master = &dra7xx_l4_per3_hwmod, 724 - .slave = &dra7xx_usb_otg_ss1_hwmod, 725 - .clk = "dpll_core_h13x2_ck", 726 - .user = OCP_USER_MPU | OCP_USER_SDMA, 727 - }; 728 - 729 - /* l4_per3 -> usb_otg_ss2 */ 730 - static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss2 = { 731 - .master = &dra7xx_l4_per3_hwmod, 732 - .slave = &dra7xx_usb_otg_ss2_hwmod, 733 - .clk = "dpll_core_h13x2_ck", 734 - .user = OCP_USER_MPU | OCP_USER_SDMA, 735 - }; 736 - 737 - /* l4_per3 -> usb_otg_ss3 */ 738 - static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss3 = { 739 - .master = &dra7xx_l4_per3_hwmod, 740 - .slave = &dra7xx_usb_otg_ss3_hwmod, 741 - .clk = "dpll_core_h13x2_ck", 742 - .user = OCP_USER_MPU | OCP_USER_SDMA, 743 - }; 744 - 745 - /* l4_per3 -> usb_otg_ss4 */ 746 - static struct omap_hwmod_ocp_if dra7xx_l4_per3__usb_otg_ss4 = { 747 - .master = &dra7xx_l4_per3_hwmod, 748 - .slave = &dra7xx_usb_otg_ss4_hwmod, 749 - .clk = "dpll_core_h13x2_ck", 750 - .user = OCP_USER_MPU | OCP_USER_SDMA, 751 - }; 752 - 753 816 /* l3_main_1 -> vcp1 */ 754 817 static struct omap_hwmod_ocp_if dra7xx_l3_main_1__vcp1 = { 755 818 .master = &dra7xx_l3_main_1_hwmod, ··· 773 900 &dra7xx_l4_cfg__pciess2, 774 901 &dra7xx_l3_main_1__qspi, 775 902 &dra7xx_l4_cfg__sata, 776 - &dra7xx_l4_per3__usb_otg_ss1, 777 - &dra7xx_l4_per3__usb_otg_ss2, 778 - &dra7xx_l4_per3__usb_otg_ss3, 779 903 &dra7xx_l3_main_1__vcp1, 780 904 &dra7xx_l4_per2__vcp1, 781 905 &dra7xx_l3_main_1__vcp2, ··· 781 911 }; 782 912 783 913 /* SoC variant specific hwmod links */ 784 - static struct omap_hwmod_ocp_if *dra76x_hwmod_ocp_ifs[] __initdata = { 785 - &dra7xx_l4_per3__usb_otg_ss4, 786 - NULL, 787 - }; 788 - 789 - static struct omap_hwmod_ocp_if *acd_76x_hwmod_ocp_ifs[] __initdata = { 790 - NULL, 791 - }; 792 - 793 - static struct omap_hwmod_ocp_if *dra74x_hwmod_ocp_ifs[] __initdata = { 794 - &dra7xx_l4_per3__usb_otg_ss4, 795 - NULL, 796 - }; 797 - 798 914 static struct omap_hwmod_ocp_if *dra72x_hwmod_ocp_ifs[] __initdata = { 799 915 NULL, 800 916 }; ··· 798 942 ret = omap_hwmod_register_links(dra7xx_hwmod_ocp_ifs); 799 943 800 944 if (!ret && soc_is_dra74x()) { 801 - ret = omap_hwmod_register_links(dra74x_hwmod_ocp_ifs); 802 - if (!ret) 803 - ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs); 945 + ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs); 804 946 } else if (!ret && soc_is_dra72x()) { 805 947 ret = omap_hwmod_register_links(dra72x_hwmod_ocp_ifs); 806 948 if (!ret && !of_machine_is_compatible("ti,dra718")) 807 949 ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs); 808 950 } else if (!ret && soc_is_dra76x()) { 809 - ret = omap_hwmod_register_links(dra76x_hwmod_ocp_ifs); 810 - 811 - if (!ret && soc_is_dra76x_acd()) { 812 - ret = omap_hwmod_register_links(acd_76x_hwmod_ocp_ifs); 813 - } else if (!ret && soc_is_dra76x_abz()) { 951 + if (!ret && soc_is_dra76x_abz()) 814 952 ret = omap_hwmod_register_links(rtc_hwmod_ocp_ifs); 815 - } 816 953 } 817 954 818 955 return ret;