fwupd crash on stop

Bug #1960768 reported by Yuan-Chen Cheng
50
This bug affects 4 people
Affects Status Importance Assigned to Milestone
OEM Priority Project
Fix Released
Critical
Yuan-Chen Cheng
fwupd (Ubuntu)
Invalid
Undecided
Unassigned
libgusb (Ubuntu)
Fix Released
Undecided
Unassigned
libusb (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

I can reproduce crash with a similar stack as below as I stop fwupd service.

https://errors.ubuntu.com/problem/4bfcf571c017010afe4775687ff2a9ca7ff79661

also test fwupd 1.7.5 (https://launchpad.net/~ycheng-twn/+archive/ubuntu/fwupd175)
still can reproduce this issue.

tags: added: jammy
Changed in oem-priority:
importance: Undecided → Critical
assignee: nobody → Yuan-Chen Cheng (ycheng-twn)
status: New → In Progress
tags: added: oem-priority
Revision history for this message
Yuan-Chen Cheng (ycheng-twn) wrote (last edit ):

I happened to install an impish iso with the previous libusb.

It seems to me that: after upgrading libusb, then this can be reproduced.

the version before and after is:

2:1.0.24-3build1
2:1.0.25~rc1-1

The journal logs before and after is:

Before
Feb 14 12:41:20 u-Latitude-5300 systemd[1]: Starting Firmware update daemon...
Feb 14 12:41:21 u-Latitude-5300 systemd[1]: Started Firmware update daemon.
Feb 14 12:41:23 u-Latitude-5300 systemd[1]: Stopping Firmware update daemon...

After:
Feb 14 12:41:43 u-Latitude-5300 systemd[1]: Starting Firmware update daemon...
Feb 14 12:41:44 u-Latitude-5300 systemd[1]: Started Firmware update daemon.
Feb 14 12:41:45 u-Latitude-5300 systemd[1]: Stopping Firmware update daemon...
Feb 14 12:41:45 u-Latitude-5300 fwupd[6455]: libusb: debug [libusb_unref_device] destroy device 1.3
Feb 14 12:41:46 u-Latitude-5300 systemd[1]: fwupd.service: Main process exited, code=dumped, status=11/SEGV
Feb 14 12:41:46 u-Latitude-5300 systemd[1]: fwupd.service: Failed with result 'core-dump'.
Feb 14 12:41:46 u-Latitude-5300 systemd[1]: Stopped Firmware update daemon.

Revision history for this message
Richard Hughes (richard-hughes) wrote :

I think Ubuntu probably needs gusb 0.3.9 or newer to fix this.

Revision history for this message
Mario Limonciello (superm1) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in fwupd (Ubuntu):
status: New → Confirmed
Changed in libgusb (Ubuntu):
status: New → Confirmed
Changed in libusb (Ubuntu):
status: New → Confirmed
Changed in fwupd (Ubuntu):
status: Confirmed → Invalid
Changed in libusb (Ubuntu):
status: Confirmed → Invalid
Revision history for this message
Yuan-Chen Cheng (ycheng-twn) wrote (last edit ):

debian sid now has libgusb version 0.3.10. And it's in jammy-proposed now.

Changed in libgusb (Ubuntu):
status: Confirmed → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libgusb - 0.3.10-1

---------------
libgusb (0.3.10-1) unstable; urgency=medium

  * New upstream version (0.3.10)
    - Fixes hangs on cleanup introduced in 0.3.8. (LP: #1960768)

 -- Mario Limonciello <email address hidden> Mon, 14 Feb 2022 10:37:07 -0600

Changed in libgusb (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Yuan-Chen Cheng (ycheng-twn) wrote :

I test the libgusb from jammy-proposed, and it fixed this issue on a machine that previously can reliably reproduce this issue.

Guess it's on it's way to jammy or jammy-update channel.

Changed in oem-priority:
status: In Progress → Fix Released
Revision history for this message
Yuan-Chen Cheng (ycheng-twn) wrote :

saw the new libgusb goes to jammy channel.

Revision history for this message
Brian Murray (brian-murray) wrote :

If fwupd is being backported to previous releases of Ubuntu it seems like libgusb would also need to be backported.

tags: added: rls-jj-incoming
Revision history for this message
Mario Limonciello (superm1) wrote :

> If fwupd is being backported to previous releases of Ubuntu it seems like libgusb would also need to be backported.

Actually the bug was introduced in libgusb 0.3.8, fixed in libgusb 0.3.9. If older releases have older than 0.3.8 they shouldn't need libgusb backport. See comment #3.

tags: removed: rls-jj-incoming
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.