On Tue, Apr 10, 2018 at 4:00 AM, Benjamin Tissoires <benjamin.tissoires@xxxxxxxxxx> wrote: > Hi Jean, > > On Tue, Apr 10, 2018 at 9:44 AM, Jean Delvare <jdelvare@xxxxxxx> wrote: >> Saving the original value of register SMBSLVCMD in >> i801_enable_host_notify() doesn't work, because this function is >> called not only at probe time but also at resume time. Do it in >> i801_probe() instead, so that the saved value is not overwritten at >> resume time. > > Sounds good. Thanks for spotting that! > And thanks Jason also for the quick tests in the other thread. Thanks, Ben. And thank you, Jean, for your great work. >> >> Signed-off-by: Jean Delvare <jdelvare@xxxxxxx> >> Fixes: 22e94bd6779e ("i2c: i801: store and restore the SLVCMD register at load and unload") >> Cc: Benjamin Tissoires <benjamin.tissoires@xxxxxxxxxx> >> Cc: Wolfram Sang <wsa@xxxxxxxxxxxxx> >> --- >> Jason, please test this patch and let us know if it fixes your problem. Unfortunately, no. For a normal power off, the subsequent boot hangs as I was seeing before. However, if I rmmod the driver first and then power off, the subsequent boot does not hang. Maybe i801_remove is only called on rmmod, but not shutdown? Do we need to define shutdown() for struct pci_driver? Regards, Jason > In any cases, this should go upstream and to stable I think. I agree with marking whatever we find for stable since I'm mainly following 4.14 at this time. Regards, Jason