Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

led: max77650: 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 led driver loaded automatically.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Signed-off-by: Pavel Machek <pavel@ucw.cz>

authored by

Bartosz Golaszewski and committed by
Pavel
b0ff9860 4c3718f9

+7
+7
drivers/leds/leds-max77650.c
··· 135 135 return rv; 136 136 } 137 137 138 + static const struct of_device_id max77650_led_of_match[] = { 139 + { .compatible = "maxim,max77650-led" }, 140 + { } 141 + }; 142 + MODULE_DEVICE_TABLE(of, max77650_led_of_match); 143 + 138 144 static struct platform_driver max77650_led_driver = { 139 145 .driver = { 140 146 .name = "max77650-led", 147 + .of_match_table = max77650_led_of_match, 141 148 }, 142 149 .probe = max77650_led_probe, 143 150 };