Index: stage2/asm.S
===================================================================
RCS file: /cvs/grub/stage2/asm.S,v
retrieving revision 1.50
diff -u -r1.50 asm.S
--- stage2/asm.S	2000/10/29 07:37:48	1.50
+++ stage2/asm.S	2000/10/30 12:03:43
@@ -44,6 +44,8 @@
 #else
 # define	ABS(x)	((x) - EXT_C(main) + 0x8200)
 #endif
+
+#define MSG(x)	movw $ABS(x), %si; call message
 	
 	.file	"asm.S"
 
@@ -275,7 +277,7 @@
 	/* shouldn't reach here */
 	jmp	EXT_C(hard_stop)
 	.code32
-	
+
 /*
  * track_int13(int drive)
  *
@@ -295,9 +297,19 @@
 	movw	2(%edi), %ax
 	movw	%ax, ABS(set_tf_int13_segment)
 
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+	.code32
+
 	/* save the new int13 handler */
 	movl	$ABS(set_tf_int13_handler), %eax
 	movl	%eax, (%edi)
+
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+	.code32
 		
 	/* replace the int1 handler */
 	movl	$0x4, %edi
@@ -305,8 +317,18 @@
 	movl	$ABS(int1_handler), %eax
 	movl	%eax, (%edi)
 
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+	.code32
+
 	/* read the MBR to call int13 successfully */
 	movb	8(%ebp), %dl
+
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+	.code32
 	
 	call	EXT_C(prot_to_real)
 	.code16
@@ -327,12 +349,22 @@
 	movl	$0x4, %edi
 	popl	(%edi)
 
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+	.code32
+
 	/* restore the int13 handler */
 	movl	$0x4c, %edi
 	movw	ABS(set_tf_int13_offset), %ax
 	movw	%ax, (%edi)
 	movw	ABS(set_tf_int13_segment), %ax
 	movw	%ax, 2(%edi)
+
+	call	EXT_C(prot_to_real)
+	.code16
+	DATA32	call	EXT_C(real_to_prot)
+.code32
 
 	popl	%edi
 	popl	%ebx
