Merge 3.10-rc3 into usb-next
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 May 2013 02:00:52 +0000 (11:00 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 May 2013 02:00:52 +0000 (11:00 +0900)
We want these fixes.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
12 files changed:
1  2 
drivers/usb/chipidea/ci13xxx_imx.c
drivers/usb/host/Kconfig
drivers/usb/host/ehci-omap.c
drivers/usb/host/ehci-orion.c
drivers/usb/host/ehci-spear.c
drivers/usb/host/ohci-nxp.c
drivers/usb/host/ohci-omap3.c
drivers/usb/host/ohci-pxa27x.c
drivers/usb/host/ohci-spear.c
drivers/usb/host/oxu210hp-hcd.c
drivers/usb/host/uhci-platform.c
drivers/usb/phy/phy-nop.c

index b8ad556c149601e937ed6d17a520c5a7e03e30c0,73f9d5f15adb6706b30a48b4c34963027d2565a0..585099ac60dd28b353af04ae7525c707b30cde63
@@@ -173,17 -173,10 +173,10 @@@ static int ci13xxx_imx_probe(struct pla
  
        ci13xxx_imx_platdata.phy = data->phy;
  
-       if (!pdev->dev.dma_mask) {
-               pdev->dev.dma_mask = devm_kzalloc(&pdev->dev,
-                                     sizeof(*pdev->dev.dma_mask), GFP_KERNEL);
-               if (!pdev->dev.dma_mask) {
-                       ret = -ENOMEM;
-                       dev_err(&pdev->dev, "Failed to alloc dma_mask!\n");
-                       goto err;
-               }
-               *pdev->dev.dma_mask = DMA_BIT_MASK(32);
-               dma_set_coherent_mask(&pdev->dev, *pdev->dev.dma_mask);
-       }
+       if (!pdev->dev.dma_mask)
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        if (usbmisc_ops && usbmisc_ops->init) {
                ret = usbmisc_ops->init(&pdev->dev);
@@@ -251,6 -244,8 +244,6 @@@ static int ci13xxx_imx_remove(struct pl
  
        clk_disable_unprepare(data->clk);
  
 -      platform_set_drvdata(pdev, NULL);
 -
        return 0;
  }
  
diff --combined drivers/usb/host/Kconfig
index 605e2773aad4e815d8a19b5084c8e006b996ef58,344d5e2f87d73a7234452a2b698f63b4959494e5..77aeb0de98e15eb3d39aebab187485f8feafbfe7
@@@ -345,17 -345,6 +345,17 @@@ config USB_ISP1362_HC
          To compile this driver as a module, choose M here: the
          module will be called isp1362-hcd.
  
 +config USB_FUSBH200_HCD
 +      tristate "FUSBH200 HCD support"
 +      depends on USB
 +      default N
 +      ---help---
 +      Faraday FUSBH200 is designed to meet USB2.0 EHCI specification
 +      with minor modification.
 +
 +      To compile this driver as a module, choose M here: the
 +      module will be called fusbh200-hcd.
 +
  config USB_OHCI_HCD
        tristate "OHCI HCD support"
        depends on USB_ARCH_HAS_OHCI
@@@ -518,7 -507,7 +518,7 @@@ endif # USB_OHCI_HC
  
  config USB_UHCI_HCD
        tristate "UHCI HCD (most Intel and VIA) support"
-       depends on PCI || SPARC_LEON || ARCH_VT8500
+       depends on PCI || USB_UHCI_SUPPORT_NON_PCI_HC
        ---help---
          The Universal Host Controller Interface is a standard by Intel for
          accessing the USB hardware in the PC (which is also called the USB
  
  config USB_UHCI_SUPPORT_NON_PCI_HC
        bool
-       depends on USB_UHCI_HCD
-       default y if (SPARC_LEON || ARCH_VT8500)
+       default y if (SPARC_LEON || USB_UHCI_PLATFORM)
  
  config USB_UHCI_PLATFORM
-       bool "Generic UHCI Platform Driver support"
-       depends on USB_UHCI_SUPPORT_NON_PCI_HC
+       bool
        default y if ARCH_VT8500
-       ---help---
-         Enable support for generic UHCI platform devices that require no
-         additional configuration.
  
  config USB_UHCI_BIG_ENDIAN_MMIO
        bool
-       depends on USB_UHCI_SUPPORT_NON_PCI_HC && SPARC_LEON
-       default y
+       default y if SPARC_LEON
  
  config USB_UHCI_BIG_ENDIAN_DESC
        bool
-       depends on USB_UHCI_SUPPORT_NON_PCI_HC && SPARC_LEON
-       default y
+       default y if SPARC_LEON
  
  config USB_FHCI_HCD
        tristate "Freescale QE USB Host Controller support"
index d3582fdfb34c371ab7efe93ca0f9fe458db1e428,16d7150e855722be6bc143c504d31120adf53f83..bafa960ffd92c5193ccec090f1cfe894ad5580e6
@@@ -90,8 -90,6 +90,6 @@@ static const struct ehci_driver_overrid
        .extra_priv_size = sizeof(struct omap_hcd),
  };
  
- static u64 omap_ehci_dma_mask = DMA_BIT_MASK(32);
  /**
   * ehci_hcd_omap_probe - initialize TI-based HCDs
   *
@@@ -146,8 -144,10 +144,10 @@@ static int ehci_hcd_omap_probe(struct p
         * Since shared usb code relies on it, set it here for now.
         * Once we have dma capability bindings this can go away.
         */
-       if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &omap_ehci_dma_mask;
+       if (!dev->dma_mask)
+               dev->dma_mask = &dev->coherent_dma_mask;
+       if (!dev->coherent_dma_mask)
+               dev->coherent_dma_mask = DMA_BIT_MASK(32);
  
        hcd = usb_create_hcd(&ehci_omap_hc_driver, dev,
                        dev_name(dev));
@@@ -294,7 -294,7 +294,7 @@@ static struct platform_driver ehci_hcd_
        /*.resume               = ehci_hcd_omap_resume, */
        .driver = {
                .name           = hcd_name,
 -              .of_match_table = of_match_ptr(omap_ehci_dt_ids),
 +              .of_match_table = omap_ehci_dt_ids,
        }
  };
  
index 29cc4a3a07a37b123bad379872570fed7367f893,efbc588b48c50acbc2225c6be3f63ce1b1f35ffd..1a450aa13ebf04aaa3b8fef5ce9e296412b89373
@@@ -137,8 -137,6 +137,6 @@@ ehci_orion_conf_mbus_windows(struct usb
        }
  }
  
- static u64 ehci_orion_dma_mask = DMA_BIT_MASK(32);
  static int ehci_orion_drv_probe(struct platform_device *pdev)
  {
        struct orion_ehci_data *pd = pdev->dev.platform_data;
         * now. Once we have dma capability bindings this can go away.
         */
        if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &ehci_orion_dma_mask;
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        if (!request_mem_region(res->start, resource_size(res),
                                ehci_orion_hc_driver.description)) {
@@@ -303,7 -303,7 +303,7 @@@ static struct platform_driver ehci_orio
        .driver = {
                .name   = "orion-ehci",
                .owner  = THIS_MODULE,
 -              .of_match_table = of_match_ptr(ehci_orion_dt_ids),
 +              .of_match_table = ehci_orion_dt_ids,
        },
  };
  
index 7c0a3566b0fe10b538ae297d49b3a63c4145a36d,bd3e5cbc6240316dc5947f6f38dbc6a6c7492c51..f5ac4e202bb6ee480aca02c1eef2c8138b5908a6
@@@ -58,8 -58,6 +58,6 @@@ static int ehci_spear_drv_resume(struc
  static SIMPLE_DEV_PM_OPS(ehci_spear_pm_ops, ehci_spear_drv_suspend,
                ehci_spear_drv_resume);
  
- static u64 spear_ehci_dma_mask = DMA_BIT_MASK(32);
  static int spear_ehci_hcd_drv_probe(struct platform_device *pdev)
  {
        struct usb_hcd *hcd ;
@@@ -84,7 -82,9 +82,9 @@@
         * Once we have dma capability bindings this can go away.
         */
        if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &spear_ehci_dma_mask;
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        usbh_clk = devm_clk_get(&pdev->dev, NULL);
        if (IS_ERR(usbh_clk)) {
@@@ -174,7 -174,7 +174,7 @@@ static struct platform_driver spear_ehc
                .name = "spear-ehci",
                .bus = &platform_bus_type,
                .pm = &ehci_spear_pm_ops,
 -              .of_match_table = of_match_ptr(spear_ehci_id_table),
 +              .of_match_table = spear_ehci_id_table,
        }
  };
  
index 86d04ed24b7248277b604e0cd0309351783390f8,5d7eb72c506403b6e3022f14b09aa47e2c8a97c1..281ba57a11e2fcfe0f34f3cc9483888d6ea7de8d
@@@ -223,8 -223,7 +223,7 @@@ static int usb_hcd_nxp_probe(struct pla
  
        isp1301_i2c_client = isp1301_get_client(isp1301_node);
        if (!isp1301_i2c_client) {
-               ret = -EPROBE_DEFER;
-               goto out;
+               return -EPROBE_DEFER;
        }
  
        pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
        if (usb_disabled()) {
                dev_err(&pdev->dev, "USB is disabled\n");
                ret = -ENODEV;
-               goto out;
+               goto fail_disable;
        }
  
        /* Enable AHB slave USB clock, needed for further USB clock control */
        if (IS_ERR(usb_pll_clk)) {
                dev_err(&pdev->dev, "failed to acquire USB PLL\n");
                ret = PTR_ERR(usb_pll_clk);
-               goto out1;
+               goto fail_pll;
        }
  
        ret = clk_enable(usb_pll_clk);
        if (ret < 0) {
                dev_err(&pdev->dev, "failed to start USB PLL\n");
-               goto out2;
+               goto fail_pllen;
        }
  
        ret = clk_set_rate(usb_pll_clk, 48000);
        if (ret < 0) {
                dev_err(&pdev->dev, "failed to set USB clock rate\n");
-               goto out3;
+               goto fail_rate;
        }
  
        /* Enable USB device clock */
        if (IS_ERR(usb_dev_clk)) {
                dev_err(&pdev->dev, "failed to acquire USB DEV Clock\n");
                ret = PTR_ERR(usb_dev_clk);
-               goto out4;
+               goto fail_dev;
        }
  
        ret = clk_enable(usb_dev_clk);
        if (ret < 0) {
                dev_err(&pdev->dev, "failed to start USB DEV Clock\n");
-               goto out5;
+               goto fail_deven;
        }
  
        /* Enable USB otg clocks */
        if (IS_ERR(usb_otg_clk)) {
                dev_err(&pdev->dev, "failed to acquire USB DEV Clock\n");
                ret = PTR_ERR(usb_otg_clk);
-               goto out6;
+               goto fail_otg;
        }
  
        __raw_writel(__raw_readl(USB_CTRL) | USB_HOST_NEED_CLK_EN, USB_CTRL);
        ret = clk_enable(usb_otg_clk);
        if (ret < 0) {
                dev_err(&pdev->dev, "failed to start USB DEV Clock\n");
-               goto out7;
+               goto fail_otgen;
        }
  
        isp1301_configure();
        if (!hcd) {
                dev_err(&pdev->dev, "Failed to allocate HC buffer\n");
                ret = -ENOMEM;
-               goto out8;
+               goto fail_hcd;
        }
  
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
        hcd->regs = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(hcd->regs)) {
                ret = PTR_ERR(hcd->regs);
-               goto out8;
+               goto fail_resource;
        }
        hcd->rsrc_start = res->start;
        hcd->rsrc_len = resource_size(res);
        irq = platform_get_irq(pdev, 0);
        if (irq < 0) {
                ret = -ENXIO;
-               goto out8;
+               goto fail_resource;
        }
  
        nxp_start_hc();
                return ret;
  
        nxp_stop_hc();
out8:
fail_resource:
        usb_put_hcd(hcd);
out7:
fail_hcd:
        clk_disable(usb_otg_clk);
out6:
fail_otgen:
        clk_put(usb_otg_clk);
out5:
fail_otg:
        clk_disable(usb_dev_clk);
out4:
fail_deven:
        clk_put(usb_dev_clk);
- out3:
+ fail_dev:
+ fail_rate:
        clk_disable(usb_pll_clk);
out2:
fail_pllen:
        clk_put(usb_pll_clk);
- out1:
+ fail_pll:
+ fail_disable:
        isp1301_i2c_client = NULL;
- out:
        return ret;
  }
  
@@@ -360,6 -360,8 +360,6 @@@ static int usb_hcd_nxp_remove(struct pl
        i2c_unregister_device(isp1301_i2c_client);
        isp1301_i2c_client = NULL;
  
 -      platform_set_drvdata(pdev, NULL);
 -
        return 0;
  }
  
index 08e811d438f37eb77a5a9947b1d3d2dd087fcfd8,8663851c8d8eac79b5d358d9e6f81f6116d5fc41..8f713571a0b75b9a24266bf281c934a2dcaf93cd
@@@ -114,8 -114,6 +114,6 @@@ static const struct hc_driver ohci_omap
  
  /*-------------------------------------------------------------------------*/
  
- static u64 omap_ohci_dma_mask = DMA_BIT_MASK(32);
  /*
   * configure so an HC device and id are always provided
   * always called with process context; sleeping is OK
@@@ -168,8 -166,10 +166,10 @@@ static int ohci_hcd_omap3_probe(struct 
         * Since shared usb code relies on it, set it here for now.
         * Once we have dma capability bindings this can go away.
         */
-       if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &omap_ohci_dma_mask;
+       if (!dev->dma_mask)
+               dev->dma_mask = &dev->coherent_dma_mask;
+       if (!dev->coherent_dma_mask)
+               dev->coherent_dma_mask = DMA_BIT_MASK(32);
  
        hcd = usb_create_hcd(&ohci_omap3_hc_driver, dev,
                        dev_name(dev));
@@@ -252,7 -252,7 +252,7 @@@ static struct platform_driver ohci_hcd_
        .shutdown       = ohci_hcd_omap3_shutdown,
        .driver         = {
                .name   = "ohci-omap3",
 -              .of_match_table = of_match_ptr(omap_ohci_dt_ids),
 +              .of_match_table = omap_ohci_dt_ids,
        },
  };
  
index 4e0f088b6d2b72d3e92774f1fde92c5590e07337,279b2ef1741149fe05deda764c09151763f56f1d..3a9c01d8b79c77b4fb607cbe003ab1b3ac6be6d5
@@@ -282,8 -282,6 +282,6 @@@ static const struct of_device_id pxa_oh
  
  MODULE_DEVICE_TABLE(of, pxa_ohci_dt_ids);
  
- static u64 pxa_ohci_dma_mask = DMA_BIT_MASK(32);
  static int ohci_pxa_of_init(struct platform_device *pdev)
  {
        struct device_node *np = pdev->dev.of_node;
         * Once we have dma capability bindings this can go away.
         */
        if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &pxa_ohci_dma_mask;
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL);
        if (!pdata)
@@@ -556,6 -556,7 +556,6 @@@ static int ohci_hcd_pxa27x_drv_remove(s
        struct usb_hcd *hcd = platform_get_drvdata(pdev);
  
        usb_hcd_pxa27x_remove(hcd, pdev);
 -      platform_set_drvdata(pdev, NULL);
        return 0;
  }
  
index 6a7cb1407326b917ac82ad1a7a0aeaf1fa74dc08,3e19e0170d1195711b4f235fd4be043fb234d65e..cc9dd9e4f05e69469eeca87233dd0f29bac23992
@@@ -91,8 -91,6 +91,6 @@@ static const struct hc_driver ohci_spea
        .start_port_reset       = ohci_start_port_reset,
  };
  
- static u64 spear_ohci_dma_mask = DMA_BIT_MASK(32);
  static int spear_ohci_hcd_drv_probe(struct platform_device *pdev)
  {
        const struct hc_driver *driver = &ohci_spear_hc_driver;
         * Once we have dma capability bindings this can go away.
         */
        if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &spear_ohci_dma_mask;
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        usbh_clk = devm_clk_get(&pdev->dev, NULL);
        if (IS_ERR(usbh_clk)) {
@@@ -179,6 -179,8 +179,6 @@@ static int spear_ohci_hcd_drv_remove(st
                spear_stop_ohci(ohci_p);
  
        usb_put_hcd(hcd);
 -
 -      platform_set_drvdata(pdev, NULL);
        return 0;
  }
  
@@@ -230,7 -232,7 +230,7 @@@ static struct platform_driver spear_ohc
        .driver = {
                .owner = THIS_MODULE,
                .name = "spear-ohci",
 -              .of_match_table = of_match_ptr(spear_ohci_id_table),
 +              .of_match_table = spear_ohci_id_table,
        },
  };
  
index c9d1149651235334fefc95016ffbbaab09edaa9d,0f401dbfaf073bb59f7faad445a19663bded3a0e..4a6df2d8f902f04951cedab23de2ebf49301f786
@@@ -3084,7 -3084,7 +3084,7 @@@ static int oxu_hub_status_data(struct u
        int ports, i, retval = 1;
        unsigned long flags;
  
-       /* if !USB_SUSPEND, root hub timers won't get shut down ... */
+       /* if !PM_RUNTIME, root hub timers won't get shut down ... */
        if (!HC_IS_RUNNING(hcd->state))
                return 0;
  
@@@ -3874,6 -3874,7 +3874,6 @@@ static int oxu_drv_probe(struct platfor
  
  error_init:
        kfree(info);
 -      platform_set_drvdata(pdev, NULL);
  
  error_alloc:
        iounmap(base);
@@@ -3906,6 -3907,7 +3906,6 @@@ static int oxu_drv_remove(struct platfo
        release_mem_region(memstart, memlen);
  
        kfree(info);
 -      platform_set_drvdata(pdev, NULL);
  
        return 0;
  }
index 5382f3a8670d47ce8cdbb6eb7111f78bde90369d,f1db61ada6a84c435aedc3967f04f8aab76c1e55..e11b70ae5f6f751d98ededac9c2d7937f7ed44cb
@@@ -60,8 -60,6 +60,6 @@@ static const struct hc_driver uhci_plat
        .hub_control =          uhci_hub_control,
  };
  
- static u64 platform_uhci_dma_mask = DMA_BIT_MASK(32);
  static int uhci_hcd_platform_probe(struct platform_device *pdev)
  {
        struct usb_hcd *hcd;
@@@ -78,7 -76,9 +76,9 @@@
         * Once we have dma capability bindings this can go away.
         */
        if (!pdev->dev.dma_mask)
-               pdev->dev.dma_mask = &platform_uhci_dma_mask;
+               pdev->dev.dma_mask = &pdev->dev.coherent_dma_mask;
+       if (!pdev->dev.coherent_dma_mask)
+               pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
  
        hcd = usb_create_hcd(&uhci_platform_hc_driver, &pdev->dev,
                        pdev->name);
@@@ -130,6 -130,7 +130,6 @@@ static int uhci_hcd_platform_remove(str
        iounmap(hcd->regs);
        release_mem_region(hcd->rsrc_start, hcd->rsrc_len);
        usb_put_hcd(hcd);
 -      platform_set_drvdata(pdev, NULL);
  
        return 0;
  }
@@@ -160,6 -161,6 +160,6 @@@ static struct platform_driver uhci_plat
        .driver = {
                .name = "platform-uhci",
                .owner = THIS_MODULE,
 -              .of_match_table = of_match_ptr(platform_uhci_ids),
 +              .of_match_table = platform_uhci_ids,
        },
  };
index 74815beab0d9bfd9058910fadcf6a670a4492cb3,638cc5dade35227732e77e6c5ccb0d769eb47d8b..55445e5d72e597c4476ff62d0c471ce3fb9433a3
@@@ -254,8 -254,6 +254,6 @@@ static int nop_usb_xceiv_remove(struct 
  
        usb_remove_phy(&nop->phy);
  
-       platform_set_drvdata(pdev, NULL);
        return 0;
  }
  
@@@ -272,7 -270,7 +270,7 @@@ static struct platform_driver nop_usb_x
        .driver         = {
                .name   = "nop_usb_xceiv",
                .owner  = THIS_MODULE,
 -              .of_match_table = of_match_ptr(nop_xceiv_dt_ids),
 +              .of_match_table = nop_xceiv_dt_ids,
        },
  };
  
This page took 0.053293 seconds and 5 git commands to generate.