Skip to contentSkip to conversation

patch "xhci: Fix xhci debugfs devices node disappearance after hibernation" added to usb-linus

PATCH [email protected] 1 participant 1 message Feb 15, 2018

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

xhci: Fix xhci debugfs devices node disappearance after hibernation

to my usb git tree which can be found at
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git
in the usb-linus branch.

The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.)

The patch will hopefully also be merged in Linus's tree for the next -rc kernel release.

If you have any questions about this process, please let me know.

Quoted 1 line

From d91676717261578f429d3577dbe9154b26e8abf7 Mon Sep 17 00:00:00 2001

From: Zhengjun Xing <[email protected]>
Date: Mon, 12 Feb 2018 14:24:49 +0200
Subject: xhci: Fix xhci debugfs devices node disappearance after hibernation

During system resume from hibernation, xhci host is reset, all the nodes in devices folder are removed in xhci_mem_cleanup function. Later nodes in /sys/kernel/debug/usb/xhci/* are created again in function xhci_run, but the nodes already exist, so the nodes still keep the old ones, finally device nodes in xhci debugfs folder /sys/kernel/debug/usb/xhci/*/devices/* are disappeared.

This fix removed xhci debugfs nodes before the nodes are re-created, so all the nodes in xhci debugfs can be re-created successfully.

Fixes 02b6fdc2a153 ("usb: xhci: Add debugfs interface for xHCI driver")
Cc <[email protected]> # v4.15
---
 drivers/usb/host/xhci.c | 1 +
 1 file changed, 1 insertion(+)
drivers/usb/host/xhci.c +1 -0
index 1eeb3396300f..b01bd643f905 100644
@@ -1014,6 +1014,7 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated)
 
 		xhci_dbg(xhci, "cleaning up memory\n");
 		xhci_mem_cleanup(xhci);
+		xhci_debugfs_exit(xhci);
 		xhci_dbg(xhci, "xhci_stop completed - status = %x\n",
 			    readl(&xhci->op_regs->status));
 
Signature · 1 line
2.16.1