summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntoniu Miclaus <antoniu.miclaus@analog.com>2026-07-20 16:37:07 +0300
committerJonathan Cameron <jonathan.cameron@oss.qualcomm.com>2026-07-23 23:58:24 +0100
commitfa2000702618660ec9ab111d9b0f0a99c6ff50ab (patch)
treea53e8e504101e26d02ba0cf887e11b1606351ac9
parent4516d204aa0cf180bb76a8af50014d93ba6cf3fc (diff)
downloadlinux-fa2000702618660ec9ab111d9b0f0a99c6ff50ab.tar.gz
linux-fa2000702618660ec9ab111d9b0f0a99c6ff50ab.zip
iio: adc: ad4080: add support for AD4883
Add support for the AD4883, a dual-channel, 16-bit, 40 MSPS SAR ADC. The AD4883 is the dual-channel variant of the AD4083, sharing the same register map and SPI interface as the rest of the AD4080 family. Like the AD4880, it uses two independent ADC channels, each with its own SPI configuration interface. Signed-off-by: Antoniu Miclaus <antoniu.miclaus@analog.com> Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
-rw-r--r--drivers/iio/adc/ad4080.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/iio/adc/ad4080.c b/drivers/iio/adc/ad4080.c
index c7ecf6971be4..543728c7e88c 100644
--- a/drivers/iio/adc/ad4080.c
+++ b/drivers/iio/adc/ad4080.c
@@ -135,6 +135,7 @@
#define AD4087_CHIP_ID 0x0057
#define AD4088_CHIP_ID 0x0058
#define AD4880_CHIP_ID 0x0059
+#define AD4883_CHIP_ID 0x005B
#define AD4884_CHIP_ID 0x005C
#define AD4080_MAX_CHANNELS 2
@@ -541,6 +542,11 @@ static const struct iio_chan_spec ad4880_channels[] = {
AD4880_CHANNEL_DEFINE(20, 32, 1),
};
+static const struct iio_chan_spec ad4883_channels[] = {
+ AD4880_CHANNEL_DEFINE(16, 16, 0),
+ AD4880_CHANNEL_DEFINE(16, 16, 1),
+};
+
static const struct iio_chan_spec ad4884_channels[] = {
AD4880_CHANNEL_DEFINE(16, 16, 0),
AD4880_CHANNEL_DEFINE(16, 16, 1),
@@ -646,6 +652,16 @@ static const struct ad4080_chip_info ad4880_chip_info = {
.lvds_cnv_clk_cnt_max = AD4080_LVDS_CNV_CLK_CNT_MAX,
};
+static const struct ad4080_chip_info ad4883_chip_info = {
+ .name = "ad4883",
+ .product_id = AD4883_CHIP_ID,
+ .scale_table = ad4080_scale_table,
+ .num_scales = ARRAY_SIZE(ad4080_scale_table),
+ .num_channels = 2,
+ .channels = ad4883_channels,
+ .lvds_cnv_clk_cnt_max = 5,
+};
+
static const struct ad4080_chip_info ad4884_chip_info = {
.name = "ad4884",
.product_id = AD4884_CHIP_ID,
@@ -858,6 +874,7 @@ static const struct spi_device_id ad4080_id[] = {
{ .name = "ad4087", .driver_data = (kernel_ulong_t)&ad4087_chip_info },
{ .name = "ad4088", .driver_data = (kernel_ulong_t)&ad4088_chip_info },
{ .name = "ad4880", .driver_data = (kernel_ulong_t)&ad4880_chip_info },
+ { .name = "ad4883", .driver_data = (kernel_ulong_t)&ad4883_chip_info },
{ .name = "ad4884", .driver_data = (kernel_ulong_t)&ad4884_chip_info },
{ }
};
@@ -874,6 +891,7 @@ static const struct of_device_id ad4080_of_match[] = {
{ .compatible = "adi,ad4087", &ad4087_chip_info },
{ .compatible = "adi,ad4088", &ad4088_chip_info },
{ .compatible = "adi,ad4880", &ad4880_chip_info },
+ { .compatible = "adi,ad4883", &ad4883_chip_info },
{ .compatible = "adi,ad4884", &ad4884_chip_info },
{ }
};