Skip to content

Commit 301ab52

Browse files
dlechjic23
authored andcommitted
iio: adc: qcom-vadc: make scale_adc5_fn const
Add const qualifier to struct qcom_adc5_scale_type scale_adc5_fn[]. This is read-only data so it can be made const. Signed-off-by: David Lechner <dlechner@baylibre.com> Link: https://patch.msgid.link/20250628-iio-const-data-9-v1-1-188ca6e904ee@baylibre.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
1 parent 285ce2e commit 301ab52

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iio/adc/qcom-vadc-common.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ static int qcom_vadc7_scale_hw_calib_die_temp(
330330
const struct adc5_data *data,
331331
u16 adc_code, int *result_mdec);
332332

333-
static struct qcom_adc5_scale_type scale_adc5_fn[] = {
333+
static const struct qcom_adc5_scale_type scale_adc5_fn[] = {
334334
[SCALE_HW_CALIB_DEFAULT] = {qcom_vadc_scale_hw_calib_volt},
335335
[SCALE_HW_CALIB_THERM_100K_PULLUP] = {qcom_vadc_scale_hw_calib_therm},
336336
[SCALE_HW_CALIB_XOTHERM] = {qcom_vadc_scale_hw_calib_therm},

0 commit comments

Comments
 (0)