lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAAd53p6dSTHmLnUiFSX+7qHJXk_CpRBCvt5P4MKN-sda3qfhLA@mail.gmail.com>
Date: Tue, 26 Mar 2024 17:29:05 +0800
From: Kai-Heng Feng <kai.heng.feng@...onical.com>
To: Greg KH <gregkh@...uxfoundation.org>
Cc: stern@...land.harvard.edu, mathias.nyman@...ux.intel.com, oneukum@...e.com, 
	Roy Luo <royluo@...gle.com>, Heiner Kallweit <hkallweit1@...il.com>, 
	Heikki Krogerus <heikki.krogerus@...ux.intel.com>, linux-usb@...r.kernel.org, 
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] usb: Disable USB3 LPM at shutdown

On Tue, Mar 26, 2024 at 1:56 PM Greg KH <gregkh@...uxfoundation.org> wrote:
>
> On Tue, Mar 26, 2024 at 11:38:48AM +0800, Kai-Heng Feng wrote:
> > On Tue, Mar 5, 2024 at 2:52 PM Kai-Heng Feng
> > <kai.heng.feng@...onical.com> wrote:
> > >
> > > SanDisks USB3 storage may disapper after system reboot:
> > >
> > > usb usb2-port3: link state change
> > > xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x2c0
> > > usb usb2-port3: do warm reset, port only
> > > xhci_hcd 0000:00:14.0: xhci_hub_status_data: stopping usb2 port polling
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2b0, return 0x2b0
> > > usb usb2-port3: not warm reset yet, waiting 50ms
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2f0, return 0x2f0
> > > usb usb2-port3: not warm reset yet, waiting 200ms
> > > ...
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x6802c0, return 0x7002c0
> > > usb usb2-port3: not warm reset yet, waiting 200ms
> > > xhci_hcd 0000:00:14.0: clear port3 reset change, portsc: 0x4802c0
> > > xhci_hcd 0000:00:14.0: clear port3 warm(BH) reset change, portsc: 0x4002c0
> > > xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x2c0
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x2c0, return 0x2c0
> > > usb usb2-port3: not enabled, trying warm reset again...
> > >
> > > This is due to the USB device still cause port change event after xHCI is
> > > shuted down:
> > >
> > > xhci_hcd 0000:38:00.0: // Setting command ring address to 0xffffe001
> > > xhci_hcd 0000:38:00.0: xhci_resume: starting usb3 port polling.
> > > xhci_hcd 0000:38:00.0: xhci_hub_status_data: stopping usb4 port polling
> > > xhci_hcd 0000:38:00.0: xhci_hub_status_data: stopping usb3 port polling
> > > xhci_hcd 0000:38:00.0: hcd_pci_runtime_resume: 0
> > > xhci_hcd 0000:38:00.0: xhci_shutdown: stopping usb3 port polling.
> > > xhci_hcd 0000:38:00.0: // Halt the HC
> > > xhci_hcd 0000:38:00.0: xhci_shutdown completed - status = 1
> > > xhci_hcd 0000:00:14.0: xhci_shutdown: stopping usb1 port polling.
> > > xhci_hcd 0000:00:14.0: // Halt the HC
> > > xhci_hcd 0000:00:14.0: xhci_shutdown completed - status = 1
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1203, return 0x203
> > > xhci_hcd 0000:00:14.0: set port reset, actual port 2-3 status  = 0x1311
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x201203, return 0x100203
> > > xhci_hcd 0000:00:14.0: clear port3 reset change, portsc: 0x1203
> > > xhci_hcd 0000:00:14.0: clear port3 warm(BH) reset change, portsc: 0x1203
> > > xhci_hcd 0000:00:14.0: clear port3 link state change, portsc: 0x1203
> > > xhci_hcd 0000:00:14.0: clear port3 connect change, portsc: 0x1203
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1203, return 0x203
> > > usb 2-3: device not accepting address 2, error -108
> > > xhci_hcd 0000:00:14.0: xHCI dying or halted, can't queue_command
> > > xhci_hcd 0000:00:14.0: Set port 2-3 link state, portsc: 0x1203, write 0x11261
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x1263, return 0x263
> > > xhci_hcd 0000:00:14.0: set port reset, actual port 2-3 status  = 0x1271
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x12b1, return 0x2b1
> > > usb usb2-port3: not reset yet, waiting 60ms
> > > ACPI: PM: Preparing to enter system sleep state S5
> > > xhci_hcd 0000:00:14.0: Get port status 2-3 read: 0x12f1, return 0x2f1
> > > usb usb2-port3: not reset yet, waiting 200ms
> > > reboot: Restarting system
> > >
> > > The port change event is caused by LPM transition, so disabling LPM at shutdown
> > > to make sure the device is in U0 for warmboot.
> > >
> > > Signed-off-by: Kai-Heng Feng <kai.heng.feng@...onical.com>
> >
> > A gentle ping...
>
> It was the middle of the merge window, we couldn't do anything with new
> changes, right?
>
> And if you wish to see patches get merged quicker, please help review
> other patches on the list, that will reduce the workload of the
> maintainers.  Why haven't you done that while waiting?

Good suggestion. I'll start to review the patches on the list.

>
> thanks,
>
> greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ