Remove initramfs workaround for u-boot environment.
Early in the dev-4.4 kernel lifetime a workaround was developed when the
fw_setenv command was failing. That issue does not appear with the
current kernel and the workaround can be removed.
Change-Id: I2a0f01f274b7ce76fbd1e80fe901cc86087ee5d8
Signed-off-by: Edward A. James <eajames@us.ibm.com>
diff --git a/common/recipes-phosphor/initfs/files/obmc-init.sh b/common/recipes-phosphor/initfs/files/obmc-init.sh
index 70af93d..a402ecb 100644
--- a/common/recipes-phosphor/initfs/files/obmc-init.sh
+++ b/common/recipes-phosphor/initfs/files/obmc-init.sh
@@ -64,10 +64,14 @@
# double \0 at the end of the environment.
# * print the value of the variable name passed as argument
- cat /run/fw_env |
- tr '\n\000' '\r\n' |
- tail -c +5 | tail -c +${copies-1} |
- sed -ne '/^$/,$d' -e "s/^$1=//p"
+ envdev=$(findmtd u-boot-env)
+ if test -n $envdev
+ then
+ cat /dev/$envdev |
+ tr '\n\000' '\r\n' |
+ tail -c +5 | tail -c +${copies-1} |
+ sed -ne '/^$/,$d' -e "s/^$1=//p"
+ fi
}
setup_resolv() {
@@ -150,13 +154,6 @@
fi
}
-env=$(findmtd u-boot-env)
-if test -n $env
-then
- ln -s /dev/$env /run/mtd:u-boot-env
- cp /run/mtd:u-boot-env /run/fw_env
-fi
-
rofs=$(findmtd rofs)
rwfs=$(findmtd rwfs)