diff options
author | George Hung <george.hung@quantatw.com> | 2020-09-10 16:15:54 +0300 |
---|---|---|
committer | Andrew Geissler <geissonator@yahoo.com> | 2020-09-23 01:24:49 +0300 |
commit | 24be2dfa81d083ab315c2cf290b3b32a2d9e18d1 (patch) | |
tree | 9461227fe90684f75b1ddeb4c35aa85d4a20bbd8 /meta-quanta/meta-gbs/recipes-kernel/linux | |
parent | 3ab8923abb02d07d7586af54369962dfe23acf15 (diff) | |
download | openbmc-24be2dfa81d083ab315c2cf290b3b32a2d9e18d1.tar.xz |
meta-quanta: gbs: add VR/adm1272 temperature sensors
VR temperature sensor names:
vddcr_cpu
vddcr_soc
vddio_abcd
vddio_efgh
p12v_mobo
p12v_fan
adm1272 temperature sensor name:
hotswap
Note:
Since adm1272 PMON_CONFIG didn't enable temperature monitoring by
default, add the driver patch to support it
(From meta-quanta rev: c680ebe0310ff72dd0811616830d22f5d5bfa108)
Signed-off-by: George Hung <george.hung@quantatw.com>
Change-Id: Icb39c0827fe66faaa91d24b3fc93e15f53d21782
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Diffstat (limited to 'meta-quanta/meta-gbs/recipes-kernel/linux')
-rw-r--r-- | meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton/0001-meta-gbs-Enable-adm1272-ADM1272_TEMP1_EN.patch | 45 | ||||
-rw-r--r-- | meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton_%.bbappend | 1 |
2 files changed, 46 insertions, 0 deletions
diff --git a/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton/0001-meta-gbs-Enable-adm1272-ADM1272_TEMP1_EN.patch b/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton/0001-meta-gbs-Enable-adm1272-ADM1272_TEMP1_EN.patch new file mode 100644 index 0000000000..1cfd330ab9 --- /dev/null +++ b/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton/0001-meta-gbs-Enable-adm1272-ADM1272_TEMP1_EN.patch @@ -0,0 +1,45 @@ +From 8e211c8bc64521d772c4389219889a240b40307b Mon Sep 17 00:00:00 2001 +From: Charles <Charles.Hsu@quantatw.com> +Date: Fri, 14 Aug 2020 18:06:22 +0800 +Subject: [PATCH] meta-gis: Enable adm1272 ADM1272_TEMP1_EN + +--- + drivers/hwmon/pmbus/adm1275.c | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) + +diff --git a/drivers/hwmon/pmbus/adm1275.c b/drivers/hwmon/pmbus/adm1275.c +index 5caa37fbfc18..550b9a8388f6 100644 +--- a/drivers/hwmon/pmbus/adm1275.c ++++ b/drivers/hwmon/pmbus/adm1275.c +@@ -595,11 +595,13 @@ static int adm1275_probe(struct i2c_client *client, + tindex = 8; + + info->func[0] |= PMBUS_HAVE_PIN | PMBUS_HAVE_STATUS_INPUT | +- PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT; ++ PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT | ++ PMBUS_HAVE_TEMP | PMBUS_HAVE_STATUS_TEMP; + +- /* Enable VOUT if not enabled (it is disabled by default) */ +- if (!(config & ADM1278_VOUT_EN)) { +- config |= ADM1278_VOUT_EN; ++ ++ /* Enable VOUT & TEMP1 if not enabled (it is disabled by default) */ ++ if ((config & (ADM1278_VOUT_EN | ADM1278_TEMP1_EN)) != (ADM1278_VOUT_EN | ADM1278_TEMP1_EN)) { ++ config |= ADM1278_VOUT_EN | ADM1278_TEMP1_EN; + ret = i2c_smbus_write_byte_data(client, + ADM1275_PMON_CONFIG, + config); +@@ -610,9 +612,7 @@ static int adm1275_probe(struct i2c_client *client, + } + } + +- if (config & ADM1278_TEMP1_EN) +- info->func[0] |= +- PMBUS_HAVE_TEMP | PMBUS_HAVE_STATUS_TEMP; ++ + if (config & ADM1278_VIN_EN) + info->func[0] |= PMBUS_HAVE_VIN; + break; +-- +2.25.1 + diff --git a/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton_%.bbappend b/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton_%.bbappend index 6347ff6384..4de4ca9002 100644 --- a/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton_%.bbappend +++ b/meta-quanta/meta-gbs/recipes-kernel/linux/linux-nuvoton_%.bbappend @@ -4,3 +4,4 @@ SRC_URI_append_gbs = " file://0003-Add-basic-support-for-SB-TSI-sensors.patch" SRC_URI_append_gbs = " file://0004-Add-kernel-seven-seg-display-support.patch" SRC_URI_append_gbs = " file://0004-ben-drivers-misc-Character-device-driver-for-seven-segme.patch" SRC_URI_append_gbs = " file://0004-ben-drivers-misc-Platform-driver-for-seven-segment-displ.patch" +SRC_URI_append_gbs = " file://0001-meta-gbs-Enable-adm1272-ADM1272_TEMP1_EN.patch" |