Re: Failure prints during format or mounting a usb storage device

2020-07-09 Thread Paul Zimmerman
On Thu, Jul 9, 2020 at 12:57 AM Gerd Hoffmann wrote: > > Starting at line 1746 is the first CBW, it's for an Inquiry command. > > > > Starting at line 1759 is the response, notice at line 1761 the MSD debug > > says "Data in 64/36", which is strange. > > Not really. First is the packet size, sec

Re: Failure prints during format or mounting a usb storage device

2020-07-09 Thread Gerd Hoffmann
> Starting at line 1746 is the first CBW, it's for an Inquiry command. > > Starting at line 1759 is the response, notice at line 1761 the MSD debug > says "Data in 64/36", which is strange. Not really. First is the packet size, second is the (remaining) data size. Inquiry data is 36 bytes, and

Re: Failure prints during format or mounting a usb storage device

2020-07-08 Thread Paul Zimmerman
On Wed, Jul 8, 2020 at 3:30 AM Gerd Hoffmann wrote: > Hi, > > > IIRC, without the dev-storage patch, the very first SCSI command > > would get stuck waiting for the CSW, because the CSW is not a > > multiple of MPS. I will have to work on getting a debug trace for > > you, I'll get back to you

Re: Failure prints during format or mounting a usb storage device

2020-07-08 Thread Gerd Hoffmann
Hi, > > Why does 7ad3d51ebb8a522ffcad391c4bef281245739dde look at short-not-ok? > > Because the patch changes dev-storage to terminate the transfer if a > short packet is received, so I figured 'short-not-ok' should affect > that behavior. I don't think so. dev-storage should not need to look

Re: Failure prints during format or mounting a usb storage device

2020-07-08 Thread Gerd Hoffmann
Hi, > IIRC, without the dev-storage patch, the very first SCSI command > would get stuck waiting for the CSW, because the CSW is not a > multiple of MPS. I will have to work on getting a debug trace for > you, I'll get back to you with that. Hmm, dev-storage should be fine with the packet being

Re: Failure prints during format or mounting a usb storage device

2020-07-08 Thread Paul Zimmerman
On Wed, Jul 8, 2020 at 12:29 AM Gerd Hoffmann wrote: > Hi, > > > > Why does 7ad3d51ebb8a522ffcad391c4bef281245739dde look at short-not-ok? > > > > Because the patch changes dev-storage to terminate the transfer if a > > short packet is received, so I figured 'short-not-ok' should affect > > tha

Re: Failure prints during format or mounting a usb storage device

2020-07-07 Thread Paul Zimmerman
On Tue, Jul 7, 2020 at 12:57 AM Gerd Hoffmann wrote: > Hi, > > > > Gerd, do you know the purpose of the 'short_not_ok' parameter to > > usb_packet_setup()? > > Well, some usb host controllers have a flag in the transfer control > blocks to indicate the host controller should stop processing req

Re: Failure prints during format or mounting a usb storage device

2020-07-07 Thread Gerd Hoffmann
Hi, > > Gerd, do you know the purpose of the 'short_not_ok' parameter to > usb_packet_setup()? Well, some usb host controllers have a flag in the transfer control blocks to indicate the host controller should stop processing requests in case of a short transfer. The usb core uses the flag to j

Re: Failure prints during format or mounting a usb storage device

2020-07-06 Thread Paul Zimmerman
On 7/6/20 3:21 PM, Paul Zimmerman wrote: On Sat, Jul 4, 2020 at 11:24 AM Paul Zimmerman mailto:pauld...@gmail.com>> wrote: On Sat, Jul 4, 2020 at 11:21 AM Sai Pavan Boddu mailto:saip...@xilinx.com>> wrote: Hi, __ __ We are seeing some errors when a usb-stora

Re: Failure prints during format or mounting a usb storage device

2020-07-06 Thread Paul Zimmerman
On Sat, Jul 4, 2020 at 11:24 AM Paul Zimmerman wrote: > > > On Sat, Jul 4, 2020 at 11:21 AM Sai Pavan Boddu > wrote: > >> Hi, >> >> >> >> We are seeing some errors when a usb-storage device is formatted or >> mounted on the guest. Below is commit I have bisected it. >> >> >> >> ** >>

Failure prints during format or mounting a usb storage device

2020-07-04 Thread Sai Pavan Boddu
Hi, We are seeing some errors when a usb-storage device is formatted or mounted on the guest. Below is commit I have bisected it. ** Errors: / # mount /dev/sda /mnt [New Thread 0x7fffd4680700 (LWP 23270)] [ 33.258454] usb 2-1: reset SuperSpeed Gen 1 USB device number 2 using xhci

Re: Failure prints during format or mounting a usb storage device

2020-07-04 Thread Paul Zimmerman
On Sat, Jul 4, 2020 at 11:21 AM Sai Pavan Boddu wrote: > Hi, > > > > We are seeing some errors when a usb-storage device is formatted or > mounted on the guest. Below is commit I have bisected it. > > > > ** > > Errors: > > > > / # mount /dev/sda /mnt > > [New Thread 0x7fffd4680700 (L