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

[media] media: i2c: ths8200: add OF support

add OF support for the ths8200 driver.

Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>

authored by

Lad, Prabhakar and committed by
Mauro Carvalho Chehab
0fb0f8f5 ed29f894

+28
+19
Documentation/devicetree/bindings/media/i2c/ths8200.txt
··· 1 + * Texas Instruments THS8200 video encoder 2 + 3 + The ths8200 device is a digital to analog converter used in DVD players, video 4 + recorders, set-top boxes. 5 + 6 + Required Properties : 7 + - compatible : value must be "ti,ths8200" 8 + 9 + Example: 10 + 11 + i2c0@1c22000 { 12 + ... 13 + ... 14 + ths8200@5c { 15 + compatible = "ti,ths8200"; 16 + reg = <0x5c>; 17 + }; 18 + ... 19 + };
+9
drivers/media/i2c/ths8200.c
··· 550 550 }; 551 551 MODULE_DEVICE_TABLE(i2c, ths8200_id); 552 552 553 + #if IS_ENABLED(CONFIG_OF) 554 + static const struct of_device_id ths8200_of_match[] = { 555 + { .compatible = "ti,ths8200", }, 556 + { /* sentinel */ }, 557 + }; 558 + MODULE_DEVICE_TABLE(of, ths8200_of_match); 559 + #endif 560 + 553 561 static struct i2c_driver ths8200_driver = { 554 562 .driver = { 555 563 .owner = THIS_MODULE, 556 564 .name = "ths8200", 565 + .of_match_table = of_match_ptr(ths8200_of_match), 557 566 }, 558 567 .probe = ths8200_probe, 559 568 .remove = ths8200_remove,