>-----Original Message----- >From: Jonathan Cameron <jic23@xxxxxxxxxx> >Sent: Monday, March 17, 2025 8:21 PM >To: Zhang, Lixu <lixu.zhang@xxxxxxxxx> >Cc: jikos@xxxxxxxxxx; srinivas.pandruvada@xxxxxxxxxxxxxxx; lars@xxxxxxxxxx; >linux-input@xxxxxxxxxxxxxxx; linux-iio@xxxxxxxxxxxxxxx; linux- >kernel@xxxxxxxxxxxxxxx >Subject: Re: [PATCH] iio: hid-sensor-prox: Add support for 16-bit report size > >On Mon, 17 Mar 2025 09:36:34 +0800 >Zhang Lixu <lixu.zhang@xxxxxxxxx> wrote: > >> On Intel platforms, the HID_USAGE_SENSOR_HUMAN_PROXIMITY report size >> is 16 bits. This patch adds support for handling 16-bit report sizes >> for the HID_USAGE_SENSOR_HUMAN_PROXIMITY usage in the HID sensor >proximity driver. >> >> Previously, the driver only supported 8-bit and 32-bit report sizes. >> With this change, the driver can now correctly process 16-bit >> proximity data, ensuring accurate human presence detection on >> platforms where this report size is used. >> >> Signed-off-by: Zhang Lixu <lixu.zhang@xxxxxxxxx> >> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@xxxxxxxxxxxxxxx> >Applied. Thanks. > >If it is reasonably urgent we could slip this in after rc1 as it smells a bit fix like. >For now I've queued it for next cycle. I don't think it's urgent, I'm fine with whatever. Thanks. Lixu >Jonathan > >> --- >> drivers/iio/light/hid-sensor-prox.c | 3 +++ >> 1 file changed, 3 insertions(+) >> >> diff --git a/drivers/iio/light/hid-sensor-prox.c >> b/drivers/iio/light/hid-sensor-prox.c >> index 76b76d12b388..3a7b48803d50 100644 >> --- a/drivers/iio/light/hid-sensor-prox.c >> +++ b/drivers/iio/light/hid-sensor-prox.c >> @@ -213,6 +213,9 @@ static int prox_capture_sample(struct >hid_sensor_hub_device *hsdev, >> case 1: >> prox_state->human_presence[chan] = *(u8 *)raw_data * >multiplier; >> return 0; >> + case 2: >> + prox_state->human_presence[chan] = *(u16 *)raw_data * >multiplier; >> + return 0; >> case 4: >> prox_state->human_presence[chan] = *(u32 *)raw_data * >multiplier; >> return 0; >> >> base-commit: eea255893718268e1ab852fb52f70c613d109b99