[RFC PATCH 2/5] iio: adc: Kconfig: add Kconfig entry for TI ADS1262 driver

Sayyad Abid posted 5 patches 9 months, 2 weeks ago
[RFC PATCH 2/5] iio: adc: Kconfig: add Kconfig entry for TI ADS1262 driver
Posted by Sayyad Abid 9 months, 2 weeks ago
Adds the Kconfig option `CONFIG_TI_ADS1262` under the IIO ADC menu.
This allows users to select the TI ADS1262 driver for compilation
during kernel configuration.

Signed-off-by: Sayyad Abid <sayyad.abid16@gmail.com>
---
 drivers/iio/adc/Kconfig | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/drivers/iio/adc/Kconfig b/drivers/iio/adc/Kconfig
index 6529df1a498c..f3f8a8cf5f89 100644
--- a/drivers/iio/adc/Kconfig
+++ b/drivers/iio/adc/Kconfig
@@ -1542,6 +1542,18 @@ config TI_ADS1100
 	  This driver can also be built as a module. If so, the module will be
 	  called ti-ads1100.
 
+config TI_ADS1262
+	tristate "Texas Instruments ADS1262"
+	depends on SPI
+	select IIO_BUFFER
+	help
+	  If you say yes here you get support for Texas Instruments ADS1262
+	  32-bit precision ADC with programmable gain amplifier and internal
+	  voltage reference.
+
+	  This driver can also be built as a module. If so, the module will be
+	  called ti-ads1262.
+
 config TI_ADS1298
 	tristate "Texas Instruments ADS1298"
 	depends on SPI
-- 
2.39.5
Re: [RFC PATCH 2/5] iio: adc: Kconfig: add Kconfig entry for TI ADS1262 driver
Posted by David Lechner 9 months, 1 week ago
On 5/1/25 5:00 AM, Sayyad Abid wrote:
> Adds the Kconfig option `CONFIG_TI_ADS1262` under the IIO ADC menu.
> This allows users to select the TI ADS1262 driver for compilation
> during kernel configuration.
> 
> Signed-off-by: Sayyad Abid <sayyad.abid16@gmail.com>
> ---
This can be in the same patch as the driver. Same with the makefile - it doesn't
need to be a separate patch.
Re: [RFC PATCH 2/5] iio: adc: Kconfig: add Kconfig entry for TI ADS1262 driver
Posted by Jonathan Cameron 9 months, 1 week ago
On Thu, 1 May 2025 12:37:35 -0500
David Lechner <dlechner@baylibre.com> wrote:

> On 5/1/25 5:00 AM, Sayyad Abid wrote:
> > Adds the Kconfig option `CONFIG_TI_ADS1262` under the IIO ADC menu.
> > This allows users to select the TI ADS1262 driver for compilation
> > during kernel configuration.
> > 
> > Signed-off-by: Sayyad Abid <sayyad.abid16@gmail.com>
> > ---  
> This can be in the same patch as the driver. Same with the makefile - it doesn't
> need to be a separate patch.

Change that from can to should / must.  There are some bits of the kernel
that run a different approach for complex multi patch drivers but for
IIO we want everything to be building at each step of the series.
Personally I see that as good practice and I don't know of any part of the
kernel where the maintainers reject that approach, just some where they
don't mind as much if a complex driver is built up and only compiled in
the final patch

Thanks,

Jonathan