Linux IIO development
 help / color / mirror / Atom feed
* [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs'
@ 2024-05-28 23:30 linux
  2024-05-29 11:24 ` Nuno Sá
  2024-05-29 14:34 ` Dan Carpenter
  0 siblings, 2 replies; 5+ messages in thread
From: linux @ 2024-05-28 23:30 UTC (permalink / raw)
  To: lars, Michael.Hennerich, jic23
  Cc: linux-iio, linux-staging, linux-kernel, Dr. David Alan Gilbert

From: "Dr. David Alan Gilbert" <linux@treblig.org>

'adt7316_limit_regs' has never been used since the original
commit 35f6b6b86ede ("staging: iio: new ADT7316/7/8 and ADT7516/7/9
driver").

The comment above it is a copy-and-paste from a different struct.

Remove both the struct and the comment.

Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
---
 drivers/staging/iio/addac/adt7316.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/staging/iio/addac/adt7316.c b/drivers/staging/iio/addac/adt7316.c
index 79467f056a05..23d036d2802c 100644
--- a/drivers/staging/iio/addac/adt7316.c
+++ b/drivers/staging/iio/addac/adt7316.c
@@ -209,14 +209,6 @@ struct adt7316_chip_info {
 #define ADT7316_TEMP_AIN_INT_MASK	\
 	(ADT7316_TEMP_INT_MASK)
 
-/*
- * struct adt7316_chip_info - chip specific information
- */
-
-struct adt7316_limit_regs {
-	u16	data_high;
-	u16	data_low;
-};
 
 static ssize_t adt7316_show_enabled(struct device *dev,
 				    struct device_attribute *attr,
-- 
2.45.1


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

* Re: [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs'
  2024-05-28 23:30 [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs' linux
@ 2024-05-29 11:24 ` Nuno Sá
  2024-05-29 14:34 ` Dan Carpenter
  1 sibling, 0 replies; 5+ messages in thread
From: Nuno Sá @ 2024-05-29 11:24 UTC (permalink / raw)
  To: linux, lars, Michael.Hennerich, jic23
  Cc: linux-iio, linux-staging, linux-kernel

On Wed, 2024-05-29 at 00:30 +0100, linux@treblig.org wrote:
> From: "Dr. David Alan Gilbert" <linux@treblig.org>
> 
> 'adt7316_limit_regs' has never been used since the original
> commit 35f6b6b86ede ("staging: iio: new ADT7316/7/8 and ADT7516/7/9
> driver").
> 
> The comment above it is a copy-and-paste from a different struct.
> 
> Remove both the struct and the comment.
> 
> Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> ---

Reviewed-by: Nuno Sa <nuno.sa@analog.com>

>  drivers/staging/iio/addac/adt7316.c | 8 --------
>  1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/staging/iio/addac/adt7316.c
> b/drivers/staging/iio/addac/adt7316.c
> index 79467f056a05..23d036d2802c 100644
> --- a/drivers/staging/iio/addac/adt7316.c
> +++ b/drivers/staging/iio/addac/adt7316.c
> @@ -209,14 +209,6 @@ struct adt7316_chip_info {
>  #define ADT7316_TEMP_AIN_INT_MASK	\
>  	(ADT7316_TEMP_INT_MASK)
>  
> -/*
> - * struct adt7316_chip_info - chip specific information
> - */
> -
> -struct adt7316_limit_regs {
> -	u16	data_high;
> -	u16	data_low;
> -};
>  
>  static ssize_t adt7316_show_enabled(struct device *dev,
>  				    struct device_attribute *attr,


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

* Re: [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs'
  2024-05-28 23:30 [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs' linux
  2024-05-29 11:24 ` Nuno Sá
@ 2024-05-29 14:34 ` Dan Carpenter
  2024-05-29 16:01   ` Dr. David Alan Gilbert
  1 sibling, 1 reply; 5+ messages in thread
From: Dan Carpenter @ 2024-05-29 14:34 UTC (permalink / raw)
  To: linux
  Cc: lars, Michael.Hennerich, jic23, linux-iio, linux-staging,
	linux-kernel

On Wed, May 29, 2024 at 12:30:08AM +0100, linux@treblig.org wrote:
> From: "Dr. David Alan Gilbert" <linux@treblig.org>
> 
> 'adt7316_limit_regs' has never been used since the original
> commit 35f6b6b86ede ("staging: iio: new ADT7316/7/8 and ADT7516/7/9
> driver").
> 
> The comment above it is a copy-and-paste from a different struct.
> 
> Remove both the struct and the comment.
> 
> Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> ---
>  drivers/staging/iio/addac/adt7316.c | 8 --------
>  1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/staging/iio/addac/adt7316.c b/drivers/staging/iio/addac/adt7316.c
> index 79467f056a05..23d036d2802c 100644
> --- a/drivers/staging/iio/addac/adt7316.c
> +++ b/drivers/staging/iio/addac/adt7316.c
> @@ -209,14 +209,6 @@ struct adt7316_chip_info {
>  #define ADT7316_TEMP_AIN_INT_MASK	\
>  	(ADT7316_TEMP_INT_MASK)
>  
> -/*
> - * struct adt7316_chip_info - chip specific information
> - */
> -
> -struct adt7316_limit_regs {
> -	u16	data_high;
> -	u16	data_low;
> -};
>  

Could you delete the blank line as well?  Otherwise we have two blank
lines in a row and checkpatch will complain.

regards,
dan carpenter



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

* Re: [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs'
  2024-05-29 14:34 ` Dan Carpenter
@ 2024-05-29 16:01   ` Dr. David Alan Gilbert
  2024-05-29 16:28     ` Dan Carpenter
  0 siblings, 1 reply; 5+ messages in thread
From: Dr. David Alan Gilbert @ 2024-05-29 16:01 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: lars, Michael.Hennerich, jic23, linux-iio, linux-staging,
	linux-kernel

* Dan Carpenter (dan.carpenter@linaro.org) wrote:
> On Wed, May 29, 2024 at 12:30:08AM +0100, linux@treblig.org wrote:
> > From: "Dr. David Alan Gilbert" <linux@treblig.org>
> > 
> > 'adt7316_limit_regs' has never been used since the original
> > commit 35f6b6b86ede ("staging: iio: new ADT7316/7/8 and ADT7516/7/9
> > driver").
> > 
> > The comment above it is a copy-and-paste from a different struct.
> > 
> > Remove both the struct and the comment.
> > 
> > Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> > ---
> >  drivers/staging/iio/addac/adt7316.c | 8 --------
> >  1 file changed, 8 deletions(-)
> > 
> > diff --git a/drivers/staging/iio/addac/adt7316.c b/drivers/staging/iio/addac/adt7316.c
> > index 79467f056a05..23d036d2802c 100644
> > --- a/drivers/staging/iio/addac/adt7316.c
> > +++ b/drivers/staging/iio/addac/adt7316.c
> > @@ -209,14 +209,6 @@ struct adt7316_chip_info {
> >  #define ADT7316_TEMP_AIN_INT_MASK	\
> >  	(ADT7316_TEMP_INT_MASK)
> >  
> > -/*
> > - * struct adt7316_chip_info - chip specific information
> > - */
> > -
> > -struct adt7316_limit_regs {
> > -	u16	data_high;
> > -	u16	data_low;
> > -};
> >  
> 
> Could you delete the blank line as well?  Otherwise we have two blank
> lines in a row and checkpatch will complain.

Sure, v2 sent.
(checkpatch didn't moan at me with or without).

Dave

> regards,
> dan carpenter
> 
> 
> 
-- 
 -----Open up your eyes, open up your mind, open up your code -------   
/ Dr. David Alan Gilbert    |       Running GNU/Linux       | Happy  \ 
\        dave @ treblig.org |                               | In Hex /
 \ _________________________|_____ http://www.treblig.org   |_______/

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

* Re: [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs'
  2024-05-29 16:01   ` Dr. David Alan Gilbert
@ 2024-05-29 16:28     ` Dan Carpenter
  0 siblings, 0 replies; 5+ messages in thread
From: Dan Carpenter @ 2024-05-29 16:28 UTC (permalink / raw)
  To: Dr. David Alan Gilbert
  Cc: lars, Michael.Hennerich, jic23, linux-iio, linux-staging,
	linux-kernel

On Wed, May 29, 2024 at 04:01:24PM +0000, Dr. David Alan Gilbert wrote:
> * Dan Carpenter (dan.carpenter@linaro.org) wrote:
> > On Wed, May 29, 2024 at 12:30:08AM +0100, linux@treblig.org wrote:
> > > From: "Dr. David Alan Gilbert" <linux@treblig.org>
> > > 
> > > 'adt7316_limit_regs' has never been used since the original
> > > commit 35f6b6b86ede ("staging: iio: new ADT7316/7/8 and ADT7516/7/9
> > > driver").
> > > 
> > > The comment above it is a copy-and-paste from a different struct.
> > > 
> > > Remove both the struct and the comment.
> > > 
> > > Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> > > ---
> > >  drivers/staging/iio/addac/adt7316.c | 8 --------
> > >  1 file changed, 8 deletions(-)
> > > 
> > > diff --git a/drivers/staging/iio/addac/adt7316.c b/drivers/staging/iio/addac/adt7316.c
> > > index 79467f056a05..23d036d2802c 100644
> > > --- a/drivers/staging/iio/addac/adt7316.c
> > > +++ b/drivers/staging/iio/addac/adt7316.c
> > > @@ -209,14 +209,6 @@ struct adt7316_chip_info {
> > >  #define ADT7316_TEMP_AIN_INT_MASK	\
> > >  	(ADT7316_TEMP_INT_MASK)
> > >  
> > > -/*
> > > - * struct adt7316_chip_info - chip specific information
> > > - */
> > > -
> > > -struct adt7316_limit_regs {
> > > -	u16	data_high;
> > > -	u16	data_low;
> > > -};
> > >  
> > 
> > Could you delete the blank line as well?  Otherwise we have two blank
> > lines in a row and checkpatch will complain.
> 
> Sure, v2 sent.
> (checkpatch didn't moan at me with or without).

Thanks.  You'd need to apply the patch and re-run checkpatch.pl with the
-f option.  It's not something that's obvious.

regards,
dan carpenter


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

end of thread, other threads:[~2024-05-29 16:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-28 23:30 [PATCH] staging: iio: adt7316: remove unused struct 'adt7316_limit_regs' linux
2024-05-29 11:24 ` Nuno Sá
2024-05-29 14:34 ` Dan Carpenter
2024-05-29 16:01   ` Dr. David Alan Gilbert
2024-05-29 16:28     ` Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox