From 8cb21e7ea509e802e5419f7cfa37d38737193ea2 Mon Sep 17 00:00:00 2001 From: "P.K.Lee" Date: Wed, 19 Jan 2022 11:00:01 +0800 Subject: meta-quanta: s6q: Add x86-power-ctrl config files These config files contains the gpio configuartion which will be used by the x86 power control. Tested: Tested and verified in S6Q. Change-Id: I3e2684b2d7b0e6f3c6eb874569d5c82f6b733e02 Signed-off-by: P.K.Lee --- meta-quanta/meta-s6q/conf/machine/s6q.conf | 2 +- .../x86-power-control/power-config-host0.json | 63 ++++++++++++++++++++++ .../chassis/x86-power-control_%.bbappend | 7 +++ 3 files changed, 71 insertions(+), 1 deletion(-) create mode 100644 meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control/power-config-host0.json create mode 100755 meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control_%.bbappend (limited to 'meta-quanta') diff --git a/meta-quanta/meta-s6q/conf/machine/s6q.conf b/meta-quanta/meta-s6q/conf/machine/s6q.conf index f9a39e48a3..d32ac7a83e 100644 --- a/meta-quanta/meta-s6q/conf/machine/s6q.conf +++ b/meta-quanta/meta-s6q/conf/machine/s6q.conf @@ -10,7 +10,7 @@ require conf/machine/include/obmc-bsp-common.inc FLASH_SIZE = "65536" -OBMC_MACHINE_FEATURES += "\ +MACHINE_FEATURES += "\ obmc-bmc-state-mgmt \ obmc-chassis-state-mgmt \ obmc-host-ipmi \ diff --git a/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control/power-config-host0.json b/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control/power-config-host0.json new file mode 100644 index 0000000000..ef182d26b9 --- /dev/null +++ b/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control/power-config-host0.json @@ -0,0 +1,63 @@ +{ + "gpio_configs":[ + { + "Name" : "IdButton", + "LineName" : "FP_ID_BTN_SCM_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "PostComplete", + "LineName" : "FM_BIOS_POST_CMPLT_BMC_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "PowerButton", + "LineName" : "SYS_BMC_PWRBTN_R_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "PowerOk", + "LineName" : "PWRGD_PS_PWROK_PLD_R", + "Type" : "GPIO", + "Polarity" : "ActiveHigh" + }, + { + "Name" : "PowerOut", + "LineName" : "SYS_PWRBTN_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "ResetButton", + "LineName" : "FP_RST_BTN_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "ResetOut", + "LineName" : "FM_BMC_RSTBTN_OUT_N", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + }, + { + "Name" : "NMIOut", + "LineName" : "IRQ_BMC_PCH_NMI_R", + "Type" : "GPIO", + "Polarity" : "ActiveLow" + } +], + "timing_configs":{ + "PowerPulseMs": 200, + "ForceOffPulseMs": 15000, + "ResetPulseMs": 5500, + "PowerCycleMs": 10000, + "SioPowerGoodWatchdogMs": 1000, + "PsPowerOKWatchdogMs": 8000, + "GracefulPowerOffS": 300, + "WarmResetCheckMs": 500, + "PowerOffSaveMs": 7000 + } +} diff --git a/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control_%.bbappend b/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control_%.bbappend new file mode 100755 index 0000000000..95cb307b64 --- /dev/null +++ b/meta-quanta/meta-s6q/recipes-x86/chassis/x86-power-control_%.bbappend @@ -0,0 +1,7 @@ +FILESEXTRAPATHS:prepend:s6q := "${THISDIR}/${PN}:" +SRC_URI:append:s6q = " file://power-config-host0.json" + +do_install:append:s6q() { + install -m 0755 -d ${D}/${datadir}/${BPN} + install -m 0644 ${WORKDIR}/power-config-host0.json ${D}${datadir}/${BPN} +} -- cgit v1.2.3