Skip to content

Commit c28bdea

Browse files
committed
Merge tag 'usb-6.2-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Pull USB fixes from Greg KH: "Here are some small USB driver fixes for 6.2-rc3 that resolve some reported issues. They include: - of-reported ulpi problem, so the offending commit is reverted - dwc3 driver bugfixes for recent changes - fotg210 fixes Most of these have been in linux-next for a while, the last few were on the mailing list for a long time and passed all the 0-day bot testing so all should be fine with them as well" * tag 'usb-6.2-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: usb: dwc3: gadget: Ignore End Transfer delay on teardown usb: dwc3: xilinx: include linux/gpio/consumer.h usb: fotg210-udc: fix error return code in fotg210_udc_probe() usb: fotg210: fix OTG-only build Revert "usb: ulpi: defer ulpi_register on ulpi_read_id timeout"
2 parents 4a4dcea + c4e3ef5 commit c28bdea

File tree

5 files changed

+9
-6
lines changed

5 files changed

+9
-6
lines changed

drivers/usb/common/ulpi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ static int ulpi_read_id(struct ulpi *ulpi)
207207
/* Test the interface */
208208
ret = ulpi_write(ulpi, ULPI_SCRATCH, 0xaa);
209209
if (ret < 0)
210-
return ret;
210+
goto err;
211211

212212
ret = ulpi_read(ulpi, ULPI_SCRATCH);
213213
if (ret < 0)

drivers/usb/dwc3/dwc3-xilinx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
#include <linux/of.h>
1414
#include <linux/platform_device.h>
1515
#include <linux/dma-mapping.h>
16+
#include <linux/gpio/consumer.h>
1617
#include <linux/of_gpio.h>
1718
#include <linux/of_platform.h>
1819
#include <linux/pm_runtime.h>

drivers/usb/dwc3/gadget.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1727,6 +1727,7 @@ static int __dwc3_stop_active_transfer(struct dwc3_ep *dep, bool force, bool int
17271727
else if (!ret)
17281728
dep->flags |= DWC3_EP_END_TRANSFER_PENDING;
17291729

1730+
dep->flags &= ~DWC3_EP_DELAY_STOP;
17301731
return ret;
17311732
}
17321733

@@ -3732,8 +3733,10 @@ void dwc3_stop_active_transfer(struct dwc3_ep *dep, bool force,
37323733
if (dep->number <= 1 && dwc->ep0state != EP0_DATA_PHASE)
37333734
return;
37343735

3736+
if (interrupt && (dep->flags & DWC3_EP_DELAY_STOP))
3737+
return;
3738+
37353739
if (!(dep->flags & DWC3_EP_TRANSFER_STARTED) ||
3736-
(dep->flags & DWC3_EP_DELAY_STOP) ||
37373740
(dep->flags & DWC3_EP_END_TRANSFER_PENDING))
37383741
return;
37393742

drivers/usb/fotg210/fotg210-core.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -144,10 +144,7 @@ static struct platform_driver fotg210_driver = {
144144

145145
static int __init fotg210_init(void)
146146
{
147-
if (usb_disabled())
148-
return -ENODEV;
149-
150-
if (IS_ENABLED(CONFIG_USB_FOTG210_HCD))
147+
if (IS_ENABLED(CONFIG_USB_FOTG210_HCD) && !usb_disabled())
151148
fotg210_hcd_init();
152149
return platform_driver_register(&fotg210_driver);
153150
}

drivers/usb/fotg210/fotg210-udc.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1201,6 +1201,8 @@ int fotg210_udc_probe(struct platform_device *pdev)
12011201
dev_info(dev, "found and initialized PHY\n");
12021202
}
12031203

1204+
ret = -ENOMEM;
1205+
12041206
for (i = 0; i < FOTG210_MAX_NUM_EP; i++) {
12051207
fotg210->ep[i] = kzalloc(sizeof(struct fotg210_ep), GFP_KERNEL);
12061208
if (!fotg210->ep[i])

0 commit comments

Comments
 (0)