FS#40382 - [linux] system doesn't power off, just reboots

Attached to Project: Arch Linux
Opened by midixinga (midixinga) - Thursday, 15 May 2014, 22:24 GMT
Last edited by Tobias Powalowski (tpowa) - Monday, 16 June 2014, 10:52 GMT
Task Type Bug Report
Category Kernel
Status Closed
Assigned To Tobias Powalowski (tpowa)
Thomas Bächler (brain0)
Architecture x86_64
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

issue appers since Kernel 3.14.3, also with Kernel 3.14.4,
issue doesn't appear with Kernel 3.14.2

also reported to https://bugzilla.kernel.org/show_bug.cgi?id=76291

issue doesn't appear with disabled USB3.0 in Bios

Mainboard ASRock H87M Pro 4, UEFI-Mode, Arch Linux x84_64

lspci -vvv:
00:14.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 05) (prog-if 30 [XHCI])
Subsystem: ASRock Incorporation Device 8c31
Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 0
Interrupt: pin A routed to IRQ 42
Region 0: Memory at f0520000 (64-bit, non-prefetchable) [size=64K]
Capabilities: [70] Power Management version 2
Flags: PMEClk- DSI- D1- D2- AuxCurrent=375mA PME(D0-,D1-,D2-,D3hot+,D3cold+)
Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
Capabilities: [80] MSI: Enable+ Count=1/8 Maskable- 64bit+
Address: 00000000fee00298 Data: 0000
Kernel driver in use: xhci_hcd
Kernel modules: xhci_hcd

some system information files attached

unloading module xhci_hcd before shut down doesn't fix the problem
This task depends upon

Closed by  Tobias Powalowski (tpowa)
Monday, 16 June 2014, 10:52 GMT
Reason for closing:  Upstream
Comment by Tobias Powalowski (tpowa) - Friday, 16 May 2014, 16:49 GMT
Please bisect the kernel and report to kernel devs.
Comment by midixinga (midixinga) - Saturday, 17 May 2014, 18:48 GMT
I'm very unfamiliar with kernel, hardware, Compiling, ... and I didn't know which repository exactly to clone.

Thus I used:
git clone git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-stable
git bisect bad v3.14.3
git bisect good v3.14.2

My result:

Before last step:
[root@dixi-arch linux-stable]# git bisect bad
Bisecting: 0 revisions left to test after this (roughly 0 steps)
[e7573909b5b8df35591a66146d8629f7aa41675e] xhci: Prevent runtime pm from autosuspending during initialization

After last step:
[root@dixi-arch linux-stable]# git bisect good
5092b2b3c54eeb1a41329661d14289f59f81bdcb is the first bad commit
commit 5092b2b3c54eeb1a41329661d14289f59f81bdcb
Author: Denis Turischev <denis.turischev@compulab.co.il>
Date: Fri Apr 25 19:20:14 2014 +0300

xhci: Switch Intel Lynx Point ports to EHCI on shutdown.

commit c09ec25d3684cad74d851c0f028a495999591279 upstream.

The same issue like with Panther Point chipsets. If the USB ports are
switched to xHCI on shutdown, the xHCI host will send a spurious interrupt,
which will wake the system. Some BIOS have work around for this, but not all.
One example is Compulab's mini-desktop, the Intense-PC2.

The bug can be avoided if the USB ports are switched back to EHCI on
shutdown.

This patch should be backported to stable kernels as old as 3.12,
that contain the commit 638298dc66ea36623dbc2757a24fc2c4ab41b016
"xhci: Fix spurious wakeups after S5 on Haswell"

Signed-off-by: Denis Turischev <denis@compulab.co.il>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

:040000 040000 e178b761c73619963c1c130805e3722a9ccbdd7d 56b0434140c234293b1a34fb2e1f04fa2fd13d16 M drivers


I hope this helps, I will also report to https://bugzilla.kernel.org/show_bug.cgi?id=76291
Comment by midixinga (midixinga) - Saturday, 17 May 2014, 19:00 GMT
addendum:

for the .config I used
zcat /proc/config.gz > .config
make localmodconfig

If there were input questions I just presses "enter"
Comment by midixinga (midixinga) - Sunday, 18 May 2014, 18:38 GMT
BIOS Information
Vendor: American Megatrends Inc.
Version: P2.00
Release Date: 12/06/2013
Address: 0xF0000
Runtime Size: 64 kB
ROM Size: 8192 kB
Characteristics:
PCI is supported
BIOS is upgradeable
BIOS shadowing is allowed
Boot from CD is supported
Selectable boot is supported
BIOS ROM is socketed
EDD is supported
5.25"/1.2 MB floppy services are supported (int 13h)
3.5"/720 kB floppy services are supported (int 13h)
3.5"/2.88 MB floppy services are supported (int 13h)
Print screen service is supported (int 5h)
8042 keyboard services are supported (int 9h)
Serial services are supported (int 14h)
Printer services are supported (int 17h)
ACPI is supported
USB legacy is supported
BIOS boot specification is supported
Targeted content distribution is supported
UEFI is supported
BIOS Revision: 4.6
Comment by midixinga (midixinga) - Sunday, 18 May 2014, 18:40 GMT
final comment:

I build a customized Kernel with Arch Stock as basis; with only ONE change:

I deleted in Line 138, not in Line 121 in drivers/usb/host/xhci-pci.c

xhci->quirks |= XHCI_SPURIOUS_REBOOT;

and issue disappears -> everything works fine now

Comment by Tobias Powalowski (tpowa) - Monday, 19 May 2014, 06:34 GMT
Now you only need to send this information to the kernel devs, that they can fix this issue quick.
Comment by midixinga (midixinga) - Monday, 19 May 2014, 08:40 GMT
reported to kernel.org: https://bugzilla.kernel.org/show_bug.cgi?id=76291
and via mail to linux-usb[at]vger.kernel.org
Comment by midixinga (midixinga) - Monday, 19 May 2014, 09:54 GMT

Loading...