drivers/intel/mipi_camera: Add DRIVERS_INTEL_MIPI_SUPPORTS_PRE_PRODUCTION_SOC

This adds DRIVERS_INTEL_MIPI_SUPPORTS_PRE_PRODUCTION_SOC to provide
the option to load pre-production or production signed IPU FW from IPU
kernel driver.

BUG=None
TEST=Build rex and brya to check if the build passes without an
error.

Change-Id: Ib507bceb6fd85d8ed764df82db400526a10e4d6e
Signed-off-by: Jamie Ryu <jamie.m.ryu@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/77854
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Jamie Ryu 2023-09-11 15:38:46 -07:00 committed by Felix Held
parent 26c440050c
commit d6f30923b2
2 changed files with 8 additions and 10 deletions

View File

@ -5,3 +5,9 @@ config DRIVERS_INTEL_MIPI_CAMERA
help help
MIPI CSI I2C camera SSDT generator. Generates SSDB and PWDB MIPI CSI I2C camera SSDT generator. Generates SSDB and PWDB
structures which are used by the Intel kernel drivers. structures which are used by the Intel kernel drivers.
config DRIVERS_INTEL_MIPI_SUPPORTS_PRE_PRODUCTION_SOC
def_bool n
help
Use this config to provide information to IPU kernel driver
if pre-production or production signed IPU FW needs to be loaded.

View File

@ -5,9 +5,7 @@
#include <acpi/acpi_device.h> #include <acpi/acpi_device.h>
#include <acpi/acpigen.h> #include <acpi/acpigen.h>
#include <acpi/acpigen_pci.h> #include <acpi/acpigen_pci.h>
#include <cpu/cpu.h>
#include <console/console.h> #include <console/console.h>
#include <cpu/intel/cpu_ids.h>
#include <device/i2c_simple.h> #include <device/i2c_simple.h>
#include <device/device.h> #include <device/device.h>
#include <device/path.h> #include <device/path.h>
@ -136,14 +134,8 @@ static void camera_fill_cio2(const struct device *dev)
snprintf(name, sizeof(name), "port%u", i); snprintf(name, sizeof(name), "port%u", i);
port_name[i] = strdup(name); port_name[i] = strdup(name);
if (CONFIG(ACPI_ADL_IPU_ES_SUPPORT)) { acpi_dp_add_integer(dsd, "is_es",
u32 cpu_id = cpu_get_cpuid(); CONFIG(DRIVERS_INTEL_MIPI_SUPPORTS_PRE_PRODUCTION_SOC));
if (cpu_id == CPUID_ALDERLAKE_J0 || cpu_id == CPUID_ALDERLAKE_Q0)
acpi_dp_add_integer(dsd, "is_es", 1);
else
acpi_dp_add_integer(dsd, "is_es", 0);
}
acpi_dp_add_child(dsd, port_name[i], port_table); acpi_dp_add_child(dsd, port_name[i], port_table);
} }