diff options
| author | Anton Blanchard <anton@samba.org> | 2003-05-03 09:24:05 +1000 |
|---|---|---|
| committer | Anton Blanchard <anton@samba.org> | 2003-05-03 09:24:05 +1000 |
| commit | 175967cf592fb068172c1bd7679f5aed12ce5595 (patch) | |
| tree | 6334c754de3b835e962318e31d49eded42c1090b | |
| parent | 3ded9b7a28f81c9d527484cea6f1910d7fa40012 (diff) | |
ppc64: firmware flash fix from Olof Johansson
| -rw-r--r-- | arch/ppc64/kernel/rtas.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/ppc64/kernel/rtas.c b/arch/ppc64/kernel/rtas.c index 963726cde947..b7e38e75b712 100644 --- a/arch/ppc64/kernel/rtas.c +++ b/arch/ppc64/kernel/rtas.c @@ -216,7 +216,11 @@ rtas_flash_firmware(void) image_size += f->blocks[i].length; } next = f->next; - f->next = (struct flash_block_list *)virt_to_absolute((unsigned long)f->next); + /* Don't translate NULL pointer for last entry */ + if(f->next) + f->next = (struct flash_block_list *)virt_to_absolute((unsigned long)f->next); + else + f->next = 0LL; /* make num_blocks into the version/length field */ f->num_blocks = (FLASH_BLOCK_LIST_VERSION << 56) | ((f->num_blocks+1)*16); } |
