util/chromeos/gen_test_hwid.sh: Replace usage of hexdump
Hexdump command is not available in coreboot-sdk. Replace it with equivalent implementation using commands that are present in the container. TEST=Passed "VP46XX" as prefix variable and it produced the same crc32 result before and after the change. Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com> Change-Id: Icad93933335b8c5ebd8fee74cc9aaed36bb56482 Reviewed-on: https://review.coreboot.org/c/coreboot/+/68133 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Julius Werner <jwerner@chromium.org>
This commit is contained in:
parent
a3e68c9f95
commit
e6b96dceab
|
@ -13,7 +13,7 @@ main() {
|
|||
local prefix="$(echo "${board}" | tr a-z A-Z) TEST"
|
||||
# gzip has second-to-last 4 bytes in CRC32.
|
||||
local crc32="$(printf "${prefix}" | gzip -1 | tail -c 8 | head -c 4 | \
|
||||
hexdump -e '1/4 "%04u" ""' | tail -c 4)"
|
||||
od -An -vtu4 | tr -d '\n' | tail -c 4)"
|
||||
|
||||
echo "${prefix}" "${crc32}"
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue