Skip to content

Commit 3b00110

Browse files
lweiss-fairphonedtor
authored andcommitted
Input: goodix-berlin - fix vddio regulator references
As per dt-bindings the property is called vddio-supply, so use the correct name in the driver instead of iovdd. The datasheet also calls the supply 'VDDIO'. Fixes: 4436227 ("Input: add core support for Goodix Berlin Touchscreen IC") Cc: stable@vger.kernel.org Signed-off-by: Luca Weiss <luca.weiss@fairphone.com> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Link: https://lore.kernel.org/r/20250103-goodix-berlin-fixes-v1-2-b014737b08b2@fairphone.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
1 parent 5bab1ae commit 3b00110

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

drivers/input/touchscreen/goodix_berlin_core.c

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ struct goodix_berlin_core {
165165
struct device *dev;
166166
struct regmap *regmap;
167167
struct regulator *avdd;
168-
struct regulator *iovdd;
168+
struct regulator *vddio;
169169
struct gpio_desc *reset_gpio;
170170
struct touchscreen_properties props;
171171
struct goodix_berlin_fw_version fw_version;
@@ -248,19 +248,19 @@ static int goodix_berlin_power_on(struct goodix_berlin_core *cd)
248248
{
249249
int error;
250250

251-
error = regulator_enable(cd->iovdd);
251+
error = regulator_enable(cd->vddio);
252252
if (error) {
253-
dev_err(cd->dev, "Failed to enable iovdd: %d\n", error);
253+
dev_err(cd->dev, "Failed to enable vddio: %d\n", error);
254254
return error;
255255
}
256256

257-
/* Vendor waits 3ms for IOVDD to settle */
257+
/* Vendor waits 3ms for VDDIO to settle */
258258
usleep_range(3000, 3100);
259259

260260
error = regulator_enable(cd->avdd);
261261
if (error) {
262262
dev_err(cd->dev, "Failed to enable avdd: %d\n", error);
263-
goto err_iovdd_disable;
263+
goto err_vddio_disable;
264264
}
265265

266266
/* Vendor waits 15ms for AVDD to settle */
@@ -283,16 +283,16 @@ static int goodix_berlin_power_on(struct goodix_berlin_core *cd)
283283
err_dev_reset:
284284
gpiod_set_value_cansleep(cd->reset_gpio, 1);
285285
regulator_disable(cd->avdd);
286-
err_iovdd_disable:
287-
regulator_disable(cd->iovdd);
286+
err_vddio_disable:
287+
regulator_disable(cd->vddio);
288288
return error;
289289
}
290290

291291
static void goodix_berlin_power_off(struct goodix_berlin_core *cd)
292292
{
293293
gpiod_set_value_cansleep(cd->reset_gpio, 1);
294294
regulator_disable(cd->avdd);
295-
regulator_disable(cd->iovdd);
295+
regulator_disable(cd->vddio);
296296
}
297297

298298
static int goodix_berlin_read_version(struct goodix_berlin_core *cd)
@@ -744,10 +744,10 @@ int goodix_berlin_probe(struct device *dev, int irq, const struct input_id *id,
744744
return dev_err_probe(dev, PTR_ERR(cd->avdd),
745745
"Failed to request avdd regulator\n");
746746

747-
cd->iovdd = devm_regulator_get(dev, "iovdd");
748-
if (IS_ERR(cd->iovdd))
749-
return dev_err_probe(dev, PTR_ERR(cd->iovdd),
750-
"Failed to request iovdd regulator\n");
747+
cd->vddio = devm_regulator_get(dev, "vddio");
748+
if (IS_ERR(cd->vddio))
749+
return dev_err_probe(dev, PTR_ERR(cd->vddio),
750+
"Failed to request vddio regulator\n");
751751

752752
error = goodix_berlin_power_on(cd);
753753
if (error) {

0 commit comments

Comments
 (0)