diff options
author | Stefan Reinauer <reinauer@chromium.org> | 2011-11-17 13:03:38 -0800 |
---|---|---|
committer | Stefan Reinauer <stefan.reinauer@coreboot.org> | 2012-03-30 17:58:55 +0200 |
commit | 8acbc2a8865ca74f0f80c51c6511b9ab4c03d552 (patch) | |
tree | c6a901f5e2e4daea98be03ff6f8c88aa25ef2289 /src/arch | |
parent | 77adc5e03cd72ba4091ebf446abc3b19a73ee8fb (diff) |
use movsl for copying resume memory back
It's not significantly faster, but easier to read and smaller.
Change-Id: Ibab0b478873912d67bf1f07743f628586353368a
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/755
Reviewed-by: Mathias Krause <minipli@googlemail.com>
Tested-by: build bot (Jenkins)
Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/x86/boot/wakeup.S | 23 |
1 files changed, 6 insertions, 17 deletions
diff --git a/src/arch/x86/boot/wakeup.S b/src/arch/x86/boot/wakeup.S index a1df4d5597..8ae337ca5d 100644 --- a/src/arch/x86/boot/wakeup.S +++ b/src/arch/x86/boot/wakeup.S @@ -38,23 +38,12 @@ __wakeup: movw %ax, (__wakeup_segment) /* Then overwrite coreboot with our backed up memory */ - movl 8(%esp), %esi - movl 12(%esp), %edi - movl 16(%esp), %ecx - shrl $4, %ecx -1: - movl 0(%esi),%eax - movl 4(%esi),%edx - movl 8(%esi),%ebx - movl 12(%esi),%ebp - addl $16,%esi - subl $1,%ecx - movl %eax,0(%edi) - movl %edx,4(%edi) - movl %ebx,8(%edi) - movl %ebp,12(%edi) - leal 16(%edi),%edi - jne 1b + cld + movl 8(%esp), %esi + movl 12(%esp), %edi + movl 16(%esp), %ecx + shrl $2, %ecx + rep movsl /* Activate the right segment descriptor real mode. */ ljmp $0x28, $RELOCATED(1f) |