From: Shehryar Ahmad <shehryar.amd@gmail.com>
To: Jonathan Cameron <jic23@kernel.org>
Cc: "Nuno Sá" <nuno.sa@analog.com>,
"Michael Hennerich" <Michael.Hennerich@analog.com>,
"David Lechner" <dlechner@baylibre.com>,
"Andy Shevchenko" <andy@kernel.org>,
linux@analog.com, linux-iio@vger.kernel.org,
linux-kernel@vger.kernel.org,
"Shehryar Ahmad" <shehryar.amd@gmail.com>
Subject: [PATCH 2/2] iio: accel: adis16209: Add OF device ID table
Date: Fri, 16 Oct 2026 16:45:27 +0500 [thread overview]
Message-ID: <20261016114527.128364-3-shehryar.amd@gmail.com> (raw)
In-Reply-To: <20261016114527.128364-1-shehryar.amd@gmail.com>
Add of_device_id table for adis16209 and register it with
MODULE_DEVICE_TABLE() to enable device tree based matching.
Signed-off-by: Shehryar Ahmad <shehryar.amd@gmail.com>
---
drivers/iio/accel/adis16209.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/iio/accel/adis16209.c b/drivers/iio/accel/adis16209.c
index 07a682d68..2dd140dd5 100644
--- a/drivers/iio/accel/adis16209.c
+++ b/drivers/iio/accel/adis16209.c
@@ -298,6 +298,12 @@ static int adis16209_probe(struct spi_device *spi)
return devm_iio_device_register(&spi->dev, indio_dev);
}
+static const struct of_device_id adis16209_of_match[] = {
+ { .compatible = "adi,adis16209" },
+ { }
+};
+MODULE_DEVICE_TABLE(of, adis16209_of_match);
+
static const struct spi_device_id adis16209_ids[] = {
{ .name = "adis16209" },
{ }
@@ -307,6 +313,7 @@ MODULE_DEVICE_TABLE(spi, adis16209_ids);
static struct spi_driver adis16209_driver = {
.driver = {
.name = "adis16209",
+ .of_match_table = adis16209_of_match,
},
.probe = adis16209_probe,
.id_table = adis16209_ids,
--
2.56.0
next prev parent reply other threads:[~2026-10-16 11:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-16 11:45 [PATCH 0/2] iio: accel: adis16209: add missing SPI and OF matching table Shehryar Ahmad
2026-10-16 11:45 ` [PATCH 1/2] iio: accel: adis16209: add SPI device ID table Shehryar Ahmad
2026-10-16 11:45 ` Shehryar Ahmad [this message]
2026-10-16 13:34 ` [PATCH 0/2] iio: accel: adis16209: add missing SPI and OF matching table Andy Shevchenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261016114527.128364-3-shehryar.amd@gmail.com \
--to=shehryar.amd@gmail.com \
--cc=Michael.Hennerich@analog.com \
--cc=andy@kernel.org \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@analog.com \
--cc=nuno.sa@analog.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®