2017-08-21 16:44:03

by Arvind Yadav

[permalink] [raw]
Subject: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id

i2c_device_id are not supposed to change at runtime. All functions
working with i2c_device_id provided by <linux/i2c.h> work with
const i2c_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <[email protected]>
---
drivers/staging/iio/light/tsl2x7x.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/iio/light/tsl2x7x.c b/drivers/staging/iio/light/tsl2x7x.c
index 1467199..9b4425d 100644
--- a/drivers/staging/iio/light/tsl2x7x.c
+++ b/drivers/staging/iio/light/tsl2x7x.c
@@ -2010,7 +2010,7 @@ static int tsl2x7x_remove(struct i2c_client *client)
return 0;
}

-static struct i2c_device_id tsl2x7x_idtable[] = {
+static const struct i2c_device_id tsl2x7x_idtable[] = {
{ "tsl2571", tsl2571 },
{ "tsl2671", tsl2671 },
{ "tmd2671", tmd2671 },
--
2.7.4


2017-08-21 20:22:30

by Dan Carpenter

[permalink] [raw]
Subject: Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id

Don't say "[PATCH 4/4]". It's not a patchset or a part of an email
thread.

regards,
dan carpenter

2017-08-22 05:21:52

by Arvind Yadav

[permalink] [raw]
Subject: Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id

Hi


On Tuesday 22 August 2017 01:50 AM, Dan Carpenter wrote:
> Don't say "[PATCH 4/4]". It's not a patchset or a part of an email
> thread.
Yes, It's part of these patchset.
[PATCH 1/4] misc: apds9802als: constify i2c_device_id
[PATCH 2/4] misc: hmc6352: constify i2c_device_id
[PATCH 3/4] misc: isl29020: constify i2c_device_id
[PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id

>
> regards,
> dan carpenter
>
~arvind

2017-09-03 11:37:43

by Jonathan Cameron

[permalink] [raw]
Subject: Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id

On Tue, 22 Aug 2017 10:51:37 +0530
Arvind Yadav <[email protected]> wrote:

> Hi
>
>
> On Tuesday 22 August 2017 01:50 AM, Dan Carpenter wrote:
> > Don't say "[PATCH 4/4]". It's not a patchset or a part of an email
> > thread.
> Yes, It's part of these patchset.
> [PATCH 1/4] misc: apds9802als: constify i2c_device_id
> [PATCH 2/4] misc: hmc6352: constify i2c_device_id
> [PATCH 3/4] misc: isl29020: constify i2c_device_id
> [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id
For a series like this that is jumping around the kernel
it would have been better to have broken it up on a subsystem
basis. It is always confusing when people only see a small
part of a bigger series and need to go looking to find out
if they have missed something in the other patches.

Anyhow, applied to the togreg branch of iio.git which will
be pushed out as testing for the autobuilders to play with it.

Thanks,

Jonathan
>
> >
> > regards,
> > dan carpenter
> >
> ~arvind
> --
> To unsubscribe from this list: send the line "unsubscribe linux-iio" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html