Control: tag -1 +confirmed

On Thu, 2016-05-26 at 16:38 +0530, Ritesh Raj Sarraf wrote:
> On Thu, 2016-05-26 at 15:35 +0530, Ritesh Raj Sarraf wrote:
> > 
> > On Mon, 2016-05-23 at 20:30 -0500, Samuel Smith wrote:
> > > May 23 19:58:37 t61 laptop-mode: Module 
> > > /usr/share/laptop-mode-tools/modules/wireless-ipw-power is not 
> > > executable or is to be skipped.
> > > May 23 19:58:37 t61 laptop-mode: Module 
> > > /usr/share/laptop-mode-tools/modules/wireless-iwl-power is not 
> > > executable or is to be skipped.
> > > May 23 19:58:37 t61 laptop-mode: Module 
> > > /usr/share/laptop-mode-tools/modules/wireless-power is not executable or 
> > > is to be skipped.
> > 
> > Almost all shipped modules are disabled in your setup. Is that intentional ?
> 
> please ignore this question. This log must be part of the USB event
> invocation,
> which is just for the USB module


Here's what I think must be happening.

Looking at your initial logs, it seems the USB subsystem generated too many
events, thus discarding the events from other subsystems.

Your mentioned workaround (that of disabling USB events in udev rules) works
because that results in ignoring all USB events. The only side effect to it is
that hotplugged USB devices won't have updated power management policy.


Now, how do we fix this ?

Note to self: If we can tag machinecheck and power_supply events, then we may
treat them as urgent events and process them with a higher precedence.
At this moment, LMT acquires an inner lock and then left out is the outer lock.
But there is no logic for a queue in place. It is just FIFO, which results in
any event able to acquire the locks (both inner and outer), which is the case in
this bug report where usb events acquire both.

Samuel: I'm afraid I don't immediately have the time/thought of a fix. Given
that you have a workaround, I'll keep this bug open for future. Meanwhile, can
you check if the below events are seen during an undock? Can you confirm that?


If this is a case of flaky usb device, then we don't really have a bug in LMT.
But you can avoid this erratic state by blacklisting the particular usb device
id.



**********************************************************************
Change events from a docking event:



# udevadm monitor
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[81944.128231] change   /devices/pci0000:00/0000:00:02.0/drm/card0 
(drm)
UDEV  [81944.155550] change   /devices/pci0000:00/0000:00:02.0/drm/card0 
(drm)
KERNEL[81944.424952] change 
/devices/pci0000:00/0000:00:02.0/backlight/acpi_video0 (backlight)
UDEV  [81944.425364] change 
/devices/pci0000:00/0000:00:02.0/backlight/acpi_video0 (backlight)
KERNEL[81944.517313] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5 (usb)
KERNEL[81944.517708] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5:1.0 (usb)
UDEV  [81944.523026] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5 (usb)
UDEV  [81944.525192] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5:1.0 (usb)
KERNEL[81944.880865] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5 (usb)
KERNEL[81944.881060] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5:1.0 (usb)
UDEV  [81944.884247] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5 (usb)
UDEV  [81944.886437] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5:1.0 (usb)
KERNEL[81945.287146] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2 (usb)
KERNEL[81945.291063] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-1.5.5.2:1.0 
(usb)
KERNEL[81945.294924] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B 
(hid)
KERNEL[81945.295067] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/input/input44 
(input)
KERNEL[81945.295116] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/input/input44/event17 
(input)
KERNEL[81945.295204] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/hidraw/hidraw0 
(hidraw)
KERNEL[81945.297437] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-1.5.5.2:1.1 
(usb)
KERNEL[81945.305681] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C 
(hid)
KERNEL[81945.310643] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/input/input45 
(input)
KERNEL[81945.310726] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/input/input45/event18 
(input)
KERNEL[81945.310863] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/hidraw/hidraw1 
(hidraw)
UDEV  [81945.314872] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2 (usb)
UDEV  [81945.316755] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-1.5.5.2:1.0 
(usb) 

UDEV  [81945.317501] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B 
(hid) 

UDEV  [81945.317601] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-1.5.5.2:1.1 
(usb) 

UDEV  [81945.318481] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/input/input44 
(input) 

UDEV  [81945.319877] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/hidraw/hidraw0 
(hidraw) 

UDEV  [81945.319953] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C 
(hid) 

UDEV  [81945.320778] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/hidraw/hidraw1 
(hidraw) 

UDEV  [81945.320964] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.0/0003:04B4:0101.001B/input/input44/event17 
(input) 

UDEV  [81945.321128] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/input/input45 
(input) 

UDEV  [81945.322428] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.2/1-
1.5.5.2:1.1/0003:04B4:0101.001C/input/input45/event18 
(input) 

KERNEL[81945.509656] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3 (usb) 
 

KERNEL[81945.511493] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-1.5.5.3:1.0 
(usb) 

KERNEL[81945.514949] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D 
(hid)
KERNEL[81945.515065] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46 
(input)
KERNEL[81945.515139] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46/mouse2 
(input)
KERNEL[81945.515189] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46/event19 
(input)
KERNEL[81945.515252] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/hidraw/hidraw2 
(hidraw)
UDEV  [81945.520749] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3 (usb)
UDEV  [81945.525008] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-1.5.5.3:1.0 
(usb)
UDEV  [81945.529408] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D 
(hid)
UDEV  [81945.530203] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/hidraw/hidraw2 
(hidraw)
UDEV  [81945.530463] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46 
(input)
UDEV  [81945.532042] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46/event19 
(input)
UDEV  [81945.532533] add 
/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.5/1-1.5.5/1-1.5.5.3/1-
1.5.5.3:1.0/0003:046D:C069.001D/input/input46/mouse2 
(input)
KERNEL[81945.609438] change 
/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/device:08/PNP0C09:00/ACPI0003:00/pow
er_supply/AC 
(power_supply)
UDEV  [81945.617012] change 
/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/device:08/PNP0C09:00/ACPI0003:00/pow
er_supply/AC 
(power_supply)
KERNEL[81945.718105] change 
/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/device:08/PNP0C09:00/PNP0C0A:00/powe
r_supply/BAT0 
(power_supply)
UDEV  [81945.718875] change 
/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/device:08/PNP0C09:00/PNP0C0A:00/powe
r_supply/BAT0 
(power_supply)
*************************************************************************


-- 
Ritesh Raj Sarraf | http://people.debian.org/~rrs
Debian - The Universal Operating System

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to