x86: Tidy up error handling in mrccache_save()
authorSimon Glass <sjg@chromium.org>
Sat, 7 Dec 2019 04:42:06 +0000 (21:42 -0700)
committerBin Meng <bmeng.cn@gmail.com>
Sun, 15 Dec 2019 03:44:14 +0000 (11:44 +0800)
commit83f288f236505e2e73da8c8d2d72f97c0fe5b06b
tree972bb71f79680279aa8629b4a0b7e874b94cd799
parent37a508f8b7d580334b0a9b886539d7816944ece0
x86: Tidy up error handling in mrccache_save()

This function is a bit confusing at present due to the error handling.
Update it to remove the goto, returning errors as they happen.

While we are here, use hex for the data size since this is the norm in
U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
arch/x86/lib/mrccache.c