Commit 59b75dcb authored by George Stark's avatar George Stark Committed by Jonathan Cameron
Browse files

iio: adc: meson: add separate config for axg SoC family



According to Amlogic custom kernels ADC of axg SoC family has
vref_select and requires this setting to work nominally and thus
needs a separate config.

Fixes: 90c62418 ("iio: adc: meson: init voltage control bits")
Signed-off-by: default avatarGeorge Stark <gnstark@salutedevices.com>
Reviewed-by: default avatarNeil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20231127235558.71995-1-gnstark@salutedevices.com


Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 2475ecdb
Loading
Loading
Loading
Loading
+15 −1
Original line number Diff line number Diff line
@@ -1241,6 +1241,20 @@ static const struct meson_sar_adc_param meson_sar_adc_gxl_param = {
	.cmv_select = 1,
};

static const struct meson_sar_adc_param meson_sar_adc_axg_param = {
	.has_bl30_integration = true,
	.clock_rate = 1200000,
	.bandgap_reg = MESON_SAR_ADC_REG11,
	.regmap_config = &meson_sar_adc_regmap_config_gxbb,
	.resolution = 12,
	.disable_ring_counter = 1,
	.has_reg11 = true,
	.vref_volatge = 1,
	.has_vref_select = true,
	.vref_select = VREF_VDDA,
	.cmv_select = 1,
};

static const struct meson_sar_adc_param meson_sar_adc_g12a_param = {
	.has_bl30_integration = false,
	.clock_rate = 1200000,
@@ -1285,7 +1299,7 @@ static const struct meson_sar_adc_data meson_sar_adc_gxm_data = {
};

static const struct meson_sar_adc_data meson_sar_adc_axg_data = {
	.param = &meson_sar_adc_gxl_param,
	.param = &meson_sar_adc_axg_param,
	.name = "meson-axg-saradc",
};