diff mbox series

[2/2] iio: adc: meson-saradc: add support for Meson G12A

Message ID 20190304111217.882-3-narmstrong@baylibre.com (mailing list archive)
State Not Applicable
Headers show
Series Add Meson SAR ADC support for G12A | expand

Commit Message

Neil Armstrong March 4, 2019, 11:12 a.m. UTC
Add the SAR ADC driver for the Amlogic Meson-G12A SoC.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
---
 drivers/iio/adc/meson_saradc.c | 8 ++++++++
 1 file changed, 8 insertions(+)

Comments

Martin Blumenstingl March 5, 2019, 9:02 p.m. UTC | #1
On Mon, Mar 4, 2019 at 12:12 PM Neil Armstrong <narmstrong@baylibre.com> wrote:
>
> Add the SAR ADC driver for the Amlogic Meson-G12A SoC.
>
> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

this new compatible string will be especially useful when we want to
add "buffer" support which was reworked in the IP block with G12A
Jonathan Cameron March 9, 2019, 6:07 p.m. UTC | #2
On Tue, 5 Mar 2019 22:02:48 +0100
Martin Blumenstingl <martin.blumenstingl@googlemail.com> wrote:

> On Mon, Mar 4, 2019 at 12:12 PM Neil Armstrong <narmstrong@baylibre.com> wrote:
> >
> > Add the SAR ADC driver for the Amlogic Meson-G12A SoC.
> >
> > Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>  
> Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
> 
> this new compatible string will be especially useful when we want to
> add "buffer" support which was reworked in the IP block with G12A

Good to know. Thanks.

Applied to the togreg branch of iio.git and pushed out as testing
for the autobuilders to play with it.

Thanks,

Jonathan
diff mbox series

Patch

diff --git a/drivers/iio/adc/meson_saradc.c b/drivers/iio/adc/meson_saradc.c
index 729becb2d3d9..69aeb5c58a9f 100644
--- a/drivers/iio/adc/meson_saradc.c
+++ b/drivers/iio/adc/meson_saradc.c
@@ -1117,6 +1117,11 @@  static const struct meson_sar_adc_data meson_sar_adc_axg_data = {
 	.name = "meson-axg-saradc",
 };
 
+static const struct meson_sar_adc_data meson_sar_adc_g12a_data = {
+	.param = &meson_sar_adc_gxl_param,
+	.name = "meson-g12a-saradc",
+};
+
 static const struct of_device_id meson_sar_adc_of_match[] = {
 	{
 		.compatible = "amlogic,meson8-saradc",
@@ -1142,6 +1147,9 @@  static const struct of_device_id meson_sar_adc_of_match[] = {
 	}, {
 		.compatible = "amlogic,meson-axg-saradc",
 		.data = &meson_sar_adc_axg_data,
+	}, {
+		.compatible = "amlogic,meson-g12a-saradc",
+		.data = &meson_sar_adc_g12a_data,
 	},
 	{},
 };