From 0d5491fb083510fda1dc3c8a9fa15d45dc0fabcc Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Mon, 18 Aug 2014 03:16:11 +0200 Subject: pc, pc64: fix off by one error in _multibootentry --- sys/src/9/pc/l.s | 2 +- sys/src/9/pc64/l.s | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/src/9/pc/l.s b/sys/src/9/pc/l.s index 0808bd5c2..663107e7a 100644 --- a/sys/src/9/pc/l.s +++ b/sys/src/9/pc/l.s @@ -67,9 +67,9 @@ TEXT _multibootentry(SB), $0 SUBL DI, CX ADDL CX, SI ADDL CX, DI + INCL CX /* one more for post decrement */ STD REP; MOVSB - CLD ADDL $KZERO, BX MOVL BX, multiboot-KZERO(SB) MOVL $_startPADDR(SB), AX diff --git a/sys/src/9/pc64/l.s b/sys/src/9/pc64/l.s index f4c066a3c..78171a114 100644 --- a/sys/src/9/pc64/l.s +++ b/sys/src/9/pc64/l.s @@ -62,9 +62,9 @@ TEXT _multibootentry<>(SB), 1, $-4 SUBL DI, CX ADDL CX, SI ADDL CX, DI + INCL CX /* one more for post decrement */ STD REP; MOVSB - CLD MOVL BX, multibootptr-KZERO(SB) MOVL $_protected<>-KZERO(SB), AX JMP* AX -- cgit v1.2.3