Check the value of ulzma and do not continue if there was an error.

Print fewer characters for pointers to make the output more concise.

Signed-off-by: Myles Watson <mylesgw@gmail.com>
Acked-by: Stefan Reinauer <stepan@coresystems.de>


git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5602 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
Myles Watson 2010-06-01 15:19:25 +00:00
parent 74cd569821
commit 94de72b919
1 changed files with 3 additions and 1 deletions

View File

@ -473,6 +473,8 @@ static int load_self_segments(
case CBFS_COMPRESS_LZMA: { case CBFS_COMPRESS_LZMA: {
printk(BIOS_DEBUG, "using LZMA\n"); printk(BIOS_DEBUG, "using LZMA\n");
len = ulzma(src, dest); len = ulzma(src, dest);
if (!len) /* Decompression Error. */
return 0;
break; break;
} }
#if CONFIG_COMPRESSED_PAYLOAD_NRV2B==1 #if CONFIG_COMPRESSED_PAYLOAD_NRV2B==1
@ -495,7 +497,7 @@ static int load_self_segments(
} }
end = dest + ptr->s_memsz; end = dest + ptr->s_memsz;
middle = dest + len; middle = dest + len;
printk(BIOS_SPEW, "[ 0x%016lx, %016lx, 0x%016lx) <- %016lx\n", printk(BIOS_SPEW, "[ 0x%08lx, %08lx, 0x%08lx) <- %08lx\n",
(unsigned long)dest, (unsigned long)dest,
(unsigned long)middle, (unsigned long)middle,
(unsigned long)end, (unsigned long)end,