summaryrefslogtreecommitdiffstats
path: root/sys/boot/i386
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2002-10-08 18:19:02 +0000
committerjhb <jhb@FreeBSD.org>2002-10-08 18:19:02 +0000
commit4c2a550344dc273f873c0dddb5e14a7968fd1f66 (patch)
treede6709c0ffa41c678ed58ac8ca4e50117440849c /sys/boot/i386
parent503c2bfc5f4aa1930defd69d927c27da83ac4473 (diff)
downloadFreeBSD-src-4c2a550344dc273f873c0dddb5e14a7968fd1f66.zip
FreeBSD-src-4c2a550344dc273f873c0dddb5e14a7968fd1f66.tar.gz
Revert MEM_USR back to 0xa000 for BTX clients. Instead, adjust boot2
to run at 0xc000 by changing its virtual start address from 0x1000 to 0x2000. Tested by: phk
Diffstat (limited to 'sys/boot/i386')
-rw-r--r--sys/boot/i386/boot2/Makefile2
-rw-r--r--sys/boot/i386/boot2/boot1.S12
-rw-r--r--sys/boot/i386/boot2/boot1.s12
-rw-r--r--sys/boot/i386/btx/btx/btx.S2
-rw-r--r--sys/boot/i386/btx/btx/btx.s2
-rw-r--r--sys/boot/i386/btx/btxldr/btxldr.S2
-rw-r--r--sys/boot/i386/btx/btxldr/btxldr.s2
-rw-r--r--sys/boot/i386/gptboot/Makefile2
8 files changed, 18 insertions, 18 deletions
diff --git a/sys/boot/i386/boot2/Makefile b/sys/boot/i386/boot2/Makefile
index 55e1dbe..aed315f 100644
--- a/sys/boot/i386/boot2/Makefile
+++ b/sys/boot/i386/boot2/Makefile
@@ -26,7 +26,7 @@ BTX= ${.CURDIR}/../btx
REL1= 0x700
ORG1= 0x7c00
-ORG2= 0x1000
+ORG2= 0x2000
# Setting this to anything else gives UFS1+2 support and larger
# boot2 binary.
diff --git a/sys/boot/i386/boot2/boot1.S b/sys/boot/i386/boot2/boot1.S
index c9079fe..61a7b8d 100644
--- a/sys/boot/i386/boot2/boot1.S
+++ b/sys/boot/i386/boot2/boot1.S
@@ -22,7 +22,7 @@
.set MEM_BUF,0x8c00 // Load area
.set MEM_BTX,0x9000 // BTX start
.set MEM_JMP,0x9010 // BTX entry point
- .set MEM_USR,0xb000 // Client start
+ .set MEM_USR,0xa000 // Client start
.set BDA_BOOT,0x472 // Boot howto flag
// Partition Constants
@@ -181,9 +181,9 @@ main.4: xor %dx,%dx // Partition:drive
// The second part is BTX, which is thus loaded into 0x9000, which is where
// it also runs from. The boot2.bin binary starts right after the end of
// BTX, so we have to figure out where the start of it is and then move the
-// binary to 0xb000. Normally, BTX clients start at MEM_USR, or 0xa000, but
-// when we use btxld to create boot2, we use an entry point of 0x1000. That
-// entry point is relative to MEM_USR; thus boot2.bin starts at 0xb000.
+// binary to 0xc000. Normally, BTX clients start at MEM_USR, or 0xa000, but
+// when we use btxld to create boot2, we use an entry point of 0x2000. That
+// entry point is relative to MEM_USR; thus boot2.bin starts at 0xc000.
//
main.5: mov %dx,MEM_ARG // Save args
movb $NSECT,%dh // Sector count
@@ -191,8 +191,8 @@ main.5: mov %dx,MEM_ARG // Save args
mov $MEM_BTX,%bx // BTX
mov 0xa(%bx),%si // Get BTX length and set
add %bx,%si // %si to start of boot2.bin
- mov $MEM_USR+SIZ_PAG,%di // Client page 1
- mov $MEM_BTX+(NSECT-2)*SIZ_SEC,%cx // Byte
+ mov $MEM_USR+SIZ_PAG*2,%di // Client page 2
+ mov $MEM_BTX+(NSECT-2)*SIZ_SEC,%cx // Byte
sub %si,%cx // count
rep // Relocate
movsb // client
diff --git a/sys/boot/i386/boot2/boot1.s b/sys/boot/i386/boot2/boot1.s
index c9079fe..61a7b8d 100644
--- a/sys/boot/i386/boot2/boot1.s
+++ b/sys/boot/i386/boot2/boot1.s
@@ -22,7 +22,7 @@
.set MEM_BUF,0x8c00 // Load area
.set MEM_BTX,0x9000 // BTX start
.set MEM_JMP,0x9010 // BTX entry point
- .set MEM_USR,0xb000 // Client start
+ .set MEM_USR,0xa000 // Client start
.set BDA_BOOT,0x472 // Boot howto flag
// Partition Constants
@@ -181,9 +181,9 @@ main.4: xor %dx,%dx // Partition:drive
// The second part is BTX, which is thus loaded into 0x9000, which is where
// it also runs from. The boot2.bin binary starts right after the end of
// BTX, so we have to figure out where the start of it is and then move the
-// binary to 0xb000. Normally, BTX clients start at MEM_USR, or 0xa000, but
-// when we use btxld to create boot2, we use an entry point of 0x1000. That
-// entry point is relative to MEM_USR; thus boot2.bin starts at 0xb000.
+// binary to 0xc000. Normally, BTX clients start at MEM_USR, or 0xa000, but
+// when we use btxld to create boot2, we use an entry point of 0x2000. That
+// entry point is relative to MEM_USR; thus boot2.bin starts at 0xc000.
//
main.5: mov %dx,MEM_ARG // Save args
movb $NSECT,%dh // Sector count
@@ -191,8 +191,8 @@ main.5: mov %dx,MEM_ARG // Save args
mov $MEM_BTX,%bx // BTX
mov 0xa(%bx),%si // Get BTX length and set
add %bx,%si // %si to start of boot2.bin
- mov $MEM_USR+SIZ_PAG,%di // Client page 1
- mov $MEM_BTX+(NSECT-2)*SIZ_SEC,%cx // Byte
+ mov $MEM_USR+SIZ_PAG*2,%di // Client page 2
+ mov $MEM_BTX+(NSECT-2)*SIZ_SEC,%cx // Byte
sub %si,%cx // count
rep // Relocate
movsb // client
diff --git a/sys/boot/i386/btx/btx/btx.S b/sys/boot/i386/btx/btx/btx.S
index cdcf448..e5c8ec4 100644
--- a/sys/boot/i386/btx/btx/btx.S
+++ b/sys/boot/i386/btx/btx/btx.S
@@ -28,7 +28,7 @@
.set MEM_DIR,0x4000 # Page directory
.set MEM_TBL,0x5000 # Page tables
.set MEM_ORG,0x9000 # BTX code
- .set MEM_USR,0xb000 # Start of user memory
+ .set MEM_USR,0xa000 # Start of user memory
#
# Paging control.
#
diff --git a/sys/boot/i386/btx/btx/btx.s b/sys/boot/i386/btx/btx/btx.s
index cdcf448..e5c8ec4 100644
--- a/sys/boot/i386/btx/btx/btx.s
+++ b/sys/boot/i386/btx/btx/btx.s
@@ -28,7 +28,7 @@
.set MEM_DIR,0x4000 # Page directory
.set MEM_TBL,0x5000 # Page tables
.set MEM_ORG,0x9000 # BTX code
- .set MEM_USR,0xb000 # Start of user memory
+ .set MEM_USR,0xa000 # Start of user memory
#
# Paging control.
#
diff --git a/sys/boot/i386/btx/btxldr/btxldr.S b/sys/boot/i386/btx/btxldr/btxldr.S
index b03354c..67a986c 100644
--- a/sys/boot/i386/btx/btxldr/btxldr.S
+++ b/sys/boot/i386/btx/btxldr/btxldr.S
@@ -166,7 +166,7 @@ ifdef(`BTXLDR_VERBOSE',`
call hexout # relocation
call putstr # message
')
- addl $PAG_SIZ * 2,%ebp # Display
+ addl $PAG_SIZ,%ebp # Display
ifdef(`BTXLDR_VERBOSE',`
movl $m_base,%esi # the
movl %ebp,%eax # user
diff --git a/sys/boot/i386/btx/btxldr/btxldr.s b/sys/boot/i386/btx/btxldr/btxldr.s
index b03354c..67a986c 100644
--- a/sys/boot/i386/btx/btxldr/btxldr.s
+++ b/sys/boot/i386/btx/btxldr/btxldr.s
@@ -166,7 +166,7 @@ ifdef(`BTXLDR_VERBOSE',`
call hexout # relocation
call putstr # message
')
- addl $PAG_SIZ * 2,%ebp # Display
+ addl $PAG_SIZ,%ebp # Display
ifdef(`BTXLDR_VERBOSE',`
movl $m_base,%esi # the
movl %ebp,%eax # user
diff --git a/sys/boot/i386/gptboot/Makefile b/sys/boot/i386/gptboot/Makefile
index 55e1dbe..aed315f 100644
--- a/sys/boot/i386/gptboot/Makefile
+++ b/sys/boot/i386/gptboot/Makefile
@@ -26,7 +26,7 @@ BTX= ${.CURDIR}/../btx
REL1= 0x700
ORG1= 0x7c00
-ORG2= 0x1000
+ORG2= 0x2000
# Setting this to anything else gives UFS1+2 support and larger
# boot2 binary.
OpenPOWER on IntegriCloud