Linux IIO development
 help / color / mirror / Atom feed
* [PATCH 0/2] Remove ad9832.h and ad9834.h header files in drivers/staging/iio/frequency
@ 2025-10-06  9:40 Taimoor Zaeem
  2025-10-06  9:40 ` [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file Taimoor Zaeem
  2025-10-06  9:40 ` [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c Taimoor Zaeem
  0 siblings, 2 replies; 5+ messages in thread
From: Taimoor Zaeem @ 2025-10-06  9:40 UTC (permalink / raw)
  To: jic23, gregkh; +Cc: linux-iio, linux-staging, Taimoor Zaeem

This patch series removes ad9832.h and ad9834.h header files.

PATCH 1/2: staging: iio: ad9834: remove empty ad9834.h file
PATCH 2/2: staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c

Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>

 drivers/staging/iio/frequency/ad9832.c | 21 ++++++++++++++--
 drivers/staging/iio/frequency/ad9832.h | 33 --------------------------
 drivers/staging/iio/frequency/ad9834.c |  3 +--
 drivers/staging/iio/frequency/ad9834.h | 10 --------
 4 files changed, 20 insertions(+), 47 deletions(-)
 delete mode 100644 drivers/staging/iio/frequency/ad9832.h
 delete mode 100644 drivers/staging/iio/frequency/ad9834.h

-- 
2.51.0


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

* [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file
  2025-10-06  9:40 [PATCH 0/2] Remove ad9832.h and ad9834.h header files in drivers/staging/iio/frequency Taimoor Zaeem
@ 2025-10-06  9:40 ` Taimoor Zaeem
  2025-10-12 14:17   ` Jonathan Cameron
  2025-10-06  9:40 ` [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c Taimoor Zaeem
  1 sibling, 1 reply; 5+ messages in thread
From: Taimoor Zaeem @ 2025-10-06  9:40 UTC (permalink / raw)
  To: jic23, gregkh; +Cc: linux-iio, linux-staging, Taimoor Zaeem

Remove drivers/staging/iio/frequency/ad9834.h header file
because it contains nothing except the include guards.

Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>
---
 drivers/staging/iio/frequency/ad9834.c |  3 +--
 drivers/staging/iio/frequency/ad9834.h | 10 ----------
 2 files changed, 1 insertion(+), 12 deletions(-)
 delete mode 100644 drivers/staging/iio/frequency/ad9834.h

diff --git a/drivers/staging/iio/frequency/ad9834.c b/drivers/staging/iio/frequency/ad9834.c
index 0038eb234d40..d339d5e8e043 100644
--- a/drivers/staging/iio/frequency/ad9834.c
+++ b/drivers/staging/iio/frequency/ad9834.c
@@ -21,9 +21,8 @@
 
 #include <linux/iio/iio.h>
 #include <linux/iio/sysfs.h>
-#include "dds.h"
 
-#include "ad9834.h"
+#include "dds.h"
 
 /* Registers */
 
diff --git a/drivers/staging/iio/frequency/ad9834.h b/drivers/staging/iio/frequency/ad9834.h
deleted file mode 100644
index 521943aa0e61..000000000000
--- a/drivers/staging/iio/frequency/ad9834.h
+++ /dev/null
@@ -1,10 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-/*
- * AD9833/AD9834/AD9837/AD9838 SPI DDS driver
- *
- * Copyright 2010-2011 Analog Devices Inc.
- */
-#ifndef IIO_DDS_AD9834_H_
-#define IIO_DDS_AD9834_H_
-
-#endif /* IIO_DDS_AD9834_H_ */
-- 
2.51.0


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

* [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c
  2025-10-06  9:40 [PATCH 0/2] Remove ad9832.h and ad9834.h header files in drivers/staging/iio/frequency Taimoor Zaeem
  2025-10-06  9:40 ` [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file Taimoor Zaeem
@ 2025-10-06  9:40 ` Taimoor Zaeem
  2025-10-07 12:48   ` Jonathan Cameron
  1 sibling, 1 reply; 5+ messages in thread
From: Taimoor Zaeem @ 2025-10-06  9:40 UTC (permalink / raw)
  To: jic23, gregkh; +Cc: linux-iio, linux-staging, Taimoor Zaeem

The struct ad9832_platform_data is only used in ad9832.c
so it moved there instead. With this change, the ad9832.h
file becomes empty, so we can remove it.

Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>
---
 drivers/staging/iio/frequency/ad9832.c | 21 ++++++++++++++--
 drivers/staging/iio/frequency/ad9832.h | 33 --------------------------
 2 files changed, 19 insertions(+), 35 deletions(-)
 delete mode 100644 drivers/staging/iio/frequency/ad9832.h

diff --git a/drivers/staging/iio/frequency/ad9832.c b/drivers/staging/iio/frequency/ad9832.c
index 49388da5a684..0517858bc5da 100644
--- a/drivers/staging/iio/frequency/ad9832.c
+++ b/drivers/staging/iio/frequency/ad9832.c
@@ -23,8 +23,6 @@
 #include <linux/iio/iio.h>
 #include <linux/iio/sysfs.h>
 
-#include "ad9832.h"
-
 #include "dds.h"
 
 /* Registers */
@@ -117,6 +115,25 @@ struct ad9832_state {
 	} __aligned(IIO_DMA_MINALIGN);
 };
 
+/**
+ * struct ad9832_platform_data - platform specific information
+ * @freq0:		power up freq0 tuning word in Hz
+ * @freq1:		power up freq1 tuning word in Hz
+ * @phase0:		power up phase0 value [0..4095] correlates with 0..2PI
+ * @phase1:		power up phase1 value [0..4095] correlates with 0..2PI
+ * @phase2:		power up phase2 value [0..4095] correlates with 0..2PI
+ * @phase3:		power up phase3 value [0..4095] correlates with 0..2PI
+ */
+
+struct ad9832_platform_data {
+	unsigned long		freq0;
+	unsigned long		freq1;
+	unsigned short		phase0;
+	unsigned short		phase1;
+	unsigned short		phase2;
+	unsigned short		phase3;
+};
+
 static unsigned long ad9832_calc_freqreg(unsigned long mclk, unsigned long fout)
 {
 	unsigned long long freqreg = (u64)fout *
diff --git a/drivers/staging/iio/frequency/ad9832.h b/drivers/staging/iio/frequency/ad9832.h
deleted file mode 100644
index d0d840edb8d2..000000000000
--- a/drivers/staging/iio/frequency/ad9832.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0+ */
-/*
- * AD9832 SPI DDS driver
- *
- * Copyright 2011 Analog Devices Inc.
- */
-#ifndef IIO_DDS_AD9832_H_
-#define IIO_DDS_AD9832_H_
-
-/*
- * TODO: struct ad9832_platform_data needs to go into include/linux/iio
- */
-
-/**
- * struct ad9832_platform_data - platform specific information
- * @freq0:		power up freq0 tuning word in Hz
- * @freq1:		power up freq1 tuning word in Hz
- * @phase0:		power up phase0 value [0..4095] correlates with 0..2PI
- * @phase1:		power up phase1 value [0..4095] correlates with 0..2PI
- * @phase2:		power up phase2 value [0..4095] correlates with 0..2PI
- * @phase3:		power up phase3 value [0..4095] correlates with 0..2PI
- */
-
-struct ad9832_platform_data {
-	unsigned long		freq0;
-	unsigned long		freq1;
-	unsigned short		phase0;
-	unsigned short		phase1;
-	unsigned short		phase2;
-	unsigned short		phase3;
-};
-
-#endif /* IIO_DDS_AD9832_H_ */
-- 
2.51.0


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

* Re: [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c
  2025-10-06  9:40 ` [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c Taimoor Zaeem
@ 2025-10-07 12:48   ` Jonathan Cameron
  0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Cameron @ 2025-10-07 12:48 UTC (permalink / raw)
  To: Taimoor Zaeem; +Cc: jic23, gregkh, linux-iio, linux-staging

On Mon,  6 Oct 2025 14:40:25 +0500
Taimoor Zaeem <taimoorzaeem@gmail.com> wrote:

> The struct ad9832_platform_data is only used in ad9832.c
> so it moved there instead. With this change, the ad9832.h
> file becomes empty, so we can remove it.
> 
> Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>

Hi.

See my reply to earlier thread for why this makes no sense and what
needs doing to actually get rid of the platform data in general
(and hence the header).

Thanks,

Jonathan



> ---
>  drivers/staging/iio/frequency/ad9832.c | 21 ++++++++++++++--
>  drivers/staging/iio/frequency/ad9832.h | 33 --------------------------
>  2 files changed, 19 insertions(+), 35 deletions(-)
>  delete mode 100644 drivers/staging/iio/frequency/ad9832.h
> 
> diff --git a/drivers/staging/iio/frequency/ad9832.c b/drivers/staging/iio/frequency/ad9832.c
> index 49388da5a684..0517858bc5da 100644
> --- a/drivers/staging/iio/frequency/ad9832.c
> +++ b/drivers/staging/iio/frequency/ad9832.c
> @@ -23,8 +23,6 @@
>  #include <linux/iio/iio.h>
>  #include <linux/iio/sysfs.h>
>  
> -#include "ad9832.h"
> -
>  #include "dds.h"
>  
>  /* Registers */
> @@ -117,6 +115,25 @@ struct ad9832_state {
>  	} __aligned(IIO_DMA_MINALIGN);
>  };
>  
> +/**
> + * struct ad9832_platform_data - platform specific information
> + * @freq0:		power up freq0 tuning word in Hz
> + * @freq1:		power up freq1 tuning word in Hz
> + * @phase0:		power up phase0 value [0..4095] correlates with 0..2PI
> + * @phase1:		power up phase1 value [0..4095] correlates with 0..2PI
> + * @phase2:		power up phase2 value [0..4095] correlates with 0..2PI
> + * @phase3:		power up phase3 value [0..4095] correlates with 0..2PI
> + */
> +
> +struct ad9832_platform_data {
> +	unsigned long		freq0;
> +	unsigned long		freq1;
> +	unsigned short		phase0;
> +	unsigned short		phase1;
> +	unsigned short		phase2;
> +	unsigned short		phase3;
> +};
> +
>  static unsigned long ad9832_calc_freqreg(unsigned long mclk, unsigned long fout)
>  {
>  	unsigned long long freqreg = (u64)fout *
> diff --git a/drivers/staging/iio/frequency/ad9832.h b/drivers/staging/iio/frequency/ad9832.h
> deleted file mode 100644
> index d0d840edb8d2..000000000000
> --- a/drivers/staging/iio/frequency/ad9832.h
> +++ /dev/null
> @@ -1,33 +0,0 @@
> -/* SPDX-License-Identifier: GPL-2.0+ */
> -/*
> - * AD9832 SPI DDS driver
> - *
> - * Copyright 2011 Analog Devices Inc.
> - */
> -#ifndef IIO_DDS_AD9832_H_
> -#define IIO_DDS_AD9832_H_
> -
> -/*
> - * TODO: struct ad9832_platform_data needs to go into include/linux/iio
> - */
> -
> -/**
> - * struct ad9832_platform_data - platform specific information
> - * @freq0:		power up freq0 tuning word in Hz
> - * @freq1:		power up freq1 tuning word in Hz
> - * @phase0:		power up phase0 value [0..4095] correlates with 0..2PI
> - * @phase1:		power up phase1 value [0..4095] correlates with 0..2PI
> - * @phase2:		power up phase2 value [0..4095] correlates with 0..2PI
> - * @phase3:		power up phase3 value [0..4095] correlates with 0..2PI
> - */
> -
> -struct ad9832_platform_data {
> -	unsigned long		freq0;
> -	unsigned long		freq1;
> -	unsigned short		phase0;
> -	unsigned short		phase1;
> -	unsigned short		phase2;
> -	unsigned short		phase3;
> -};
> -
> -#endif /* IIO_DDS_AD9832_H_ */


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

* Re: [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file
  2025-10-06  9:40 ` [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file Taimoor Zaeem
@ 2025-10-12 14:17   ` Jonathan Cameron
  0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Cameron @ 2025-10-12 14:17 UTC (permalink / raw)
  To: Taimoor Zaeem; +Cc: gregkh, linux-iio, linux-staging

On Mon,  6 Oct 2025 14:40:24 +0500
Taimoor Zaeem <taimoorzaeem@gmail.com> wrote:

> Remove drivers/staging/iio/frequency/ad9834.h header file
> because it contains nothing except the include guards.
> 
Odd!  I guess left over after some other cleanup at somepoint.

Applied.

Thanks for cleaning this up.

Jonathan

> Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>
> ---
>  drivers/staging/iio/frequency/ad9834.c |  3 +--
>  drivers/staging/iio/frequency/ad9834.h | 10 ----------
>  2 files changed, 1 insertion(+), 12 deletions(-)
>  delete mode 100644 drivers/staging/iio/frequency/ad9834.h
> 
> diff --git a/drivers/staging/iio/frequency/ad9834.c b/drivers/staging/iio/frequency/ad9834.c
> index 0038eb234d40..d339d5e8e043 100644
> --- a/drivers/staging/iio/frequency/ad9834.c
> +++ b/drivers/staging/iio/frequency/ad9834.c
> @@ -21,9 +21,8 @@
>  
>  #include <linux/iio/iio.h>
>  #include <linux/iio/sysfs.h>
> -#include "dds.h"
>  
> -#include "ad9834.h"
> +#include "dds.h"
>  
>  /* Registers */
>  
> diff --git a/drivers/staging/iio/frequency/ad9834.h b/drivers/staging/iio/frequency/ad9834.h
> deleted file mode 100644
> index 521943aa0e61..000000000000
> --- a/drivers/staging/iio/frequency/ad9834.h
> +++ /dev/null
> @@ -1,10 +0,0 @@
> -/* SPDX-License-Identifier: GPL-2.0 */
> -/*
> - * AD9833/AD9834/AD9837/AD9838 SPI DDS driver
> - *
> - * Copyright 2010-2011 Analog Devices Inc.
> - */
> -#ifndef IIO_DDS_AD9834_H_
> -#define IIO_DDS_AD9834_H_
> -
> -#endif /* IIO_DDS_AD9834_H_ */


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

end of thread, other threads:[~2025-10-12 14:18 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-06  9:40 [PATCH 0/2] Remove ad9832.h and ad9834.h header files in drivers/staging/iio/frequency Taimoor Zaeem
2025-10-06  9:40 ` [PATCH 1/2] staging: iio: ad9834: remove empty ad9834.h file Taimoor Zaeem
2025-10-12 14:17   ` Jonathan Cameron
2025-10-06  9:40 ` [PATCH 2/2] staging: iio: ad9832: move struct ad9832_platform_data to ad9832.c Taimoor Zaeem
2025-10-07 12:48   ` Jonathan Cameron

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