diff options
| author | Christopher Hoover <ch@murgatroid.com> | 2026-10-18 19:34:20 -0700 |
|---|---|---|
| committer | Jonathan Cameron <jonathan.cameron@oss.qualcomm.com> | 2026-11-11 02:53:02 +0000 |
| commit | bbe4f3f668babc9443fc1f075695e43e17ca7976 (patch) | |
| tree | 758edf5c134aed8f991429c39fd406c62ee91d15 /kernel/debug/debug_core.c | |
| parent | 36eeb26031e90eeb81bbac3d3acad61d23fcbdf3 (diff) | |
iio: humidity: hid-sensor-humidity: Use per-instance callbacks
hid-sensor-humidity keeps a single static struct
hid_sensor_hub_callbacks for all instances and overwrites its pdev in
every probe, so with two humidity sensors, input reports for one are
delivered with the other's platform device, and a NULL dereference
follows once that device is removed. The same bug was found in
hid-sensor-temperature, which shares this code.
Keep the callbacks in struct hid_humidity_state, as the other HID
sensor drivers (accel, gyro, als, ...) do.
Fixes: d7ed89d5aadf ("iio: hid: Add humidity sensor support")
Cc: stable@vger.kernel.org
Signed-off-by: Christopher Hoover <ch@murgatroid.com>
Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com>
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
Diffstat (limited to 'kernel/debug/debug_core.c')
0 files changed, 0 insertions, 0 deletions
