Hi,

On Tue, Jul 02, 2013 at 06:04:45PM +0000, Paul Zimmerman wrote:
> > From: linux-usb-ow...@vger.kernel.org 
> > [mailto:linux-usb-ow...@vger.kernel.org] On Behalf Of Felipe Balbi
> > Sent: Tuesday, July 02, 2013 2:31 AM
> > 
> >     Signed-off-by: Felipe Balbi <ba...@ti.com>
> > 
> > diff --git a/Documentation/devicetree/bindings/usb/generic.txt 
> > b/Documentation/devicetree/bindings/usb/generic.txt
> > new file mode 100644
> > index 0000000..477d5bb
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/usb/generic.txt
> > @@ -0,0 +1,24 @@
> > +Generic USB Properties
> > +
> > +Optional properties:
> > + - maximum-speed: tells USB controllers we want to work up to a certain
> > +                   speed. Valid arguments are "super-speed", "high-speed",
> > +                   "full-speed" and "low-speed". In case this isn't passed
> > +                   via DT, USB controllers should default to their maximum
> > +                   HW capability.
> > + - dr_mode: tells Dual-Role USB controllers that we want to work on a
> > +                   particular mode. Valid arguments are "host",
> > +                   "peripheral" and "otg". In case this attribute isn't
> > +                   passed via DT, USB DRD controllers should default to
> > +                   OTG.
> > +
> > +This is an attribute to a USB controller such as:
> > +
> > +dwc3@4a030000 {
> > +   compatible = "synopsys,dwc3";
> 
> Hi Felipe,
> 
> Just a small nit. Weren't you going to change this property to
> "snps,dwc3" to match the existing Synopsys DT naming convention
> in the kernel? Or has the horse already left the gate on that?

I think we can still change, but we need to keep compatibility for the
old one in the driver :-)

Here's a patch for that:

commit 90dc4b82df9d0b4d049d03d1be225b9c7456522b
Author: Felipe Balbi <ba...@ti.com>
Date:   Tue Jul 2 21:20:24 2013 +0300

    usb: dwc3: core: switch to snps,dwc3
    
    all other drivers using Synopsys IPs with DT
    have a compatible of snps,$driver, in order
    to add consistency, we are switching over to
    snps,dwc3 but keeping synopsys,dwc3 in the core
    driver to maintain backwards compatibility.
    
    New DTS bindings should NOT use synopsys,dwc3.
    
    Signed-off-by: Felipe Balbi <ba...@ti.com>

diff --git a/Documentation/devicetree/bindings/usb/dwc3.txt 
b/Documentation/devicetree/bindings/usb/dwc3.txt
index 7a95c65..3a64e20 100644
--- a/Documentation/devicetree/bindings/usb/dwc3.txt
+++ b/Documentation/devicetree/bindings/usb/dwc3.txt
@@ -3,7 +3,7 @@ synopsys DWC3 CORE
 DWC3- USB3 CONTROLLER
 
 Required properties:
- - compatible: must be "synopsys,dwc3"
+ - compatible: must be "snps,dwc3"
  - reg : Address and length of the register set for the device
  - interrupts: Interrupts used by the dwc3 controller.
  - usb-phy : array of phandle for the PHY device
@@ -14,7 +14,7 @@ Optional properties:
 This is usually a subnode to DWC3 glue to which it is connected.
 
 dwc3@4a030000 {
-       compatible = "synopsys,dwc3";
+       compatible = "snps,dwc3";
        reg = <0x4a030000 0xcfff>;
        interrupts = <0 92 4>
        usb-phy = <&usb2_phy>, <&usb3,phy>;
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 635cae2..2462708 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -641,7 +641,7 @@
                        utmi-mode = <2>;
                        ranges;
                        dwc3@4a030000 {
-                               compatible = "synopsys,dwc3";
+                               compatible = "snps,dwc3";
                                reg = <0x4a030000 0x1000>;
                                interrupts = <0 92 4>;
                                usb-phy = <&usb2_phy>, <&usb3_phy>;
diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index c86ae12..a4dab1c 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -755,6 +755,9 @@ static const struct dev_pm_ops dwc3_dev_pm_ops = {
 #ifdef CONFIG_OF
 static const struct of_device_id of_dwc3_match[] = {
        {
+               .compatible = "snps,dwc3"
+       },
+       {
                .compatible = "synopsys,dwc3"
        },
        { },

-- 
balbi

Attachment: signature.asc
Description: Digital signature

Reply via email to