Commit abc8b561 authored by Benoit Rat's avatar Benoit Rat

userspace/startup-mb: fix scb_ver to get it from hwinfo in DF.

This fix is needed by 7S-SCBv3.4-S2 because it mounts the old AT45DB642D. 
The patch is temporary because wrs_version will use dotconfig for next 
release. It is why we have an "ugly" but working parsing.
parent 52704b1f
...@@ -16,11 +16,14 @@ if [ "$tfpga" = "UNKNOWN" ]; then ...@@ -16,11 +16,14 @@ if [ "$tfpga" = "UNKNOWN" ]; then
fi fi
FP_FILE="$WR_HOME/lib/firmware/18p_mb-${tfpga}.bin" FP_FILE="$WR_HOME/lib/firmware/18p_mb-${tfpga}.bin"
# Get the SCB version from DF.
# TODO: Update wrsw_version to read this value from DF. scb_ver=$($WR_HOME/bin/wrs_version -t | grep scb-version | cut -d: -f2 | sed 's/[ \.]//g')
scb_ver=33 if [ "$scb_ver" = "UNKNOWN" ]; then
if mtdinfo -a | grep -A 1 dataflash | grep 264 &> /dev/null; then scb_ver=33
scb_ver=34 # For backward compatibility we can also check the type of DF.
if mtdinfo -a | grep -A 1 dataflash | grep -q 264; then
scb_ver=34
fi
fi fi
LM_FILE="$WR_HOME/lib/firmware/rt_cpu.elf" LM_FILE="$WR_HOME/lib/firmware/rt_cpu.elf"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment