Bug 112351

Summary: jme driver breaks suspend/resume
Product: Drivers Reporter: Diego Viola (diego.viola)
Component: NetworkAssignee: drivers_network (drivers_network)
Severity: normal    
Priority: P1    
Hardware: x86-64   
OS: Linux   
Kernel Version: 4.4.1-2-ARCH Tree: Mainline
Regression: No
Attachments: lspci

Description Diego Viola 2016-02-12 07:44:19 UTC
I have this network card:

02:00.0 Ethernet controller: JMicron Technology Corp. JMC260 PCI Express Fast Ethernet Controller (rev 03)

Every time I initiate a suspend 'systemctl suspend' the machine hangs at resume unless I unload the jme driver.

I can also suspend the computer when the driver is loaded but when the link is down: 'ip link set ens34 down'

However, as soon as the link is up, the hang occurs again.

Here is a call trace I was able to get after it hanged:


jme_start_irq+0x84/0xa0 [jme]
jme_resume+0x12f/0x210 [jme]
? pci_pm_thaw+0x90/0x90
? process_one_work+0x440/0x440
? kthread_worker_fn+0x170/0x170
? kthread_worker_fn+0x170/0x170

I run Arch Linux (x86-64), I also tried compiling the latest kernel from git but the problem is still there, I also went back to Linux 3.11 so I could try to git bisect the issue, but the problem was there in the 3.11 kernel as well.

Please let me know if you need any other information.
Comment 1 Diego Viola 2016-02-12 07:53:34 UTC
This is on a desktop computer BTW, not a laptop.
Comment 2 Diego Viola 2016-02-13 00:23:18 UTC
Created attachment 203571 [details]
Comment 3 Diego Viola 2016-02-13 00:24:11 UTC
Created attachment 203581 [details]
Comment 4 Diego Viola 2016-02-13 01:54:41 UTC
I think this is probably a race condition, because I managed to resume from suspend a few times while testing this, and when the device was up, but this happened very random and it was rare.

Most of the time (99% of the time) it just hangs after resume from suspend.
Comment 5 Diego Viola 2016-02-13 01:57:40 UTC
I mean, the hang only occurs when the device is up, if the device is down (ip link set ens34 down) the hang doesn't occur.
Comment 6 Diego Viola 2016-02-13 18:42:11 UTC
Tried all these parameters from the module, no effect:

parm:           force_pseudohp:Enable pseudo hot-plug feature manually by driver instead of BIOS. (int)
parm:           no_pseudohp:Disable pseudo hot-plug feature. (int)
parm:           no_extplug:Do not use external plug signal for pseudo hot-plug. (int)
Comment 7 Diego Viola 2016-02-13 20:39:27 UTC
So I found that disabling async helps with my issue, e.g.

$ echo 0 > /sys/power/pm_async

I can't reproduce the hang anymore, tried suspend/resume almost ~15 times.
Comment 8 Diego Viola 2016-02-20 17:57:31 UTC
Anyone please?
Comment 9 Diego Viola 2016-02-23 00:40:29 UTC
Fixed here: