[Bug 1642812] Re: USB devices are not closed when error occurs

Ɓukasz Zemczak 1642812 at bugs.launchpad.net
Thu Feb 15 11:21:14 UTC 2018


Hello Robert, or anyone else affected,

Accepted fwupd into xenial-proposed. The package will build now and be
available at https://launchpad.net/ubuntu/+source/fwupd/0.8.3-0ubuntu2
in a few hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested and change the tag from
verification-needed-xenial to verification-done-xenial. If it does not
fix the bug for you, please add a comment stating that, and change the
tag to verification-failed-xenial. In either case, without details of
your testing we will not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance!

** Tags added: verification-needed verification-needed-xenial

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1642812

Title:
  USB devices are not closed when error occurs

Status in fwupd package in Ubuntu:
  Fix Released
Status in fwupd source package in Xenial:
  Fix Committed
Status in fwupd source package in Yakkety:
  Won't Fix
Status in fwupd source package in Zesty:
  Fix Released

Bug description:
  [Impact]

   * fwupd (used in Xenial) does not close USB device nodes when it fails to process the 
  devices.

   * The orphan (un-closed) device node will be kept until fwupd ends

   * The behavior will avoid the system to set the USB device as
  idle/suspend then the system cannot enter some power-saving mode (eg.
  S0ix)

  
  [Test Case]

   * make sure fwupd is not running by executing 'fwupdmgr get-devices'
     It will show devices information.

   * list the fds opened by fwupd
     $ sudo ls -l /proc/$(pgrep fwupd)/fd | grep usb
     If a system is not affected, it will output nothing.
     If the result shows one or more strings like /dev/bus/usb/[BUS]/[DEV]
     (BUS and DEV are numeric variables), that means the issue is existing.

  
  [Regression Potential] 

   * The fix only closes file descriptors of USB devices when errors
  happen and should not have regression there.

  
  [Original description]
    In fwupd, a few of USB devices are not closed when there are some failures of 
    operations. This issue will cause fwupd has some orphan USB nodes inside during fwupd is 
    running. A orphan USB node might introduce memory leak and block some runtime power 
    features as well.

    I proposed a upstream PR, and also put the link here.
    https://github.com/hughsie/fwupd/pull/73

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/fwupd/+bug/1642812/+subscriptions



More information about the Ubuntu-sponsors mailing list