diff options
| author | Alexandru Ardelean <alexandru.ardelean@analog.com> | 2020-11-27 11:40:37 +0200 |
|---|---|---|
| committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2020-11-28 13:03:28 +0000 |
| commit | b6a3f8326cfddad455d832d4ff9392286280a31c (patch) | |
| tree | 78f5a40f63001a844979224d21fb6ecd7c436a32 /tools/perf/scripts/python/export-to-sqlite.py | |
| parent | dt-bindings: iio: imu: st_lsm6dsx: introduce vdd-vddio regulators bindings (diff) | |
| download | linux-b6a3f8326cfddad455d832d4ff9392286280a31c.tar.gz linux-b6a3f8326cfddad455d832d4ff9392286280a31c.zip | |
iio: adc: ad7298: convert probe to device-managed functions
This change converts the probe of this driver to use device-managed
register functions, and a devm_add_action_or_reset() for the regulator
disable.
With this, the exit & error paths can be removed.
Another side-effect is that this should avoid some static-analyzer's check
with respect to a potential null dereference of the regulator. The null
dereference isn't likely to happen (under normal operation), so there isn't
a requirement to have this fixed/backported in other releases.
As a note: this is removing spi_set_drvdata() since there is no other
spi_get_drvdata() (or dev_get_drvdata()) call that need it.
Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Cc: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20201127094038.91714-1-alexandru.ardelean@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions
