From a122a2566e59c342afa697e442a8c9a8c381b24e Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Fri, 10 Oct 2008 12:21:25 -0700 Subject: memdisk: fix up new e820 code Correct the assembly portion of the new e820 code, which had been left, in effect, half finished. Signed-off-by: H. Peter Anvin --- memdisk/memdisk.asm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'memdisk') diff --git a/memdisk/memdisk.asm b/memdisk/memdisk.asm index 47b55fce..f1e463b5 100644 --- a/memdisk/memdisk.asm +++ b/memdisk/memdisk.asm @@ -553,22 +553,22 @@ int15_e820: mov [es:di+20],eax mov ecx,24 ; Bytes loaded .no_extattr: - push ecx mov eax,[bx-16] ; Start addr (low) + mov edx,[bx-12] ; Start addr (high) mov [es:di],eax - mov ecx,[bx-12] ; Start addr (high) mov [es:di+4],edx mov eax,[bx] ; End addr (low) mov edx,[bx+4] ; End addr (high) sub eax,[bx-16] ; Derive the length sbb edx,[bx-12] mov [es:di+8],eax ; Length (low) - mov [es:di+12],ecx ; Length (high) + mov [es:di+12],edx ; Length (high) cmp dword [bx+8],-1 ; Type of next = end? jne .notdone xor ebx,ebx ; Done with table .notdone: pop eax ; "SMAP" + mov edx,eax ; Some systems expect eax = edx = SMAP pop ds int15_success: mov byte [bp+6], 02h ; Clear CF -- cgit v1.2.1