[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20251206054831.26045-1-dharanitharan725@gmail.com>
Date: Sat, 6 Dec 2025 05:48:31 +0000
From: Dharanitharan R <dharanitharan725@...il.com>
To: Lars-Peter Clausen <lars@...afoo.de>
Cc: Michael Hennerich <Michael.Hennerich@...log.com>,
Jonathan Cameron <jic23@...nel.org>,
David Lechner <dlechner@...libre.com>,
Nuno Sá <nuno.sa@...log.com>,
Andy Shevchenko <andy@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
linux-iio@...r.kernel.org,
linux-staging@...ts.linux.dev,
linux-kernel@...r.kernel.org,
Dharanitharan R <dharanitharan725@...il.com>
Subject: [PATCH v1] staging: iio: frequency: ad9832: replace long/short with u32/u16
Cleanup the AD9832 header by explicitly including <linux/types.h> and
replacing ambiguous integer types with fixed-width kernel types:
- unsigned long → u32
- unsigned short → u16
This improves type clarity and ensures consistent behavior across
architectures.
Signed-off-by: Dharanitharan R <dharanitharan725@...il.com>
---
drivers/staging/iio/frequency/ad9832.h | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/iio/frequency/ad9832.h b/drivers/staging/iio/frequency/ad9832.h
index d0d840edb8d2..d59ad0627a9b 100644
--- a/drivers/staging/iio/frequency/ad9832.h
+++ b/drivers/staging/iio/frequency/ad9832.h
@@ -6,6 +6,7 @@
*/
#ifndef IIO_DDS_AD9832_H_
#define IIO_DDS_AD9832_H_
+#include <linux/types.h>
/*
* TODO: struct ad9832_platform_data needs to go into include/linux/iio
@@ -22,12 +23,12 @@
*/
struct ad9832_platform_data {
- unsigned long freq0;
- unsigned long freq1;
- unsigned short phase0;
- unsigned short phase1;
- unsigned short phase2;
- unsigned short phase3;
+ u32 freq0;
+ u32 freq1;
+ u16 phase0;
+ u16 phase1;
+ u16 phase2;
+ u16 phase3;
};
#endif /* IIO_DDS_AD9832_H_ */
--
2.43.0
Powered by blists - more mailing lists