diff options
author | Bin Meng <bmeng.cn@gmail.com> | 2021-07-07 18:00:21 +0800 |
---|---|---|
committer | Anup Patel <anup@brainfault.org> | 2021-07-11 14:09:10 +0530 |
commit | dcb756b01ac3b9d9bf56c125b17f4c80ee31a35b (patch) | |
tree | ab18c07b0a23321afa46e1660eb7594ef0944938 | |
parent | abfce9b25c7ec12a214bf3e9f85b5a3c8fb91b67 (diff) |
firmware: Remove the sanity checks in fw_save_info()
The sanity checks on the magic and version was already done in
fw_boot_hart(), which happens before fw_save_info() is called.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Xiang W <wxjstz@126.com>
Reviewed-by: Anup Patel <anup.patel@wdc.com>
-rw-r--r-- | firmware/fw_dynamic.S | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/firmware/fw_dynamic.S b/firmware/fw_dynamic.S index 0705e63..945fa04 100644 --- a/firmware/fw_dynamic.S +++ b/firmware/fw_dynamic.S @@ -57,14 +57,6 @@ fw_save_info: lla a4, _dynamic_next_arg1 REG_S a1, (a4) - /* Sanity checks */ - li a4, FW_DYNAMIC_INFO_MAGIC_VALUE - REG_L a3, FW_DYNAMIC_INFO_MAGIC_OFFSET(a2) - bne a3, a4, _bad_dynamic_info - li a4, FW_DYNAMIC_INFO_VERSION_MAX - REG_L a3, FW_DYNAMIC_INFO_VERSION_OFFSET(a2) - bgt a3, a4, _bad_dynamic_info - /* Save version == 0x1 fields */ lla a4, _dynamic_next_addr REG_L a3, FW_DYNAMIC_INFO_NEXT_ADDR_OFFSET(a2) |