Skip to content

Commit ce535a2

Browse files
brgldtor
authored andcommitted
Input: max77650-onkey - add of_match table
We need the of_match table if we want to use the compatible string in the pmic's child node and get the onkey driver loaded automatically. Signed-off-by: Bartosz Golaszewski <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
1 parent c15f8ba commit ce535a2

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/input/misc/max77650-onkey.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,16 @@ static int max77650_onkey_probe(struct platform_device *pdev)
108108
return input_register_device(onkey->input);
109109
}
110110

111+
static const struct of_device_id max77650_onkey_of_match[] = {
112+
{ .compatible = "maxim,max77650-onkey" },
113+
{ }
114+
};
115+
MODULE_DEVICE_TABLE(of, max77650_onkey_of_match);
116+
111117
static struct platform_driver max77650_onkey_driver = {
112118
.driver = {
113119
.name = "max77650-onkey",
120+
.of_match_table = max77650_onkey_of_match,
114121
},
115122
.probe = max77650_onkey_probe,
116123
};

0 commit comments

Comments
 (0)