Skip to content

Commit

Permalink
iio: imu: adis16480: Add OF device ID table
Browse files Browse the repository at this point in the history
The driver does not have a struct of_device_id table, but supported
devices are registered via Device Trees. This patch adds OF device ID
table.

Signed-off-by: Stefan Popa <stefan.popa@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
  • Loading branch information
Stefan Popa authored and Jonathan Cameron committed Apr 4, 2019
1 parent cede2f8 commit 304840c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions drivers/iio/imu/adis16480.c
Original file line number Diff line number Diff line change
Expand Up @@ -991,9 +991,19 @@ static const struct spi_device_id adis16480_ids[] = {
};
MODULE_DEVICE_TABLE(spi, adis16480_ids);

static const struct of_device_id adis16480_of_match[] = {
{ .compatible = "adi,adis16375" },
{ .compatible = "adi,adis16480" },
{ .compatible = "adi,adis16485" },
{ .compatible = "adi,adis16488" },
{ },
};
MODULE_DEVICE_TABLE(of, adis16480_of_match);

static struct spi_driver adis16480_driver = {
.driver = {
.name = "adis16480",
.of_match_table = adis16480_of_match,
},
.id_table = adis16480_ids,
.probe = adis16480_probe,
Expand Down

0 comments on commit 304840c

Please sign in to comment.