[SRU][Eoan/raspi2][PATCH 0/1] IO errors when writing large amounts of data to USB storage in eoan on RPI2/3 (armhf kernel)

Hui Wang hui.wang at canonical.com
Wed Nov 20 14:18:55 UTC 2019


BugLink: https://bugs.launchpad.net/bugs/1852510

The upstream already looked at the patch and agreed with the change
(https://github.com/raspberrypi/linux/issues/3332), and I already
sent the pullrequest but looks like the maintainer is on vacation,
we need to wait for a long period of time.
(https://github.com/raspberrypi/linux/pull/3341)

But this bug is very critical, it is a block for generating our
image, so I send this patch to SRU before it is merged by upstream.


[Impact]
On the RPI2/3 boards with eoan armhf kernel, if we copy large size
files to usb stick, the usb host driver dwc_otg will fail and print
lots of IO errors in the dmesg.

[Fix]
To support rpi4, we enabled the LPAE/HIGHMEM/VMSPLIT_3G in the armhf
kernel, the dwc_otg has some problem with highmem enabled. If the
urb's buffer is in the highmem region, the enqueue function will return
the -EINVALID unconditionally, as a result, it can't handle the urb
which contains the highmem buffer. But the driver itself can handle the
highmem buffer, we just need to do a little change.

[Test Case]
With the patch applied, I tested armhf and arm64 kernel on rpi2/3/4,
all worked well, no regression and the usb driver works well.

[Regression Risk]
Low, the upstream already looked at my patch and agreed with my
change, and I tested the patch on rpi2/3/4 with armhf and arm64
kernels, all worked well.

Hui Wang (1):
  UBUNTU: SAUCE: dwc_otg: checking the urb->transfer_buffer too early
    (#3332)

 drivers/usb/host/dwc_otg/dwc_otg_hcd_linux.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

-- 
2.17.1




More information about the kernel-team mailing list