drivers/intel/mipi_camera: Adding support for low power camera probe

Add a new configuration low_power_probe to avoid camera privacy LED
blink during the boot.

Change-Id: I27d5c66fb380ae6cd76d04ee82b7736407dac1b0
Signed-off-by: Pandya, Varshit B <varshit.b.pandya@intel.com>
Signed-off-by: Sugnan Prabhu S <sugnan.prabhu.s@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/52189
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Maulik V Vaghela <maulik.v.vaghela@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Sugnan Prabhu S 2021-02-09 10:31:15 +05:30 committed by Patrick Georgi
parent 194179c3d7
commit 60be9dbbc7
2 changed files with 13 additions and 0 deletions

View File

@ -433,6 +433,9 @@ static void camera_fill_sensor(const struct device *dev)
acpi_dp_add_array(dsd, lens_focus); acpi_dp_add_array(dsd, lens_focus);
} }
if (config->low_power_probe)
acpi_dp_add_integer(dsd, "i2c-allow-low-power-probe", 0x01);
acpi_dp_add_child(dsd, "port0", prt0); acpi_dp_add_child(dsd, "port0", prt0);
acpi_dp_write(dsd); acpi_dp_write(dsd);
@ -480,6 +483,10 @@ static void camera_fill_nvm(const struct device *dev)
acpi_dp_add_integer(dsd, "address-width", config->nvm_width); acpi_dp_add_integer(dsd, "address-width", config->nvm_width);
acpi_dp_add_string(dsd, "compatible", config->nvm_compat); acpi_dp_add_string(dsd, "compatible", config->nvm_compat);
if (config->low_power_probe)
acpi_dp_add_integer(dsd, "i2c-allow-low-power-probe", 0x01);
acpi_dp_write(dsd); acpi_dp_write(dsd);
} }
@ -493,6 +500,10 @@ static void camera_fill_vcm(const struct device *dev)
dsd = acpi_dp_new_table("_DSD"); dsd = acpi_dp_new_table("_DSD");
acpi_dp_add_string(dsd, "compatible", config->vcm_compat); acpi_dp_add_string(dsd, "compatible", config->vcm_compat);
if (config->low_power_probe)
acpi_dp_add_integer(dsd, "i2c-allow-low-power-probe", 0x01);
acpi_dp_write(dsd); acpi_dp_write(dsd);
} }

View File

@ -247,6 +247,8 @@ struct drivers_intel_mipi_camera_config {
const char *vcm_compat; const char *vcm_compat;
/* Does the device have a power resource entries */ /* Does the device have a power resource entries */
bool has_power_resource; bool has_power_resource;
/* Perform low power probe */
bool low_power_probe;
}; };
#endif #endif