2020-08-28 17:45:24

by Alexandru Elisei

[permalink] [raw]
Subject: [PATCH] iio: adc: rockchip_saradc: Select IIO_TRIGGERED_BUFFER

Building the Rockchip saradc driver can trigger the following error if the
driver is compiled into the kernel, but the IIO triggered buffer is not:

aarch64-linux-gnu-ld: drivers/iio/adc/rockchip_saradc.o: in function `rockchip_saradc_probe':
/path/to/linux/drivers/iio/adc/rockchip_saradc.c:427: undefined reference to `devm_iio_triggered_buffer_setup'

This is because commit 4e130dc7b413 ("iio: adc: rockchip_saradc: Add
support iio buffers") added support for industrial I/O triggered buffers,
but didn't update Kconfig to build the required file. Fix that.

Fixes: 4e130dc7b413 ("iio: adc: rockchip_saradc: Add support iio buffers")
Signed-off-by: Alexandru Elisei <[email protected]>
---
drivers/iio/adc/Kconfig | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/iio/adc/Kconfig b/drivers/iio/adc/Kconfig
index 66d9cc073157..baa36a07a9cf 100644
--- a/drivers/iio/adc/Kconfig
+++ b/drivers/iio/adc/Kconfig
@@ -865,6 +865,7 @@ config ROCKCHIP_SARADC
tristate "Rockchip SARADC driver"
depends on ARCH_ROCKCHIP || (ARM && COMPILE_TEST)
depends on RESET_CONTROLLER
+ select IIO_TRIGGERED_BUFFER
help
Say yes here to build support for the SARADC found in SoCs from
Rockchip.
--
2.28.0


2020-08-29 14:58:29

by Jonathan Cameron

[permalink] [raw]
Subject: Re: [PATCH] iio: adc: rockchip_saradc: Select IIO_TRIGGERED_BUFFER

On Fri, 28 Aug 2020 18:42:42 +0100
Alexandru Elisei <[email protected]> wrote:

> Building the Rockchip saradc driver can trigger the following error if the
> driver is compiled into the kernel, but the IIO triggered buffer is not:
>
> aarch64-linux-gnu-ld: drivers/iio/adc/rockchip_saradc.o: in function `rockchip_saradc_probe':
> /path/to/linux/drivers/iio/adc/rockchip_saradc.c:427: undefined reference to `devm_iio_triggered_buffer_setup'
>
> This is because commit 4e130dc7b413 ("iio: adc: rockchip_saradc: Add
> support iio buffers") added support for industrial I/O triggered buffers,
> but didn't update Kconfig to build the required file. Fix that.
>
> Fixes: 4e130dc7b413 ("iio: adc: rockchip_saradc: Add support iio buffers")
> Signed-off-by: Alexandru Elisei <[email protected]>

Sorry, I've had a patch queued to fix this for a while, but had a
vacation just after merge window occurred that delayed me sending it out.

Will send a pull sometime this weekend.

Jonathan

> ---
> drivers/iio/adc/Kconfig | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/iio/adc/Kconfig b/drivers/iio/adc/Kconfig
> index 66d9cc073157..baa36a07a9cf 100644
> --- a/drivers/iio/adc/Kconfig
> +++ b/drivers/iio/adc/Kconfig
> @@ -865,6 +865,7 @@ config ROCKCHIP_SARADC
> tristate "Rockchip SARADC driver"
> depends on ARCH_ROCKCHIP || (ARM && COMPILE_TEST)
> depends on RESET_CONTROLLER
> + select IIO_TRIGGERED_BUFFER
> help
> Say yes here to build support for the SARADC found in SoCs from
> Rockchip.

2020-08-30 09:27:29

by Alexandru Elisei

[permalink] [raw]
Subject: Re: [PATCH] iio: adc: rockchip_saradc: Select IIO_TRIGGERED_BUFFER

Hi Jonathan,

On 8/29/20 3:57 PM, Jonathan Cameron wrote:
> On Fri, 28 Aug 2020 18:42:42 +0100
> Alexandru Elisei <[email protected]> wrote:
>
>> Building the Rockchip saradc driver can trigger the following error if the
>> driver is compiled into the kernel, but the IIO triggered buffer is not:
>>
>> aarch64-linux-gnu-ld: drivers/iio/adc/rockchip_saradc.o: in function `rockchip_saradc_probe':
>> /path/to/linux/drivers/iio/adc/rockchip_saradc.c:427: undefined reference to `devm_iio_triggered_buffer_setup'
>>
>> This is because commit 4e130dc7b413 ("iio: adc: rockchip_saradc: Add
>> support iio buffers") added support for industrial I/O triggered buffers,
>> but didn't update Kconfig to build the required file. Fix that.
>>
>> Fixes: 4e130dc7b413 ("iio: adc: rockchip_saradc: Add support iio buffers")
>> Signed-off-by: Alexandru Elisei <[email protected]>
> Sorry, I've had a patch queued to fix this for a while, but had a
> vacation just after merge window occurred that delayed me sending it out.
>
> Will send a pull sometime this weekend.
>
> Jonathan

That's great, thank you!

Thanks,
Alex