Package: src:linux Version: 3.16.5-1 The touchpad (`SYN1B7D:01 06CB:2991 UNKNOWN` as reported by dmesg) of a friend's laptop stops working after suspending and resuming the laptop when using kernel 3.16. I cannot test older kernels as the laptop is quite new. The problem is solved in 3.17 with commit [109571c]. Since, AFAIK, Jessie will ship with kernel 3.16, please consider the attached patch, which adds [109571c] to `debian/patches/bugfix/all` and updates `debian/patches/series`.
[109571c]: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=109571cf3ec78a39477eedd6b11927f52cbcb1e8 Best regards, Joost
diff -Naur debian.orig/patches/bugfix/all/i2c-hid-suspend-resume-fix.patch debian/patches/bugfix/all/i2c-hid-suspend-resume-fix.patch --- debian.orig/patches/bugfix/all/i2c-hid-suspend-resume-fix.patch 1970-01-01 01:00:00.000000000 +0100 +++ debian/patches/bugfix/all/i2c-hid-suspend-resume-fix.patch 2014-10-11 15:35:34.774146332 +0200 @@ -0,0 +1,73 @@ +From 109571cf3ec78a39477eedd6b11927f52cbcb1e8 Mon Sep 17 00:00:00 2001 +From: Andrew Duggan <adug...@synaptics.com> +Date: Fri, 11 Jul 2014 16:34:18 -0700 +Subject: [PATCH] HID: i2c-hid: call the hid driver's suspend and resume + callbacks + +Currently, the i2c-hid driver does not call the suspend, resume, and +reset_resume callbacks in the hid_driver struct when those events occur. +This means that HID drivers for i2c-hid devices will not be able to execute +commands which may be needed during suspend or resume. One example is when a +touchpad using the hid-multitouch driver gets reset by i2c-hid coming out of +resume. Since the reset_resume callback never gets called the device is never +put back into the correct input mode. This patch calls the suspend and resume +callbacks and tries to duplicate the functionality of the usb-hid driver. + +Signed-off-by: Andrew Duggan <adug...@synaptics.com> +Signed-off-by: Vincent Huang <vincent.hu...@tw.synaptics.com> +Reviewed-by: Benjamin Tissoires <benjamin.tissoi...@redhat.com> +Signed-off-by: Jiri Kosina <jkos...@suse.cz> +--- + drivers/hid/i2c-hid/i2c-hid.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c +index 21aafc8..747d544 100644 +--- a/drivers/hid/i2c-hid/i2c-hid.c ++++ b/drivers/hid/i2c-hid/i2c-hid.c +@@ -1054,21 +1054,29 @@ static int i2c_hid_remove(struct i2c_client *client) + static int i2c_hid_suspend(struct device *dev) + { + struct i2c_client *client = to_i2c_client(dev); ++ struct i2c_hid *ihid = i2c_get_clientdata(client); ++ struct hid_device *hid = ihid->hid; ++ int ret = 0; + + disable_irq(client->irq); + if (device_may_wakeup(&client->dev)) + enable_irq_wake(client->irq); + ++ if (hid->driver && hid->driver->suspend) ++ ret = hid->driver->suspend(hid, PMSG_SUSPEND); ++ + /* Save some power */ + i2c_hid_set_power(client, I2C_HID_PWR_SLEEP); + +- return 0; ++ return ret; + } + + static int i2c_hid_resume(struct device *dev) + { + int ret; + struct i2c_client *client = to_i2c_client(dev); ++ struct i2c_hid *ihid = i2c_get_clientdata(client); ++ struct hid_device *hid = ihid->hid; + + enable_irq(client->irq); + ret = i2c_hid_hwreset(client); +@@ -1078,6 +1086,11 @@ static int i2c_hid_resume(struct device *dev) + if (device_may_wakeup(&client->dev)) + disable_irq_wake(client->irq); + ++ if (hid->driver && hid->driver->reset_resume) { ++ ret = hid->driver->reset_resume(hid); ++ return ret; ++ } ++ + return 0; + } + #endif +-- +2.1.1 + diff -Naur debian.orig/patches/series debian/patches/series --- debian.orig/patches/series 2014-10-10 04:16:39.000000000 +0200 +++ debian/patches/series 2014-10-11 15:35:49.733657053 +0200 @@ -110,6 +110,7 @@ debian/i2o-disable-i2o_ext_adaptec-on-64bit.patch bugfix/all/aic94xx-remove-broken-fallback-for-missing-ctrl-a.patch bugfix/all/builddeb-put-the-dbg-files-into-the-correct-director.patch +bugfix/all/i2c-hid-suspend-resume-fix.patch # memfd_create() & kdbus backport features/all/kdbus/mm-allow-drivers-to-prevent-new-writable-mappings.patch