diff options
author | Laxman Dewangan <ldewangan@nvidia.com> | 2016-04-06 13:31:06 +0300 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2016-04-19 21:58:14 +0300 |
commit | 8bf872d8d261feefcdf67027522e3f717cad2bfe (patch) | |
tree | d3e646a5e68314e744468fdec20d17c24248785e /include/linux/ptp_clock_kernel.h | |
parent | 5f991a921a08279f573fa5ecf84261a3a6fac0cc (diff) | |
download | linux-8bf872d8d261feefcdf67027522e3f717cad2bfe.tar.xz |
iio: core: Add devm_ APIs for iio_channel_{get,release}
Some of kernel driver uses the IIO framework to get the sensor
value via ADC or IIO HW driver. The client driver get iio channel
by iio_channel_get() and release it by calling iio_channel_release().
Add resource managed version (devm_*) of these APIs so that if client
calls the devm_iio_channel_get() then it need not to release it explicitly,
it can be done by managed device framework when driver get un-binded.
This reduces the code in error path and also need of .remove callback in
some cases.
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'include/linux/ptp_clock_kernel.h')
0 files changed, 0 insertions, 0 deletions