linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id
@ 2017-08-21 16:43 Arvind Yadav
  2017-08-21 20:20 ` Dan Carpenter
  0 siblings, 1 reply; 4+ messages in thread
From: Arvind Yadav @ 2017-08-21 16:43 UTC (permalink / raw)
  To: arnd, gregkh, knaack.h, pmeerw, lars; +Cc: linux-kernel, devel, linux-iio

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 <arvind.yadav.cs@gmail.com>
---
 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

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id
  2017-08-21 16:43 [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id Arvind Yadav
@ 2017-08-21 20:20 ` Dan Carpenter
  2017-08-22  5:21   ` Arvind Yadav
  0 siblings, 1 reply; 4+ messages in thread
From: Dan Carpenter @ 2017-08-21 20:20 UTC (permalink / raw)
  To: Arvind Yadav
  Cc: arnd, gregkh, knaack.h, pmeerw, lars, devel, linux-iio, linux-kernel

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

regards,
dan carpenter

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id
  2017-08-21 20:20 ` Dan Carpenter
@ 2017-08-22  5:21   ` Arvind Yadav
  2017-09-03 11:37     ` Jonathan Cameron
  0 siblings, 1 reply; 4+ messages in thread
From: Arvind Yadav @ 2017-08-22  5:21 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: arnd, gregkh, knaack.h, pmeerw, lars, devel, linux-iio, linux-kernel

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

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id
  2017-08-22  5:21   ` Arvind Yadav
@ 2017-09-03 11:37     ` Jonathan Cameron
  0 siblings, 0 replies; 4+ messages in thread
From: Jonathan Cameron @ 2017-09-03 11:37 UTC (permalink / raw)
  To: Arvind Yadav
  Cc: Dan Carpenter, arnd, gregkh, knaack.h, pmeerw, lars, devel,
	linux-iio, linux-kernel

On Tue, 22 Aug 2017 10:51:37 +0530
Arvind Yadav <arvind.yadav.cs@gmail.com> 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 majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-09-03 11:37 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-21 16:43 [PATCH 4/4] staging: iio: tsl2x7x: constify i2c_device_id Arvind Yadav
2017-08-21 20:20 ` Dan Carpenter
2017-08-22  5:21   ` Arvind Yadav
2017-09-03 11:37     ` Jonathan Cameron

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).