From 6af3d0ea72a6f6852bda7519278a0c6fdd16d2b5 Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Tue, 21 Apr 2009 19:15:55 -0700 Subject: [PATCH] a20: advance A20Test by a large, prime number Rather than simply incrementing A20Test, advance it by a large prime number every time. The reason is to minimize false aliasing as quickly as possible. Signed-off-by: H. Peter Anvin --- core/bcopy32.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/bcopy32.inc b/core/bcopy32.inc index 97b9263..c715557 100644 --- a/core/bcopy32.inc +++ b/core/bcopy32.inc @@ -333,7 +333,7 @@ a20_test: mov eax,[cs:A20Test] mov cx,32 ; Loop count jmp .test ; First iteration = early out -.wait: inc eax +.wait: add eax,0x430aea41 ; A large prime number mov [cs:A20Test],eax io_delay ; Serialize, and fix delay .test: cmp eax,[es:A20Test+10h] -- 2.7.4