From f96aa7a68780529fcef97dd207416cfcee9e68b9 Mon Sep 17 00:00:00 2001 From: Sumeet Pawnikar Date: Mon, 5 Jul 2021 21:09:53 +0530 Subject: IMOK: Add IMOK method support for DPTF Add IMOK method support for DPTF BRANCH=None BUG=b:187797417 TEST=Built and tested on dedede board Change-Id: I8edfa3bcaa6bde0b9690fcace000cd582dcc81d2 Signed-off-by: Sumeet Pawnikar Reviewed-on: https://review.coreboot.org/c/coreboot/+/54688 Tested-by: build bot (Jenkins) Reviewed-by: Tim Wawrzynczak --- src/drivers/intel/dptf/dptf.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/drivers/intel/dptf/dptf.c b/src/drivers/intel/dptf/dptf.c index f9b4dee5c5..24a371dda6 100644 --- a/src/drivers/intel/dptf/dptf.c +++ b/src/drivers/intel/dptf/dptf.c @@ -117,6 +117,15 @@ static void write_fan(const struct drivers_intel_dptf_config *config, acpigen_pop_len(); /* Device */ } +/* \_SB.DPTF */ +static void write_imok(void) +{ + acpigen_write_method("IMOK", 1); + /* Return (Arg0) */ + acpigen_emit_byte(RETURN_OP); + acpigen_emit_byte(ARG0_OP); + acpigen_write_method_end(); +} /* \_SB.DPTF */ static void write_oem_variables(const struct drivers_intel_dptf_config *config) { @@ -217,6 +226,7 @@ static void write_device_definitions(const struct device *dev) write_open_dptf_device(dev, platform_info); write_fan(config, platform_info); write_oem_variables(config); + write_imok(); write_generic_devices(config, platform_info); acpigen_pop_len(); /* DPTF Device (write_open_dptf_device) */ -- cgit v1.2.3