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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 20 Apr 2022 10:09:05 -0400
From:   Alan Stern <stern@...land.harvard.edu>
To:     Oliver Neukum <oneukum@...e.com>
Cc:     Evan Green <evgreen@...omium.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Mathias Nyman <mathias.nyman@...el.com>,
        Rajat Jain <rajatja@...omium.org>,
        Bjorn Helgaas <bhelgaas@...gle.com>,
        "Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
        Razvan Heghedus <heghedus.razvan@...il.com>,
        Wei Ming Chen <jj251510319013@...il.com>,
        Youngjin Jang <yj84.jang@...sung.com>,
        linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [PATCH v2 0/2] USB: Quiesce interrupts across pm freeze

On Wed, Apr 20, 2022 at 10:47:27AM +0200, Oliver Neukum wrote:
> 
> 
> On 19.04.22 19:49, Alan Stern wrote:
> > On Tue, Apr 19, 2022 at 05:51:38PM +0200, Oliver Neukum wrote:
> >>
> >> On 19.04.22 16:35, Alan Stern wrote:
> >>> On Tue, Apr 19, 2022 at 09:05:53AM +0200, Oliver Neukum wrote:
> >>>
> >>>
> >>> The THAW part of suspend-to-hibernation is used only for writing the 
> >>> memory image to permanent storage.  I doubt that a malfunctioning HID 
> >>> device would interfere with this process.
> >>>
> >> True, if and only if all goes well. At the time thaw() has run writing
> >> the image to disk can still fail. In that case the devices will still
> >> be needed.
> > Consider adding a mechanism to usbcore which would allow an interface 
> > driver to request that the next time its device is resumed, the core 
> > should perform a reset-resume.  Would that help?
> >
> >
> 
> Strictly speaking no. We already have that in form of the RESET_RESUME
> quirk. The broken devices we are talking about here can do runtime PM
> perfectly fine, if and only if remote wakeup is requested.
> So we need that flag to translate only in freeze()/thaw() resulting in that
> behavior, as opposed to every pair of suspend()/resume()

That was my point.  The HID driver can check at suspend time whether or 
not remote wakeup will be enabled.  If yes, well and good, no changes 
are needed.  If not, the driver can then request that the following 
resume be a runtime-resume.

Another possibility is, as you mentioned before, adding a USB quirk for 
devices which require reset-resume whenever they are resumed with wakeup 
disabled.

Alan Stern

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ