commit | fb1950f0c3c27daac646d276ed24bcc4d5743c52 | [log] [tgz] |
---|---|---|
author | Michael Tritz <mtritz@us.ibm.com> | Mon Nov 13 11:05:03 2017 -0600 |
committer | Michael Tritz <mtritz@us.ibm.com> | Mon Nov 13 11:05:14 2017 -0600 |
tree | b97caed23260fd8679074f607f6b0da3bb9d713a | |
parent | b5da198802d1155b26a7366d0141b12cd5af5a37 [diff] |
Block attempts to create a pnor-patch volume in field mode This patch improves the obmc-flash-bios script by blocking attempts to create and mount a pnor-patch volume when the system is in field mode. When this scenario is reached, the current behavior is to error out because the script tries to mount pnor-patch to /usr/local/share/pnor, which is inaccessible in field mode. This fix simply blocks these attempts to suppress the error message. Change-Id: I78b5171e66f194d7b8d2b1baa639ee29a1b11794 Signed-off-by: Michael Tritz <mtritz@us.ibm.com>
diff --git a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/flash/openpower-software-manager/obmc-flash-bios b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/flash/openpower-software-manager/obmc-flash-bios index d92fad5..1c90e8b 100644 --- a/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/flash/openpower-software-manager/obmc-flash-bios +++ b/meta-openbmc-machines/meta-openpower/common/recipes-phosphor/flash/openpower-software-manager/obmc-flash-bios
@@ -112,6 +112,9 @@ pnordev="/dev/mtd${pnor}" if [[ "${name}" == "pnor-patch" ]]; then + if [[ "$(fw_printenv fieldmode 2>/dev/null)" == "fieldmode=true" ]]; then + return 0 + fi if [[ ! "$(hexdump -C -n 3 ${pnordev})" =~ "UBI" ]]; then return 0 fi