diff options
author | Jim Broadus <jbroadus@gmail.com> | 2019-02-19 11:30:27 -0800 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2019-02-24 14:43:22 +0100 |
commit | 93b6604c5a669d84e45fe5129294875bf82eb1ff (patch) | |
tree | 07d6a5115257ca3c883421af21db513639977a00 /drivers/misc | |
parent | 088a8a7fb408d77b5c3029114f7ed457ed3ee715 (diff) | |
download | linux-stable-93b6604c5a669d84e45fe5129294875bf82eb1ff.tar.gz linux-stable-93b6604c5a669d84e45fe5129294875bf82eb1ff.tar.bz2 linux-stable-93b6604c5a669d84e45fe5129294875bf82eb1ff.zip |
i2c: Allow recovery of the initial IRQ by an I2C client device.
A previous change allowed I2C client devices to discover new IRQs upon
reprobe by clearing the IRQ in i2c_device_remove. However, if an IRQ was
assigned in i2c_new_device, that information is lost.
For example, the touchscreen and trackpad devices on a Dell Inspiron laptop
are I2C devices whose IRQs are defined by ACPI extended IRQ types. The
client device structures are initialized during an ACPI walk. After
removing the i2c_hid device, modprobe fails.
This change caches the initial IRQ value in i2c_new_device and then resets
the client device IRQ to the initial value in i2c_device_remove.
Fixes: 6f108dd70d30 ("i2c: Clear client->irq in i2c_device_remove")
Signed-off-by: Jim Broadus <jbroadus@gmail.com>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
[wsa: this is an easy to backport fix for the regression. We will
refactor the code to handle irq assignments better in general.]
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/misc')
0 files changed, 0 insertions, 0 deletions