Skip to content

Commit e9241f4

Browse files
dlechnunojsa
authored andcommitted
iio: dac: ad8460: add SPI device match table
Add SPI device match table for ADI AD8460 DAC. As described in [1], this is required for the module to automatically load, even when using DT. [1]: https://lore.kernel.org/all/20210921192149.50740-1-broonie@kernel.org/ Signed-off-by: David Lechner <dlechner@baylibre.com> Link: https://patch.msgid.link/20241018-iio-dac-ad8460-add-spi-match-table-v1-1-84a5f903bf50@baylibre.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
1 parent c44922f commit e9241f4

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/iio/dac/ad8460.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -927,12 +927,19 @@ static const struct of_device_id ad8460_of_match[] = {
927927
};
928928
MODULE_DEVICE_TABLE(of, ad8460_of_match);
929929

930+
static const struct spi_device_id ad8460_spi_match[] = {
931+
{ .name = "ad8460" },
932+
{ }
933+
};
934+
MODULE_DEVICE_TABLE(spi, ad8460_spi_match);
935+
930936
static struct spi_driver ad8460_driver = {
931937
.driver = {
932938
.name = "ad8460",
933939
.of_match_table = ad8460_of_match,
934940
},
935941
.probe = ad8460_probe,
942+
.id_table = ad8460_spi_match,
936943
};
937944
module_spi_driver(ad8460_driver);
938945

0 commit comments

Comments
 (0)