mirror of
https://review.coreboot.org/flashrom.git
synced 2025-04-27 23:22:37 +02:00
flashrom_tester: Parse fmap header as little endian
The fmap header was incorrectly parsed as big endian. BUG=b:240097529 BRANCH=None TEST=/usr/bin/flashrom_tester --debug :lib: host Coreboot_ELOG_sanity Change-Id: Ia683ce7a6ce3bc009218c300abb9c3a16ea06a6d Reviewed-on: https://review.coreboot.org/c/flashrom/+/66119 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
This commit is contained in:
parent
dfbcf63302
commit
81069f0c65
@ -253,7 +253,7 @@ fn elog_sanity_test(env: &mut TestEnv) -> TestResult {
|
||||
return Err("ELOG contained no data".into());
|
||||
}
|
||||
let data = fs::read(ELOG_FILE)?;
|
||||
if u32::from_be_bytes(data[0..4].try_into()?) != 0x474f4c45 {
|
||||
if u32::from_le_bytes(data[0..4].try_into()?) != 0x474f4c45 {
|
||||
return Err("ELOG had bad magic number".into());
|
||||
}
|
||||
Ok(())
|
||||
|
Loading…
x
Reference in New Issue
Block a user