fby3.5: cl: Fix that BIC reports wrong PCH sensor value during in-ban…#296
Closed
DelphineChiu wants to merge 1 commit into
Closed
fby3.5: cl: Fix that BIC reports wrong PCH sensor value during in-ban…#296DelphineChiu wants to merge 1 commit into
DelphineChiu wants to merge 1 commit into
Conversation
…d BIOS firmware updating Summary: - BIC reads the PCH sensors from ME through IPMI command. The wrong sensor value is reported while doing BIOS firmware updated. Follow the ME spec, the completion code, the scanning and reading state should be checked. If the completion code is not successfully or the scanning and reading state are disabled or unavailable, BIC returns unspecified error completion code. Test Plan: - Check the sensor reading value and SEL during in-band BIOS firmware updating - pass [Log] [root@OpenBIC_Refactor_Slot3 Y35CLE16]# ./afulnx_64 Y35CLE16.bin /x /me /RLC:F Skipping BTF generation for /root/Y35CLE16/DriverSource/amifldrv_impl.ko due to unavailability of vmlinux Skipping BTF generation for /root/Y35CLE16/DriverSource/amifldrv_mod.ko due to u[ 5421.687187] amifldrv_mod: loading out-of-tree module taints kernel. [ 5421.703248] amifldrv_mod: module license 'Proprietary' taints kernel. [ 5421.717549] Disabling lock debugging due to kernel taint navailability of vmlinux +---------------------------------------------------------------------------+ | AMI Firmware Update Utility v5.12.04.2099 | | Copyright (c) 1985-2020, American Megatrends International LLC. | | All rights reserved. Subject to AMI licensing agreement. | +---------------------------------------------------------------------------+ Reading flash ...................... Done - ME Data Size Checking ............ Pass - Check RomLayout .................. Pass Loading The ME Data To BIOS ........ Done - Update success for FDR - Update success for GBER - DER is locked, skip updating. Or trying assert HDA_SDO pin. - REGD is locked, skip updating. Or trying assert HDA_SDO pin. - Successful update recovery region to OPRx!! - Successful update MFSB - Successful update factory data and recovery region - Update MER ......................[ 5657.771270] NMI watchdog: Enabled. Permanently consumes one hw-PMU counter. - ME Entire Image update success !! WARNING !! System must power-off to have the changes which take effect! Process completed. root@bmc-oob:~# while [ 1 ]; do sensor-util slot1|grep "PCH Temp"; done ... PCH Temp (0x4) : 34.00 C | (ok) PCH Temp (0x4) : 34.00 C | (ok) PCH Temp (0x4) : 34.00 C | (ok) PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : NA | (na) ... PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : NA | (na) PCH Temp (0x4) : 34.00 C | (ok) PCH Temp (0x4) : 34.00 C | (ok) PCH Temp (0x4) : 34.00 C | (ok) root@bmc-oob:~# log-util slot1 --print 2018 Mar 09 07:41:47 log-util: User cleared FRU: 1 logs 1 slot1 2018-03-09 07:46:48 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:48, Sensor: ME_POWER_STATE (0x16), Event Data: (020000) POWER_OFF Assertion 1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update 1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update 1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update 1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update 1 slot1 2018-03-09 07:47:10 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:47:10, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update 1 slot1 2018-03-09 07:47:37 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:47:37, Sensor: ME_POWER_STATE (0x16), Event Data: (000000) RUNNING Assertion
GoldenBug
approved these changes
May 31, 2022
GoldenBug
left a comment
Contributor
There was a problem hiding this comment.
Thanks for the in-depth code comment. It really helps improve readability!
Contributor
|
@GoldenBug has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…d BIOS firmware updating
Summary:
The wrong sensor value is reported while doing BIOS firmware updated.
Follow the ME spec, the completion code, the scanning and reading state should be checked.
If the completion code is not successfully or the scanning and reading state are disabled or unavailable,
BIC returns unspecified error completion code.
Test Plan:
[Log]
[root@OpenBIC_Refactor_Slot3 Y35CLE16]# ./afulnx_64 Y35CLE16.bin /x /me /RLC:F
Skipping BTF generation for /root/Y35CLE16/DriverSource/amifldrv_impl.ko due to unavailability of vmlinux
Skipping BTF generation for /root/Y35CLE16/DriverSource/amifldrv_mod.ko due to u[ 5421.687187] amifldrv_mod: loading out-of-tree module taints kernel.
[ 5421.703248] amifldrv_mod: module license 'Proprietary' taints kernel.
[ 5421.717549] Disabling lock debugging due to kernel taint
navailability of vmlinux
+---------------------------------------------------------------------------+
| AMI Firmware Update Utility v5.12.04.2099 |
| Copyright (c) 1985-2020, American Megatrends International LLC. |
| All rights reserved. Subject to AMI licensing agreement. |
+---------------------------------------------------------------------------+
Reading flash ...................... Done
Loading The ME Data To BIOS ........ Done
WARNING !!
System must power-off to have the changes which take effect!
Process completed.
root@bmc-oob:
# while [ 1 ]; do sensor-util slot1|grep "PCH Temp"; done# log-util slot1 --print...
PCH Temp (0x4) : 34.00 C | (ok)
PCH Temp (0x4) : 34.00 C | (ok)
PCH Temp (0x4) : 34.00 C | (ok)
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : NA | (na)
...
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : NA | (na)
PCH Temp (0x4) : 34.00 C | (ok)
PCH Temp (0x4) : 34.00 C | (ok)
PCH Temp (0x4) : 34.00 C | (ok)
root@bmc-oob:
2018 Mar 09 07:41:47 log-util: User cleared FRU: 1 logs
1 slot1 2018-03-09 07:46:48 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:48, Sensor: ME_POWER_STATE (0x16), Event Data: (020000) POWER_OFF Assertion
1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update
1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update
1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update
1 slot1 2018-03-09 07:46:49 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:46:49, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update
1 slot1 2018-03-09 07:47:10 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:47:10, Sensor: SPS_FW_HEALTH (0x17), Event Data: (A00600) Direct Flash update
1 slot1 2018-03-09 07:47:37 ipmid SEL Entry: FRU: 1, Record: Standard (0x02), Time: 2018-03-09 07:47:37, Sensor: ME_POWER_STATE (0x16), Event Data: (000000) RUNNING Assertion