-
Notifications
You must be signed in to change notification settings - Fork 279
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fby3: PFR: send CHKPT_COMPLETE when BMC boot complete (#1014)
Summary: - send CHKPT_COMPLETE when BMC boot complete. It could clear the watchdog timeout in CPLD in order to stop doing recovery. Pull Request resolved: facebookexternal/openbmc.wiwynn#1014 Test Plan: - Build and test pass on fbyv3. root@bmc-oob:/# bash /etc/init.d/setup-pfr.sh Bus: 12 Device address: 0x38 To write 2 bytes: 0xf 0x9 root@bmc-oob:~# i2craw 12 0x38 -r 1 -w "0x03" Bus: 12 Device address: 0x38 To write 1 bytes: 0x3 To read 1 bytes. Received: 0xe root@bmc-oob:~# Reviewed By: williamspatrick fbshipit-source-id: 3b6372dfb7
- Loading branch information
1 parent
64cf5c7
commit de522bc
Showing
2 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
35 changes: 35 additions & 0 deletions
35
meta-facebook/meta-fby3/recipes-fby3/plat-utils/files/setup-pfr.sh
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/bin/sh | ||
# | ||
# Copyright 2019-present Facebook. All Rights Reserved. | ||
# | ||
# This program file is free software; you can redistribute it and/or modify it | ||
# under the terms of the GNU General Public License as published by the | ||
# Free Software Foundation; version 2 of the License. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | ||
# for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program in a file named COPYING; if not, write to the | ||
# Free Software Foundation, Inc., | ||
# 51 Franklin Street, Fifth Floor, | ||
# Boston, MA 02110-1301 USA | ||
|
||
PATH=/sbin:/bin:/usr/sbin:/usr/bin | ||
|
||
. /usr/local/fbpackages/utils/ast-functions | ||
|
||
# CHKPT_COMPLETE | ||
|
||
BOARD_ID=$(get_bmc_board_id) | ||
# NIC EXP BMC | ||
if [ $BOARD_ID -eq 9 ]; then | ||
/usr/sbin/i2craw 9 0x38 -w "0x0F 0x09" | ||
# Baseboard BMC | ||
elif [ $BOARD_ID -eq 14 ] || [ $BOARD_ID -eq 7 ]; then | ||
/usr/sbin/i2craw 12 0x38 -w "0x0F 0x09" | ||
else | ||
echo "Is board id correct(id=$BOARD_ID)?" | ||
fi |
This file contains 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