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:
04a14ae
)
iio: light: stk3310: Add device tree support
author
Luca Weiss
<luca@z3ntu.xyz>
Wed, 3 Jul 2019 18:05:59 +0000
(20:05 +0200)
committer
Jonathan Cameron
<Jonathan.Cameron@huawei.com>
Sat, 27 Jul 2019 19:11:15 +0000
(20:11 +0100)
Add device tree support for the stk33xx family of ambient light sensors.
Tested-by: Martijn Braam <martijn@brixit.nl>
Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/light/stk3310.c
patch
|
blob
|
history
diff --git
a/drivers/iio/light/stk3310.c
b/drivers/iio/light/stk3310.c
index b955183edfe81f2b9470f8c26a9042eb8f3242b4..185c24a75ae6fa2fadfc8c9736a3c550e865b42a 100644
(file)
--- a/
drivers/iio/light/stk3310.c
+++ b/
drivers/iio/light/stk3310.c
@@
-679,9
+679,18
@@
static const struct acpi_device_id stk3310_acpi_id[] = {
MODULE_DEVICE_TABLE(acpi, stk3310_acpi_id);
+static const struct of_device_id stk3310_of_match[] = {
+ { .compatible = "sensortek,stk3310", },
+ { .compatible = "sensortek,stk3311", },
+ { .compatible = "sensortek,stk3335", },
+ {}
+};
+MODULE_DEVICE_TABLE(of, stk3310_of_match);
+
static struct i2c_driver stk3310_driver = {
.driver = {
.name = "stk3310",
+ .of_match_table = stk3310_of_match,
.pm = STK3310_PM_OPS,
.acpi_match_table = ACPI_PTR(stk3310_acpi_id),
},