summaryrefslogtreecommitdiff
path: root/drivers/input
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2024-08-23 22:50:35 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2024-09-05 22:56:46 -0700
commitc4a8349262aaea42163dbc9171208f712f172d25 (patch)
treef6858065ce35666fc2da8ba50f7922598f69a4c6 /drivers/input
parent43a48ec581d7e4b6751b236122f7c0a78c99a838 (diff)
Input: zforce_ts - do not ignore errors when acquiring regulator
We should abort probe on any error besides -ENOENT which signifies that the regulator is not defined in device tree or elsewhere, not only when we see -EPROBE_DEFER. Tested-by: Andreas Kemnade <andreas@kemnade.info> # Tolino Shine2HD Link: https://lore.kernel.org/r/20240824055047.1706392-12-dmitry.torokhov@gmail.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/touchscreen/zforce_ts.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/touchscreen/zforce_ts.c b/drivers/input/touchscreen/zforce_ts.c
index c5b4c85359b4..0d06dda311d4 100644
--- a/drivers/input/touchscreen/zforce_ts.c
+++ b/drivers/input/touchscreen/zforce_ts.c
@@ -753,7 +753,7 @@ static int zforce_probe(struct i2c_client *client)
ts->reg_vdd = devm_regulator_get_optional(&client->dev, "vdd");
if (IS_ERR(ts->reg_vdd)) {
ret = PTR_ERR(ts->reg_vdd);
- if (ret == -EPROBE_DEFER)
+ if (ret != -ENOENT)
return ret;
} else {
ret = regulator_enable(ts->reg_vdd);