ARM: dts: sun8i: Move A23/A33 usbphy and usb_otg nodes to common dtsi
authorChen-Yu Tsai <wens@csie.org>
Thu, 8 Sep 2016 03:25:35 +0000 (11:25 +0800)
committerMaxime Ripard <maxime.ripard@free-electrons.com>
Sat, 10 Sep 2016 09:50:43 +0000 (11:50 +0200)
The usbphy and usb_otg nodes in the A23 and A33 dts files only differ
by compatible, and for the usbphy, the size of one of its register
regions.

Move all the common bits to the A23/A33 common dtsi file.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
arch/arm/boot/dts/sun8i-a23-a33.dtsi
arch/arm/boot/dts/sun8i-a23.dtsi
arch/arm/boot/dts/sun8i-a33.dtsi

index 7ea6de12040e34060dc33ddfcb19e56ba43faeb2..01d8bbf08749e3f5ae3294fa18e0327e61e2fbfe 100644 (file)
                        #size-cells = <0>;
                };
 
+               usb_otg: usb@01c19000 {
+                       /* compatible gets set in SoC specific dtsi file */
+                       reg = <0x01c19000 0x0400>;
+                       clocks = <&ccu CLK_BUS_OTG>;
+                       resets = <&ccu RST_BUS_OTG>;
+                       interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
+                       interrupt-names = "mc";
+                       phys = <&usbphy 0>;
+                       phy-names = "usb";
+                       extcon = <&usbphy 0>;
+                       status = "disabled";
+               };
+
+               usbphy: phy@01c19400 {
+                       /*
+                        * compatible and address regions get set in
+                        * SoC specific dtsi file
+                        */
+                       clocks = <&ccu CLK_USB_PHY0>,
+                                <&ccu CLK_USB_PHY1>;
+                       clock-names = "usb0_phy",
+                                     "usb1_phy";
+                       resets = <&ccu RST_USB_PHY0>,
+                                <&ccu RST_USB_PHY1>;
+                       reset-names = "usb0_reset",
+                                     "usb1_reset";
+                       status = "disabled";
+                       #phy-cells = <1>;
+               };
+
                ehci0: usb@01c1a000 {
                        compatible = "allwinner,sun8i-a23-ehci", "generic-ehci";
                        reg = <0x01c1a000 0x100>;
index a915feb3a49431a283280d261319e9a0ac34ba42..54d045dab825d71119218a3564d6ed437245cdc0 100644 (file)
        memory {
                reg = <0x40000000 0x40000000>;
        };
-
-       soc@01c00000 {
-               usb_otg: usb@01c19000 {
-                       compatible = "allwinner,sun6i-a31-musb";
-                       reg = <0x01c19000 0x0400>;
-                       clocks = <&ccu CLK_BUS_OTG>;
-                       resets = <&ccu RST_BUS_OTG>;
-                       interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
-                       interrupt-names = "mc";
-                       phys = <&usbphy 0>;
-                       phy-names = "usb";
-                       extcon = <&usbphy 0>;
-                       status = "disabled";
-               };
-
-               usbphy: phy@01c19400 {
-                       compatible = "allwinner,sun8i-a23-usb-phy";
-                       reg = <0x01c19400 0x10>,
-                             <0x01c1a800 0x4>;
-                       reg-names = "phy_ctrl",
-                                   "pmu1";
-                       clocks = <&ccu CLK_USB_PHY0>,
-                                <&ccu CLK_USB_PHY1>;
-                       clock-names = "usb0_phy",
-                                     "usb1_phy";
-                       resets = <&ccu RST_USB_PHY0>,
-                                <&ccu RST_USB_PHY1>;
-                       reset-names = "usb0_reset",
-                                     "usb1_reset";
-                       status = "disabled";
-                       #phy-cells = <1>;
-               };
-       };
 };
 
 &ccu {
                     <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>,
                     <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
 };
+
+&usb_otg {
+       compatible = "allwinner,sun6i-a31-musb";
+};
+
+&usbphy {
+       compatible = "allwinner,sun8i-a23-usb-phy";
+       reg = <0x01c19400 0x10>, <0x01c1a800 0x4>;
+       reg-names = "phy_ctrl", "pmu1";
+};
index 1d21d488cb3e37cc043f5a404d7f2aeafbaeb6ab..fd1e1cddd4a8fb95cfd87b44edd41d5b62c24448 100644 (file)
                        reset-names = "ahb";
                };
 
-               usb_otg: usb@01c19000 {
-                       compatible = "allwinner,sun8i-a33-musb";
-                       reg = <0x01c19000 0x0400>;
-                       clocks = <&ccu CLK_BUS_OTG>;
-                       resets = <&ccu RST_BUS_OTG>;
-                       interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
-                       interrupt-names = "mc";
-                       phys = <&usbphy 0>;
-                       phy-names = "usb";
-                       extcon = <&usbphy 0>;
-                       status = "disabled";
-               };
-
-               usbphy: phy@01c19400 {
-                       compatible = "allwinner,sun8i-a33-usb-phy";
-                       reg = <0x01c19400 0x14>,
-                             <0x01c1a800 0x4>;
-                       reg-names = "phy_ctrl",
-                                   "pmu1";
-                       clocks = <&ccu CLK_USB_PHY0>,
-                                <&ccu CLK_USB_PHY1>;
-                       clock-names = "usb0_phy",
-                                     "usb1_phy";
-                       resets = <&ccu RST_USB_PHY0>,
-                                <&ccu RST_USB_PHY1>;
-                       reset-names = "usb0_reset",
-                                     "usb1_reset";
-                       status = "disabled";
-                       #phy-cells = <1>;
-               };
-
                fe0: display-frontend@01e00000 {
                        compatible = "allwinner,sun8i-a33-display-frontend";
                        reg = <0x01e00000 0x20000>;
        };
 
 };
+
+&usb_otg {
+       compatible = "allwinner,sun8i-a33-musb";
+};
+
+&usbphy {
+       compatible = "allwinner,sun8i-a33-usb-phy";
+       reg = <0x01c19400 0x14>, <0x01c1a800 0x4>;
+       reg-names = "phy_ctrl", "pmu1";
+};