projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2b0d1c6
)
iio: gyro: bmg160: add device tree compatibility table
author
H. Nikolaus Schaller
<hns@goldelico.com>
Mon, 18 Mar 2019 15:14:14 +0000
(16:14 +0100)
committer
Jonathan Cameron
<Jonathan.Cameron@huawei.com>
Thu, 4 Apr 2019 19:20:52 +0000
(20:20 +0100)
Add of_match_table.
Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/gyro/bmg160_i2c.c
patch
|
blob
|
history
diff --git
a/drivers/iio/gyro/bmg160_i2c.c
b/drivers/iio/gyro/bmg160_i2c.c
index 90126a5a7663399cb7815de8262eb961c8e608ef..934a092134f05b27688e5cf4b4818ae6a0035460 100644
(file)
--- a/
drivers/iio/gyro/bmg160_i2c.c
+++ b/
drivers/iio/gyro/bmg160_i2c.c
@@
-54,10
+54,19
@@
static const struct i2c_device_id bmg160_i2c_id[] = {
MODULE_DEVICE_TABLE(i2c, bmg160_i2c_id);
+static const struct of_device_id bmg160_of_match[] = {
+ { .compatible = "bosch,bmg160" },
+ { .compatible = "bosch,bmi055_gyro" },
+ { }
+};
+
+MODULE_DEVICE_TABLE(of, bmg160_of_match);
+
static struct i2c_driver bmg160_i2c_driver = {
.driver = {
.name = "bmg160_i2c",
.acpi_match_table = ACPI_PTR(bmg160_acpi_match),
+ .of_match_table = bmg160_of_match,
.pm = &bmg160_pm_ops,
},
.probe = bmg160_i2c_probe,