From 4b0c8ccb141982ca47387046a09a604fe655a6e2 Mon Sep 17 00:00:00 2001 From: Subrata Banik Date: Mon, 19 Dec 2022 17:45:25 +0530 Subject: [PATCH] soc/intel/apollolake: Move DPTF ACPI Device IDs into header file This patch moves DPTF ACPI Device IDs into the header file (soc/dptf.h) so that upcoming patches in this patch train can achieve more common code. TEST=Able to build and boot Google/Reef. Signed-off-by: Subrata Banik Change-Id: I0ce956351afc06871c465b67f51cba8786ce52db Reviewed-on: https://review.coreboot.org/c/coreboot/+/71104 Reviewed-by: Sean Rhodes Reviewed-by: Eric Lai Reviewed-by: Sumeet R Pawnikar Tested-by: build bot (Jenkins) Reviewed-by: Kapil Porwal --- src/soc/intel/apollolake/dptf.c | 7 ++++--- src/soc/intel/apollolake/include/soc/dptf.h | 14 ++++++++++++++ 2 files changed, 18 insertions(+), 3 deletions(-) create mode 100644 src/soc/intel/apollolake/include/soc/dptf.h diff --git a/src/soc/intel/apollolake/dptf.c b/src/soc/intel/apollolake/dptf.c index 391a2d1ed0..a1ccb165a2 100644 --- a/src/soc/intel/apollolake/dptf.c +++ b/src/soc/intel/apollolake/dptf.c @@ -1,15 +1,16 @@ /* SPDX-License-Identifier: GPL-2.0-only */ #include +#include static const struct dptf_platform_info apl_dptf_platform_info = { .use_eisa_hids = true, /* _HID for the toplevel DPTF device, typically \_SB.DPTF */ - .dptf_device_hid = "INT3400", + .dptf_device_hid = DPTF_DPTF_DEVICE, /* _HID for Intel DPTF Generic Device (these require PTYP as well) */ - .generic_hid = "INT3403", + .generic_hid = DPTF_GEN_DEVICE, /* _HID for Intel DPTF Fan Device */ - .fan_hid = "INT3404", + .fan_hid = DPTF_FAN_DEVICE, }; const struct dptf_platform_info *soc_get_dptf_platform_info(void) diff --git a/src/soc/intel/apollolake/include/soc/dptf.h b/src/soc/intel/apollolake/include/soc/dptf.h new file mode 100644 index 0000000000..06cf9ebef4 --- /dev/null +++ b/src/soc/intel/apollolake/include/soc/dptf.h @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ + +#ifndef _SOC_DPTF_H_ +#define _SOC_DPTF_H_ + +/* Below are the unique ACPI Device IDs for thermal/dptf on Apollo Lake SoC. */ +/* DPTF ACPI Device ID */ +#define DPTF_DPTF_DEVICE "INT3400" +/* Generic ACPI Device ID for TSR0/1/2/3 and charger */ +#define DPTF_GEN_DEVICE "INT3403" +/* Fan ACPI Device ID */ +#define DPTF_FAN_DEVICE "INT3404" + +#endif /* _SOC_DPTF_H_ */