diff options
| author | Vladimir Zapolskiy <[email protected]> | 2024-08-30 09:34:55 +0300 |
|---|---|---|
| committer | Hans Verkuil <[email protected]> | 2024-08-31 09:40:43 +0200 |
| commit | 4f6bec9dba371d3d3fa6e17dd7a29534ff12fdc6 (patch) | |
| tree | 7c319ac315e3b67eb58e8f6766ea5e6b19847965 | |
| parent | a85c73cd6709f8f513b09221f4e505a2a6f21961 (diff) | |
media: i2c: og01a1b: Add OF support to the image sensor driver
The OmniVision OG01A1B image sensor driver currently supports probing
only on ACPI platforms, the changes adds support of OF platforms to
the driver.
Signed-off-by: Vladimir Zapolskiy <[email protected]>
Signed-off-by: Sakari Ailus <[email protected]>
Signed-off-by: Hans Verkuil <[email protected]>
| -rw-r--r-- | drivers/media/i2c/og01a1b.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/media/i2c/og01a1b.c b/drivers/media/i2c/og01a1b.c index bac9597faf68..9e756c1c47df 100644 --- a/drivers/media/i2c/og01a1b.c +++ b/drivers/media/i2c/og01a1b.c @@ -1057,10 +1057,17 @@ static const struct acpi_device_id og01a1b_acpi_ids[] = { MODULE_DEVICE_TABLE(acpi, og01a1b_acpi_ids); #endif +static const struct of_device_id og01a1b_of_match[] = { + { .compatible = "ovti,og01a1b" }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(of, og01a1b_of_match); + static struct i2c_driver og01a1b_i2c_driver = { .driver = { .name = "og01a1b", .acpi_match_table = ACPI_PTR(og01a1b_acpi_ids), + .of_match_table = og01a1b_of_match, }, .probe = og01a1b_probe, .remove = og01a1b_remove, |