* [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int'
@ 2026-04-19 18:05 Joshua Crofts
2026-04-20 8:42 ` Andy Shevchenko
2026-04-20 15:46 ` srinivas pandruvada
0 siblings, 2 replies; 4+ messages in thread
From: Joshua Crofts @ 2026-04-19 18:05 UTC (permalink / raw)
To: jikos, jic23, srinivas.pandruvada
Cc: dlechner, nuno.sa, andy, linux-input, linux-iio, linux-kernel,
Joshua Crofts
Use 'u32' instead of bare 'unsigned' to resolve checkpatch.pl warnings
and correct type use as defined in the hid_sensor_hub_callbacks struct.
No functional change.
Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com>
---
v2:
- changed 'unsigned int' to 'u32' per struct definition
drivers/iio/magnetometer/hid-sensor-magn-3d.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/iio/magnetometer/hid-sensor-magn-3d.c b/drivers/iio/magnetometer/hid-sensor-magn-3d.c
index c673f9323e..b01dd53eb1 100644
--- a/drivers/iio/magnetometer/hid-sensor-magn-3d.c
+++ b/drivers/iio/magnetometer/hid-sensor-magn-3d.c
@@ -280,7 +280,7 @@ static const struct iio_info magn_3d_info = {
/* Callback handler to send event after all samples are received and captured */
static int magn_3d_proc_event(struct hid_sensor_hub_device *hsdev,
- unsigned usage_id,
+ u32 usage_id,
void *priv)
{
struct iio_dev *indio_dev = platform_get_drvdata(priv);
@@ -302,7 +302,7 @@ static int magn_3d_proc_event(struct hid_sensor_hub_device *hsdev,
/* Capture samples in local storage */
static int magn_3d_capture_sample(struct hid_sensor_hub_device *hsdev,
- unsigned usage_id,
+ u32 usage_id,
size_t raw_len, char *raw_data,
void *priv)
{
@@ -350,7 +350,7 @@ static int magn_3d_parse_report(struct platform_device *pdev,
struct hid_sensor_hub_device *hsdev,
struct iio_chan_spec **channels,
int *chan_count,
- unsigned usage_id,
+ u32 usage_id,
struct magn_3d_state *st)
{
int i;
--
2.34.1
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int'
2026-04-19 18:05 [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int' Joshua Crofts
@ 2026-04-20 8:42 ` Andy Shevchenko
2026-04-20 15:46 ` srinivas pandruvada
1 sibling, 0 replies; 4+ messages in thread
From: Andy Shevchenko @ 2026-04-20 8:42 UTC (permalink / raw)
To: Joshua Crofts
Cc: jikos, jic23, srinivas.pandruvada, dlechner, nuno.sa, andy,
linux-input, linux-iio, linux-kernel
On Sun, Apr 19, 2026 at 08:05:23PM +0200, Joshua Crofts wrote:
> Use 'u32' instead of bare 'unsigned' to resolve checkpatch.pl warnings
> and correct type use as defined in the hid_sensor_hub_callbacks struct.
"...in the struct hid_sensor_hub_callbacks."
> No functional change.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int'
2026-04-19 18:05 [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int' Joshua Crofts
2026-04-20 8:42 ` Andy Shevchenko
@ 2026-04-20 15:46 ` srinivas pandruvada
2026-04-20 16:50 ` Andy Shevchenko
1 sibling, 1 reply; 4+ messages in thread
From: srinivas pandruvada @ 2026-04-20 15:46 UTC (permalink / raw)
To: Joshua Crofts, jikos, jic23
Cc: dlechner, nuno.sa, andy, linux-input, linux-iio, linux-kernel
On Sun, 2026-04-19 at 20:05 +0200, Joshua Crofts wrote:
> Use 'u32' instead of bare 'unsigned' to resolve checkpatch.pl
> warnings
> and correct type use as defined in the hid_sensor_hub_callbacks
> struct.
>
> No functional change.
>
> Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com>
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> ---
> v2:
> - changed 'unsigned int' to 'u32' per struct definition
>
> drivers/iio/magnetometer/hid-sensor-magn-3d.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/iio/magnetometer/hid-sensor-magn-3d.c
> b/drivers/iio/magnetometer/hid-sensor-magn-3d.c
> index c673f9323e..b01dd53eb1 100644
> --- a/drivers/iio/magnetometer/hid-sensor-magn-3d.c
> +++ b/drivers/iio/magnetometer/hid-sensor-magn-3d.c
> @@ -280,7 +280,7 @@ static const struct iio_info magn_3d_info = {
>
> /* Callback handler to send event after all samples are received and
> captured */
> static int magn_3d_proc_event(struct hid_sensor_hub_device *hsdev,
> - unsigned usage_id,
> + u32 usage_id,
> void *priv)
> {
> struct iio_dev *indio_dev = platform_get_drvdata(priv);
> @@ -302,7 +302,7 @@ static int magn_3d_proc_event(struct
> hid_sensor_hub_device *hsdev,
>
> /* Capture samples in local storage */
> static int magn_3d_capture_sample(struct hid_sensor_hub_device
> *hsdev,
> - unsigned usage_id,
> + u32 usage_id,
> size_t raw_len, char *raw_data,
> void *priv)
> {
> @@ -350,7 +350,7 @@ static int magn_3d_parse_report(struct
> platform_device *pdev,
> struct hid_sensor_hub_device *hsdev,
> struct iio_chan_spec **channels,
> int *chan_count,
> - unsigned usage_id,
> + u32 usage_id,
> struct magn_3d_state *st)
> {
> int i;
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int'
2026-04-20 15:46 ` srinivas pandruvada
@ 2026-04-20 16:50 ` Andy Shevchenko
0 siblings, 0 replies; 4+ messages in thread
From: Andy Shevchenko @ 2026-04-20 16:50 UTC (permalink / raw)
To: srinivas pandruvada
Cc: Joshua Crofts, jikos, jic23, dlechner, nuno.sa, andy, linux-input,
linux-iio, linux-kernel
On Mon, Apr 20, 2026 at 08:46:57AM -0700, srinivas pandruvada wrote:
> On Sun, 2026-04-19 at 20:05 +0200, Joshua Crofts wrote:
> > Use 'u32' instead of bare 'unsigned' to resolve checkpatch.pl
> > warnings
> > and correct type use as defined in the hid_sensor_hub_callbacks
> > struct.
> >
> > No functional change.
> >
> > Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com>
>
> Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
The Subject needs to be adjusted as well.
> > ---
> > v2:
> > - changed 'unsigned int' to 'u32' per struct definition
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-04-20 16:50 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-19 18:05 [PATCH v2] iio: magnetometer: hid-sensor-magn-3d: prefer 'unsigned int' Joshua Crofts
2026-04-20 8:42 ` Andy Shevchenko
2026-04-20 15:46 ` srinivas pandruvada
2026-04-20 16:50 ` Andy Shevchenko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox