iio: add the IIO backend framework
authorNuno Sa <nuno.sa@analog.com>
Sat, 10 Feb 2024 20:57:17 +0000 (21:57 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Mon, 19 Feb 2024 19:32:22 +0000 (19:32 +0000)
commit1a97905d3e48ebe79a06d16143fbfa427c56ce5f
tree1c24ebf6d74fc8711a56bd1980304ce37d7e2f73
parent9c446288d7b31402adb454535cb2c3cbdb55bb88
iio: add the IIO backend framework

This is a Framework to handle complex IIO aggregate devices.

The typical architecture is to have one device as the frontend device which
can be "linked" against one or multiple backend devices. All the IIO and
userspace interface is expected to be registers/managed by the frontend
device which will callback into the backends when needed (to get/set
some configuration that it does not directly control).

The basic framework interface is pretty simple:
 - Backends should register themselves with @devm_iio_backend_register()
 - Frontend devices should get backends with @devm_iio_backend_get()

Signed-off-by: Nuno Sa <nuno.sa@analog.com>
Link: https://lore.kernel.org/r/20240210-iio-backend-v11-5-f5242a5fb42a@analog.com
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
MAINTAINERS
drivers/iio/Kconfig
drivers/iio/Makefile
drivers/iio/industrialio-backend.c [new file with mode: 0644]
include/linux/iio/backend.h [new file with mode: 0644]