[2410] 2009-07-15 Pavel Roskin <[email protected]>

Pavel Roskin <[email protected]> Wed, 15 Jul 2009 14:58:08 +0000
Newsgroups gmane.comp.boot-loaders.grub.cvs
Message-ID <[email protected]>
Revision: 2410
          http://svn.sv.gnu.org/viewvc/?view=rev&root=grub&revision=2410
Author:   proski
Date:     2009-07-15 14:58:07 +0000 (Wed, 15 Jul 2009)
Log Message:
-----------
2009-07-15  Pavel Roskin  <[email protected]>

	* boot/i386/pc/boot.S (kernel_segment): Remove.
	(copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
	for destination.

Modified Paths:
--------------
    trunk/grub2/ChangeLog
    trunk/grub2/boot/i386/pc/boot.S

Modified: trunk/grub2/ChangeLog
===================================================================
--- trunk/grub2/ChangeLog	2009-07-15 14:55:24 UTC (rev 2409)
+++ trunk/grub2/ChangeLog	2009-07-15 14:58:07 UTC (rev 2410)
@@ -1,5 +1,9 @@
 2009-07-15  Pavel Roskin  <[email protected]>
 
+	* boot/i386/pc/boot.S (kernel_segment): Remove.
+	(copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
+	for destination.
+
 	* boot/i386/pc/boot.S (boot_version): Remove.
 	* include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
 	Remove.

Modified: trunk/grub2/boot/i386/pc/boot.S
===================================================================
--- trunk/grub2/boot/i386/pc/boot.S	2009-07-15 14:55:24 UTC (rev 2409)
+++ trunk/grub2/boot/i386/pc/boot.S	2009-07-15 14:58:07 UTC (rev 2410)
@@ -94,8 +94,6 @@
 
 kernel_address:
 	.word	GRUB_BOOT_MACHINE_KERNEL_ADDR
-kernel_segment:
-	.word	GRUB_BOOT_MACHINE_KERNEL_SEG
 
 	. = _start + GRUB_BOOT_MACHINE_KERNEL_SECTOR
 kernel_sector:
@@ -372,13 +370,6 @@
 	movw	%es, %bx
 
 copy_buffer:
-#ifdef APPLE_CC
-	kernel_segment_abs = ABS (kernel_segment)
-	movw	(kernel_segment_abs), %es
-#else
-	movw	ABS(kernel_segment), %es
-#endif
-
 	/*
 	 * We need to save %cx and %si because the startup code in
 	 * kernel uses them without initializing them.
@@ -389,7 +380,8 @@
 	movw	$0x100, %cx
 	movw	%bx, %ds
 	xorw	%si, %si
-	xorw	%di, %di
+	movw	$GRUB_BOOT_MACHINE_KERNEL_ADDR, %di
+	movw	%si, %es
 
 	cld