On Fri, Feb 09, 2024 at 05:11:21PM +0200, Tasos Sahanidis wrote: > This external HDD fails when plugged in to a USB 3 port. Ignoring UAS and > falling back to mass storage resolves this issue. What happens when it is plugged into a USB-2 port? > [ 56.338088] scsi 4:0:0:0: Direct-Access LaCie Rugged FW USB3 1081 PQ: 0 ANSI: 4 > [ 56.339162] sd 4:0:0:0: Attached scsi generic sg2 type 0 > [ 56.343484] sd 4:0:0:0: [sdc] 976773153 512-byte logical blocks: (500 GB/466 GiB) > [ 56.343600] sd 4:0:0:0: [sdc] Write Protect is off > [ 56.343604] sd 4:0:0:0: [sdc] Mode Sense: 47 00 10 08 > [ 87.365885] sd 4:0:0:0: tag#26 uas_eh_abort_handler 0 uas-tag 1 inflight: IN > [ 87.365897] sd 4:0:0:0: tag#26 CDB: Mode Sense(6) 1a 00 08 00 04 00 > [ 87.381852] scsi host4: uas_eh_device_reset_handler start > [ 87.514256] usb 3-1: reset SuperSpeed USB device number 2 using xhci_hcd > [ 87.538153] usb 3-1: LPM exit latency is zeroed, disabling LPM. > [ 87.539720] scsi host4: uas_eh_device_reset_handler success > [ 118.102578] scsi host4: uas_eh_device_reset_handler start > [ 118.102733] sd 4:0:0:0: tag#26 uas_zap_pending 0 uas-tag 1 inflight: > [ 118.102745] sd 4:0:0:0: tag#26 CDB: Mode Sense(6) 1a 00 08 00 04 00 > [ 118.231029] usb 3-1: reset SuperSpeed USB device number 2 using xhci_hcd Have you checked to see if any of the quirk flags can prevent this problem? It looks like the only issue might be that one Mode Sense(6) command. Falling back from uas to usb-storage could reduce the throughput considerably. We would like to avoid doing this if possible. Alan Stern > Signed-off-by: Tasos Sahanidis <tasos@xxxxxxxxxxxx> > --- > drivers/usb/storage/unusual_uas.h | 11 +++++++++++ > 1 file changed, 11 insertions(+) > > diff --git a/drivers/usb/storage/unusual_uas.h b/drivers/usb/storage/unusual_uas.h > index 1f8c9b16a0fb..b1d99c57cf8a 100644 > --- a/drivers/usb/storage/unusual_uas.h > +++ b/drivers/usb/storage/unusual_uas.h > @@ -45,6 +45,17 @@ UNUSUAL_DEV(0x059f, 0x105f, 0x0000, 0x9999, > USB_SC_DEVICE, USB_PR_DEVICE, NULL, > US_FL_NO_REPORT_OPCODES | US_FL_NO_SAME), > > +/* > + * Patch by Tasos Sahanidis <tasos@xxxxxxxxxxxx> > + * UAS hangs during Mode Sense(6). The quirks for the similar "Rugged USB3-FW" > + * disk (US_FL_NO_REPORT_OPCODES | US_FL_NO_SAME) do not resolve the issue. > + */ > +UNUSUAL_DEV(0x059f, 0x104b, 0x0000, 0x9999, > + "LaCie", > + "Rugged FW USB3", > + USB_SC_DEVICE, USB_PR_DEVICE, NULL, > + US_FL_IGNORE_UAS), > + > /* Reported-by: Julian Sikorski <belegdol@xxxxxxxxx> */ > UNUSUAL_DEV(0x059f, 0x1061, 0x0000, 0x9999, > "LaCie", > -- > 2.25.1 > >