[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190518214434.23660-1-lucasseikioshiro@gmail.com>
Date: Sat, 18 May 2019 18:44:34 -0300
From: Lucas Oshiro <lucasseikioshiro@...il.com>
To: Lars-Peter Clausen <lars@...afoo.de>,
Michael Hennerich <Michael.Hennerich@...log.com>,
Stefan Popa <stefan.popa@...log.com>,
Jonathan Cameron <jic23@...nel.org>,
Hartmut Knaack <knaack.h@....de>,
Peter Meerwald-Stadler <pmeerw@...erw.net>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: linux-iio@...r.kernel.org, devel@...verdev.osuosl.org,
linux-kernel@...r.kernel.org, kernel-usp@...glegroups.com,
Rodrigo Ribeiro <rodrigorsdc@...il.com>
Subject: [PATCH v2] staging: iio: adis16240: add device to module device table
Add a of_device_id struct and MODULE_DEVICE_TABLE call, in order to add
device-tree support for this driver.
Signed-off-by: Lucas Oshiro <lucasseikioshiro@...il.com>
Signed-off-by: Rodrigo Ribeiro <rodrigorsdc@...il.com>
Co-developed-by: Rodrigo Ribeiro <rodrigorsdc@...il.com>
---
drivers/staging/iio/accel/adis16240.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/staging/iio/accel/adis16240.c b/drivers/staging/iio/accel/adis16240.c
index b80e0d248b0f..8c6d23604eca 100644
--- a/drivers/staging/iio/accel/adis16240.c
+++ b/drivers/staging/iio/accel/adis16240.c
@@ -435,6 +435,12 @@ static int adis16240_remove(struct spi_device *spi)
return 0;
}
+static const struct of_device_id adis16240_of_match[] = {
+ { .compatible = "adi,adis16240" },
+ { },
+};
+MODULE_DEVICE_TABLE(of, adis16240_of_match);
+
static struct spi_driver adis16240_driver = {
.driver = {
.name = "adis16240",
--
2.21.0
Powered by blists - more mailing lists