Skip to content

Commit 59b75dc

Browse files
geo-starkjic23
authored andcommitted
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: 90c6241 ("iio: adc: meson: init voltage control bits") Signed-off-by: George Stark <[email protected]> Reviewed-by: Neil Armstrong <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jonathan Cameron <[email protected]>
1 parent 2475ecd commit 59b75dc

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

drivers/iio/adc/meson_saradc.c

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1241,6 +1241,20 @@ static const struct meson_sar_adc_param meson_sar_adc_gxl_param = {
12411241
.cmv_select = 1,
12421242
};
12431243

1244+
static const struct meson_sar_adc_param meson_sar_adc_axg_param = {
1245+
.has_bl30_integration = true,
1246+
.clock_rate = 1200000,
1247+
.bandgap_reg = MESON_SAR_ADC_REG11,
1248+
.regmap_config = &meson_sar_adc_regmap_config_gxbb,
1249+
.resolution = 12,
1250+
.disable_ring_counter = 1,
1251+
.has_reg11 = true,
1252+
.vref_volatge = 1,
1253+
.has_vref_select = true,
1254+
.vref_select = VREF_VDDA,
1255+
.cmv_select = 1,
1256+
};
1257+
12441258
static const struct meson_sar_adc_param meson_sar_adc_g12a_param = {
12451259
.has_bl30_integration = false,
12461260
.clock_rate = 1200000,
@@ -1285,7 +1299,7 @@ static const struct meson_sar_adc_data meson_sar_adc_gxm_data = {
12851299
};
12861300

12871301
static const struct meson_sar_adc_data meson_sar_adc_axg_data = {
1288-
.param = &meson_sar_adc_gxl_param,
1302+
.param = &meson_sar_adc_axg_param,
12891303
.name = "meson-axg-saradc",
12901304
};
12911305

0 commit comments

Comments
 (0)