Thomas Gleixner
2874c5fd28
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152
...
Based on 1 normalized pattern(s):
this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation either version 2 of the license or at
your option any later version
extracted by the scancode license scanner the SPDX license identifier
GPL-2.0-or-later
has been chosen to replace the boilerplate/reference in 3029 file(s).
Signed-off-by: Thomas Gleixner <tglx@linutronix.de >
Reviewed-by: Allison Randal <allison@lohutok.net >
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
2019-05-30 11:26:32 -07:00
Andrey Smirnov
9c6126940d
iio: imx7d_adc: Use devm_iio_device_register()
...
Use devm_iio_device_register() and drop imx7d_adc_remove().
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-22 11:34:14 +01:00
Andrey Smirnov
b846676066
iio: imx7d_adc: Simplify imx7d_adc_remove() with imx7d_adc_suspend()
...
Since imx7d_adc_remove() does exactly the same thing as
imx7d_adc_suspend() we can use the latter together with
devm_add_action_or_reset() to simplify the former. Rename
imx7d_adc_suspend() to imx7d_adc_disable() for clarity while at it.
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-22 11:34:14 +01:00
Andrey Smirnov
4fe86cdf92
iio: imx7d_adc: Simplify imx7d_adc_probe() with imx7d_adc_resume()
...
Initialization sequence performed in imx7d_adc_resume() is exactly the
same as the one being done in imx7d_adc_probe(). Make use of the
former in the latter to avoid code duplication. Rename
imx7d_adc_resume() to imx7d_adc_enable() for clarity while at it.
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-22 11:34:14 +01:00
Andrey Smirnov
a8427a7b37
iio: imx7d_adc: Use devm_platform_ioremap_resource()
...
Use devm_platform_ioremap_resource() to be able to drop a bit of
explicit boilerplate code.
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-14 13:22:30 +01:00
Andrey Smirnov
8cc393bf30
iio: imx7d_adc: Replace pr_err with dev_err
...
Replace combination of pr_err()/dev_name() with an equivalent call for
dev_err().
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-14 13:22:30 +01:00
Andrey Smirnov
aa21a28e90
iio: imx7d_adc: Add local struct device pointer in imx7d_adc_probe()
...
Use a local "struct device *dev" in imx7d_adc_probe() for brevity. No
functional change intended.
Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com >
Cc: Jonathan Cameron <jic23@kernel.org >
Cc: Hartmut Knaack <knaack.h@gmx.de >
Cc: Lars-Peter Clausen <lars@metafoo.de >
Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net >
Cc: Chris Healy <cphealy@gmail.com >
Cc: linux-iio@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2019-04-14 13:22:29 +01:00
Colin Ian King
dd63b4fa0d
iio: adc: fix spelling mistake: "Freeacale" -> "Freescale"
...
Trivial fix to spelling mistake in module description text
Signed-off-by: Colin Ian King <colin.king@canonical.com >
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
2018-05-22 18:17:57 +01:00
Jonathan Cameron
52b31bcc93
iio:adc: drop assign iio_info.driver_module and iio_trigger_ops.owner
...
The equivalent of both of these are now done via macro magic when
the relevant register calls are made. The actual structure
elements will shortly go away.
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com >
Reviewed-by: Lars-Peter Clausen <lars@metafoo.de >
2017-08-22 21:22:25 +01:00
simran singhal
0b568b3c4a
iio: adc: Remove unnecessary cast on void pointer
...
The following Coccinelle script was used to detect this:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
*((T *)e)
|
((T *)x)[...]
|
((T*)x)->f
|
- (T*)
e
)
Signed-off-by: simran singhal <singhalsimran0@gmail.com >
Signed-off-by: Jonathan Cameron <jic23@kernel.org >
2017-04-02 09:46:25 +01:00
Haibo Chen
16846ebeff
iio: adc: add IMX7D ADC driver support
...
Freescale i.MX7D soc contains a new ADC IP. This patch add this ADC
driver support, and the driver only support ADC software trigger.
Signed-off-by: Haibo Chen <haibo.chen@freescale.com >
Signed-off-by: Jonathan Cameron <jic23@kernel.org >
2015-12-12 16:25:41 +00:00