OpenCloudOS-Kernel/drivers/iio/dac
Lars-Peter Clausen 8cb631ccbb iio: Remove superfluous of_node assignments
If a driver does not assign an of_node to a IIO device to IIO core will
automatically assign the of_node of the parent device. This automatic
assignment is done in the iio_device_register() function.

There is a fair amount of drivers that currently manually assign the
of_node of the IIO device. All but 4 of them can make use of the automatic
assignment though.

The exceptions are:
 * mxs-lradc-adc: Which uses the of_node of the parent of the parent.
 * stm32-dfsdm-adc, stm32-adc and stm32-dac: Which reference the of_node
   assigned to the IIO device before iio_device_register() is called.

All other drivers are updated to use automatic assignment. This reduces
the amount of boilerplate code involved in setting up the IIO device.

The patch has mostly been auto-generated with the following semantic patch

// <smpl>
@exists@
expression indio_dev;
expression parent;
@@
indio_dev = \(devm_iio_device_alloc\|iio_device_alloc\)(&parent, ...)
...
-indio_dev->dev.of_node = parent.of_node;

@exists@
expression indio_dev;
expression parent;
@@
indio_dev = \(devm_iio_device_alloc\|iio_device_alloc\)(parent, ...)
...
-indio_dev->dev.of_node = parent->of_node;
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2020-06-14 14:20:08 +01:00
..
Kconfig iio: DAC extension for ltc2634-12/10/8 2020-05-03 09:47:23 +01:00
Makefile iio: dac: ad5770r: Add AD5770R support 2020-03-08 17:28:41 +00:00
ad5064.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5360.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5380.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5421.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5446.c iio: remove left-over comments about parent assignment 2020-06-14 11:50:00 +01:00
ad5449.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5504.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5592r-base.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5592r-base.h iio: dac: ad5592r-base: Replace indio_dev->mlock with own device lock 2020-05-21 19:37:05 +01:00
ad5592r.c iio: dac: ad5592r: Fix a typo in the name of a function 2020-05-03 09:47:21 +01:00
ad5593r.c iio: dac: ad5593r: Fix a typo in MODULE_DESCRIPTION 2020-05-03 09:47:21 +01:00
ad5624r.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 177 2019-05-30 11:29:19 -07:00
ad5624r_spi.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5686-spi.c drivers: iio: dac: Fix wrong license for ADI drivers 2019-02-09 18:46:01 +00:00
ad5686.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5686.h iio: dac: ad5686: Replace indio_dev->mlock with own device lock 2020-05-16 16:29:54 +01:00
ad5696-i2c.c drivers: iio: dac: Fix wrong license for ADI drivers 2019-02-09 18:46:01 +00:00
ad5755.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5758.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5761.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5764.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad5770r.c iio: remove left-over parent assignments 2020-06-14 11:50:04 +01:00
ad5791.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad7303.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ad8801.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
cio-dac.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
dpot-dac.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ds4424.c iio: Remove superfluous of_node assignments 2020-06-14 14:20:08 +01:00
lpc18xx_dac.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ltc1660.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ltc2632.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
m62332.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
max517.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
max5821.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
mcp4725.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
mcp4922.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
stm32-dac-core.c iio: dac: stm32-dac: better handle reset controller failures 2020-01-18 14:32:01 +00:00
stm32-dac-core.h iio: stm32: Adopt SPDX identifier 2018-01-08 16:03:41 +01:00
stm32-dac.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ti-dac082s085.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
ti-dac5571.c iio: Remove superfluous of_node assignments 2020-06-14 14:20:08 +01:00
ti-dac7311.c iio: Remove superfluous of_node assignments 2020-06-14 14:20:08 +01:00
ti-dac7612.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
vf610_dac.c iio: Remove superfluous of_node assignments 2020-06-14 14:20:08 +01:00