diff options
| author | Jonathan Santos <Jonathan.Santos@analog.com> | 2026-04-01 08:58:22 -0300 |
|---|---|---|
| committer | Jonathan Cameron <jic23@kernel.org> | 2026-04-27 09:58:23 +0100 |
| commit | 2c5ebb7708274ac1e41cbd3248ed87aa3a1cee71 (patch) | |
| tree | 454ea33e36f32d5fafc9f97a550147e4a00f9afa | |
| parent | 0179a95bbb8ce2fc36ba3766c7db5c7b4dd180b9 (diff) | |
| download | linux-2c5ebb7708274ac1e41cbd3248ed87aa3a1cee71.tar.gz linux-2c5ebb7708274ac1e41cbd3248ed87aa3a1cee71.zip | |
iio: adc: ad4130: Add SPI device ID table
Add SPI device ID table to enable non-device tree based device binding.
The id_table provides a fallback matching mechanism when of_match_table
cannot be used, which is required for proper SPI driver registration.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Signed-off-by: Jonathan Santos <Jonathan.Santos@analog.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
| -rw-r--r-- | drivers/iio/adc/ad4130.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/iio/adc/ad4130.c b/drivers/iio/adc/ad4130.c index 5567ae5dee88..d7aaf57ab87a 100644 --- a/drivers/iio/adc/ad4130.c +++ b/drivers/iio/adc/ad4130.c @@ -2109,12 +2109,19 @@ static const struct of_device_id ad4130_of_match[] = { }; MODULE_DEVICE_TABLE(of, ad4130_of_match); +static const struct spi_device_id ad4130_id_table[] = { + { "ad4130" }, + { } +}; +MODULE_DEVICE_TABLE(spi, ad4130_id_table); + static struct spi_driver ad4130_driver = { .driver = { .name = AD4130_NAME, .of_match_table = ad4130_of_match, }, .probe = ad4130_probe, + .id_table = ad4130_id_table, }; module_spi_driver(ad4130_driver); |
