diff options
author | Jonathan Zhang <jonzhang@meta.com> | 2022-10-21 18:07:41 -0700 |
---|---|---|
committer | Martin Roth <martin.roth@amd.corp-partner.google.com> | 2022-10-31 03:32:09 +0000 |
commit | 9f9bfdd5a1a314633d8ac154ed2d2b5b90653865 (patch) | |
tree | bbf61b27f8299f1f5641ed9033893bd332f050b9 /src/drivers/ipmi | |
parent | cb3eaf680a367d3ea54741cb194c6e2c2af14858 (diff) |
drivers/ipmi/ipmi_kcs_ops.c: accommodate BMC revision being 0
BMC major/minor revision may be 0. Get the value directly from
BMC without checking to accommodate such situation.
Signed-off-by: Tim Chu <Tim.Chu@quantatw.com>
Signed-off-by: Jonathan Zhang <jonzhang@meta.com>
Change-Id: I0e08c6d02de8f6efceb69b6d6cebad9d61cfd20e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/68685
Reviewed-by: Shuming Chu (Shuming) <s1218944@gmail.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Martin Roth <martin.roth@amd.corp-partner.google.com>
Diffstat (limited to 'src/drivers/ipmi')
-rw-r--r-- | src/drivers/ipmi/ipmi_kcs_ops.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/drivers/ipmi/ipmi_kcs_ops.c b/src/drivers/ipmi/ipmi_kcs_ops.c index a2ad7abd86..28ced49f53 100644 --- a/src/drivers/ipmi/ipmi_kcs_ops.c +++ b/src/drivers/ipmi/ipmi_kcs_ops.c @@ -259,14 +259,8 @@ static void ipmi_ssdt(const struct device *dev) void ipmi_bmc_version(uint8_t *ipmi_bmc_major_revision, uint8_t *ipmi_bmc_minor_revision) { - if (!bmc_revision_major || !bmc_revision_minor) { - printk(BIOS_ERR, "IPMI: BMC revision missing\n"); - *ipmi_bmc_major_revision = 0; - *ipmi_bmc_minor_revision = 0; - } else { - *ipmi_bmc_major_revision = bmc_revision_major; - *ipmi_bmc_minor_revision = bmc_revision_minor; - } + *ipmi_bmc_major_revision = bmc_revision_major; + *ipmi_bmc_minor_revision = bmc_revision_minor; } #if CONFIG(GENERATE_SMBIOS_TABLES) |