]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
iio: dummy: Fix build error when CONFIG_IIO_TRIGGERED_BUFFER is not set
authorWei Yongjun <weiyongjun1@huawei.com>
Mon, 24 May 2021 14:05:36 +0000 (14:05 +0000)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 13 Jun 2021 16:00:17 +0000 (17:00 +0100)
Gcc reports build error when CONFIG_IIO_TRIGGERED_BUFFER is not set:

riscv64-linux-gnu-ld: drivers/iio/dummy/iio_simple_dummy_buffer.o: in function `iio_simple_dummy_configure_buffer':
iio_simple_dummy_buffer.c:(.text+0x2b0): undefined reference to `iio_triggered_buffer_setup_ext'
riscv64-linux-gnu-ld: drivers/iio/dummy/iio_simple_dummy_buffer.o: in function `.L0 ':
iio_simple_dummy_buffer.c:(.text+0x2fc): undefined reference to `iio_triggered_buffer_cleanup'

Fix it by select IIO_TRIGGERED_BUFFER for config IIO_SIMPLE_DUMMY_BUFFER.

Fixes: 738f6ba11800 ("iio: dummy: iio_simple_dummy_buffer: use triggered buffer core calls")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/dummy/Kconfig

index 5c5c2f8c55f36c261417f55d30c5b96cee47e205..1f46cb9e51b741243e2e0e0769a798f6bb1a7a32 100644 (file)
@@ -34,6 +34,7 @@ config IIO_SIMPLE_DUMMY_BUFFER
        select IIO_BUFFER
        select IIO_TRIGGER
        select IIO_KFIFO_BUF
+       select IIO_TRIGGERED_BUFFER
        help
          Add buffered data capture to the simple dummy driver.