aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin/flamegraph-record
diff options
context:
space:
mode:
authorDouglas Anderson <[email protected]>2022-11-17 21:49:19 -0800
committerDmitry Torokhov <[email protected]>2022-11-17 22:14:45 -0800
commita85fbd6498441694475716a4d5c65f9d3e073faf (patch)
treec55f6daccd9ddd0d199622d34cfc7dcfab521c34 /tools/perf/scripts/python/bin/flamegraph-record
parentc7f43645de7895a8e90cb267a9b3c46e989d8ca6 (diff)
Input: elants_i2c - properly handle the reset GPIO when power is off
As can be seen in elants_i2c_power_off(), we want the reset GPIO asserted when power is off. The reset GPIO is active low so we need the reset line logic low when power is off to avoid leakage. We have a problem, though, at probe time. At probe time we haven't powered the regulators on yet but we have: devm_gpiod_get(&client->dev, "reset", GPIOD_OUT_LOW); While that _looks_ right, it turns out that it's not. The GPIOD_OUT_LOW doesn't mean to init the GPIO to low. It means init the GPIO to "not asserted". Since this is an active low GPIO that inits it to be high. Let's fix this to properly init the GPIO. Now after both probe and power off the state of the GPIO is consistent (it's "asserted" or level low). Once we fix this, we can see that at power on time we no longer to assert the reset GPIO as the first thing. The reset GPIO is _always_ asserted before powering on. Let's fix powering on to account for this. Fixes: afe10358e47a ("Input: elants_i2c - wire up regulator support") Signed-off-by: Douglas Anderson <[email protected]> Link: https://lore.kernel.org/r/20221117123805.1.I9959ac561dd6e1e8e1ce7085e4de6167b27c574f@changeid Signed-off-by: Dmitry Torokhov <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin/flamegraph-record')
0 files changed, 0 insertions, 0 deletions