From owner-cvs-all Fri Aug 4 15:37:28 2000 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 5061D37B6EC; Fri, 4 Aug 2000 15:37:23 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id PAA36603; Fri, 4 Aug 2000 15:37:23 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Message-Id: <200008042237.PAA36603@freefall.freebsd.org> From: John Baldwin Date: Fri, 4 Aug 2000 15:37:23 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/boot/i386/boot0 boot0.s X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG jhb 2000/08/04 15:37:23 PDT Modified files: sys/boot/i386/boot0 boot0.s Log: Argh! Fix a brainfart of mine. In the old boot0, we relocated ourself to 0x600 via a 'rep movsw'. Once that was done, %cx was zero, so we could simply use 'movb' to update the lower byte of %cx in preparation for zeroing out the fake partition entry used to boot to other drives via F5. Well, in the new boot0, we don't actually relocate ourselves, instead it is easier to create the fake partition entry first and then just use it to get the BIOS to load all of boot0 into memory at 0x600. However, since we aren't doing the relocate code anymore, we don't know that %cx == 0 when we hit the 'movb' to setup %cx for clearning the fake partition entry. Thus, if %ch != 0 when the BIOS started boot0, then it would end up zeroing a lot more memory than just 8 words. The solution is to do a word move of $8 into %cx. Debugging help from: David Wolfskill Revision Changes Path 1.20 +2 -2 src/sys/boot/i386/boot0/boot0.s To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message