Bug 490577 - HAL sometimes doesn't emit udi-removed signals
HAL sometimes doesn't emit udi-removed signals
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: hal (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Richard Hughes
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-03-16 23:18 EDT by Dan Williams
Modified: 2009-06-04 20:46 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-06-04 20:46:20 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
FreeDesktop.org 20703 None None None Never

  None (edit)
Description Dan Williams 2009-03-16 23:18:18 EDT
Sierra 881 mobile broadband card.  When the mobile broadband connection is active in NetworkManager, pulling the card without disconnecting emits removal signals for some devices, but not for other devices:

Obligatory lshal --monitor output:

23:06:37.994: pci_1033_35 added
23:06:38.180: pci_1033_35_0 added
23:06:38.369: usb_device_1d6b_1_0000_03_00_0 added
23:06:38.476: usb_device_1d6b_1_0000_03_00_0_if0 added
23:06:38.614: usb_device_1d6b_1_0000_03_00_1 added
23:06:38.632: usb_device_1d6b_1_0000_03_00_1_if0 added
23:06:42.845: usb_device_1199_6851_noserial added
23:06:43.104: usb_device_1199_6851_noserial_if0 added
23:06:44.038: computer_power_supply_battery_BAT0 property battery.voltage.current = 12599 (0x3137)
23:06:45.990: usb_device_1199_6851_noserial_if0_serial_usb_0 added
23:06:46.098: usb_device_1199_6851_noserial_if0_serial_usb_2 added
23:06:48.127: usb_device_1199_6851_noserial_if0_serial_usb_3 added
23:06:48.215: usb_device_1199_6851_noserial_if0_serial_usb_1 added

(activate 3G connection)

23:07:14.063: computer_power_supply_battery_BAT0 property battery.voltage.current = 12604 (0x313c)
23:07:21.562: net_computer added

(pull card while 3G connection is active)

23:07:40.061: usb_device_1199_6851_noserial_if0 removed
23:07:40.100: usb_device_1199_6851_noserial removed
23:07:40.205: usb_device_1d6b_1_0000_03_00_0_if0 removed
23:07:40.264: usb_device_1d6b_1_0000_03_00_0 removed
23:07:40.365: pci_1033_35 removed
23:07:40.446: usb_device_1d6b_1_0000_03_00_1_if0 removed
23:07:40.490: usb_device_1d6b_1_0000_03_00_1 removed
23:07:40.611: pci_1033_35_0 removed
23:07:40.632: net_computer removed
23:07:44.056: computer_power_supply_battery_BAT0 property battery.voltage.current = 12599 (0x3137)


Notice how no device removal messages are sent for the following four serial TTYs:

usb_device_1199_6851_noserial_if0_serial_usb_0 added
usb_device_1199_6851_noserial_if0_serial_usb_2 added
usb_device_1199_6851_noserial_if0_serial_usb_3 added
usb_device_1199_6851_noserial_if0_serial_usb_1 added


NetworkManager kind of depends on HAL to send device-removal signals when a device gets removed, and if HAL doesn't do that, weird stuff happens, like the 3G card still showing up in the applet menu even though it's been pulled out, becuase HAL didn't send the removal signal, for the tty, and thus NM doesn't think the device has been removed.
Comment 1 Dan Williams 2009-03-16 23:45:16 EDT
See the referenced fdo bug for HAL and udev logs that show the issue.  The tty removal events always come last, *after* their parent devices, and apparently there's an error removing the device:

23:30:12.715 [I] osspec.c:247: SEQNUM=1424, ACTION=remove, SUBSYSTEM=usb-serial, DEVPATH=/sys/2-1:1.0/ttyUSB3, DEVNAME=, IFINDEX=0
23:30:12.715 [I] hotplug.c:435: checking event /sys/2-1:1.0/ttyUSB3
23:30:12.715 [I] device.c:4884: remove_dev: subsys=usb-serial sysfs_path=/sys/2-1:1.0/ttyUSB3
23:30:12.715 [W] device.c:4888: Error removing device
23:30:12.715 [D] hotplug.c:453: events queued = 0, events in progress = 0
23:30:12.715 [D] hotplug.c:458: Hotplug-queue empty now ... no hotplug events in progress
Comment 2 Chuck Ebbert 2009-06-04 20:46:20 EDT
This was a kernel bug, fixed in 2.6.30-rc, 2.6.27.23 and 2.6.29.3

Note You need to log in before you can comment on or make changes to this bug.