aboutsummaryrefslogtreecommitdiff
path: root/driver/main.h
diff options
context:
space:
mode:
Diffstat (limited to 'driver/main.h')
-rw-r--r--driver/main.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/driver/main.h b/driver/main.h
index a0ef924..666bcc1 100644
--- a/driver/main.h
+++ b/driver/main.h
@@ -5,18 +5,26 @@
#include "platform.h"
-static const struct of_device_id lork_ids[] = {
- { .compatible = "gpio-extern" },
+static const struct of_device_id lork_match[] = {
+ { .compatible = "lork-i2c" },
{},
};
-struct platform_driver lork_driver = {
+static const struct i2c_device_id lork_ids[] = {
+ { "foo", 0 },
+ {},
+};
+
+MODULE_DEVICE_TABLE(i2c, lork_ids);
+
+struct i2c_driver lork_driver = {
.probe = lork_probe,
.remove = lork_remove,
.driver = {
- .name = "gpio-extern",
+ .name = "lork",
.owner = THIS_MODULE,
- .of_match_table = of_match_ptr(lork_ids),
- }
+ .of_match_table = of_match_ptr(lork_match),
+ },
+ .id_table = lork_ids,
};