Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
MAINTAINERS | 7 +
drivers/iio/adc/Kconfig | 27 ++
drivers/iio/adc/Makefile | 3 +
drivers/iio/adc/ad7606.c | 583
This patch replaces the license text at the top of ad7606 driver files
and instead adds SPDX GPL-2.0 license identifier.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 5 ++---
drivers/staging/iio/adc/ad7606.h | 3 +--
drivers/staging/iio/adc/ad7606_par.c | 5
Document support for AD7606 Analog to Digital Converter.
Signed-off-by: Stefan Popa
Reviewed-by: Rob Herring
---
.../devicetree/bindings/iio/adc/adi,ad7606.txt | 65 ++
MAINTAINERS| 1 +
2 files changed, 66 insertions(+)
create
* Placed includes in alphabetical order
* Added brackets around num and mask through out for AD760X_CHANNEL
* Used single line comments where needed
* Removed extra lines and spaces
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 27 ---
drivers
BUSY
signal triggers the interrupt.
ad7606_trigger_handler() is used as bottom half of the poll function.
It reads data from the device and stores it in the internal buffer.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 111 +--
drivers
:
- Nothing changed.
Stefan Popa (6):
staging: iio: adc: ad7606: Simplify the Kconfing menu
staging: iio: adc: ad7606: Use SPDX identifier
staging: iio: adc: ad7606: Add support for threaded irq
staging: iio: adc: ad7606: Misc style fixes (no functional change)
staging: iio: adc: ad7606: Move
There is no point in having three menu entries that can be selected
individually. Instead, the SPI and parallel interfaces should select
AD7606.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/Kconfig | 27 ++-
1 file changed, 10 insertions(+), 17 deletions
Document support for AD7606 Analog to Digital Converter.
Signed-off-by: Stefan Popa
Reviewed-by: Rob Herring
---
.../devicetree/bindings/iio/adc/adi,ad7606.txt | 65 ++
MAINTAINERS| 1 +
2 files changed, 66 insertions(+)
create
Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
MAINTAINERS | 7 +
drivers/iio/adc/Kconfig | 28 ++
drivers/iio/adc/Makefile | 3 +
drivers/iio/adc/ad7606.c | 588
* Placed includes in alphabetical order
* Added brackets around num and mask through out for AD760X_CHANNEL
* Used single line comments where needed
* Removed extra lines and spaces
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 27 ---
drivers
This series attempts to clean up the driver according to the feedback
received during review and finally moves it out of staging.
Stefan Popa (11):
staging: iio: adc: ad7606: Simplify the Kconfing menu
staging: iio: adc: ad7606: Use SPDX identifier
staging: iio: adc: ad7606: Use wait-for
BUSY
signal triggers the interrupt.
ad7606_trigger_handler() is used as bottom half of the poll function.
It reads data from the device and stores it in the internal buffer.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 116 +--
drivers
The 'adi' vendor prefix needs to be added to conversion-start, range,
first-data and oversampling-ratio properties.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/iio/adc/
There is no point in having three menu entries that can be selected
individually. Instead, the SPI and parallel interfaces should select
AD7606.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/Kconfig | 24 +---
1 file changed, 9 insertions(+), 15 deletions(-)
diff
When looking for the available scale or oversampling ratio, it is better
to use the find_closest() macro. This simplifies the code and also does
not require an exact value to be entered from the user space.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 58
Switch to devm version of request_irq, iio_triggered_buffer_setup,
iio_device_register. To avoid potential ordering issues in probe,
devm_add_action_or_reset() is used for the regulator_disable(). This
simplifies the code and decreases the chance of bugs.
Signed-off-by: Stefan Popa
---
drivers
This patch replaces the use of wait_event_interruptible() with
wait_for_completion_timeout() when reading the result of a single
conversion. In this way, if the interrupt never occurs, the program will
not remain blocked.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 14
This patch replaces the license text at the top of ad7606 driver files
and instead adds SPDX GPL-2.0+ license identifier.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606.c | 5 ++---
drivers/staging/iio/adc/ad7606.h | 3 +--
drivers/staging/iio/adc/ad7606_par.c | 5
The driver does not have a struct of_device_id table, but supported
devices are registered via Device Trees. This patch adds and OF device
ID table.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7606_par.c | 10 ++
drivers/staging/iio/adc/ad7606_spi.c | 10 ++
2 files
Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
Changes in v2:
- Simplified the Kconfig menu.
- Added SPDX-License-Identifier.
- Ordered the includes alphabetically.
- Used a threaded interrupt.
- Replaced
Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
Changes in v2:
- Simplified the Kconfig menu.
- Added SPDX-License-Identifier.
- Ordered the includes alphabetically.
- Used a threaded interrupt.
- Replaced
Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
Changes in v2:
- Simplified the Kconfig menu.
- Added SPDX-License-Identifier.
- Ordered the includes alphabetically.
- Used a threaded interrupt.
- Replaced
Move ad7606 ADC driver out of staging and into the mainline.
Signed-off-by: Stefan Popa
---
MAINTAINERS | 7 +
drivers/iio/adc/Kconfig | 34 +++
drivers/iio/adc/Makefile | 3 +
drivers/iio/adc/ad7606.c | 565
SPI host drivers can use DMA to transfer data, so the buffer should be properly
allocated.
Keeping it on the stack could cause an undefined behavior.
The dedicated reset function solves this issue.
Signed-off-by: Stefan Popa
---
drivers/staging/iio/adc/ad7192.c | 4 +---
1 file changed, 1
24 matches
Mail list logo