mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-25 22:54:51 +02:00
DuetPkg BootSector: fix bugs in .S files so that 32-bit and 64-bit DUET can boot to Shell with boot sector binaries built by GCC.
There is also a bug in bs32.asm/bs32.S that the space between the code and the 0xAA55 ending signature is not enough to hold the 2 debug strings. It is fixed by shortening the strings. Signed-off-by: rsun3 Reviewed-by: niruiyu git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12930 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
e8ef42833f
commit
e7c4ef5ed4
@ -1,6 +1,6 @@
|
|||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
#*
|
#*
|
||||||
#* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
|
#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||||
#* This program and the accompanying materials
|
#* This program and the accompanying materials
|
||||||
#* are licensed and made available under the terms and conditions of the BSD License
|
#* are licensed and made available under the terms and conditions of the BSD License
|
||||||
#* which accompanies this distribution. The full text of the license may be found at
|
#* which accompanies this distribution. The full text of the license may be found at
|
||||||
@ -54,7 +54,7 @@ _start:
|
|||||||
xorw %ax, %ax # AX = 0x0000
|
xorw %ax, %ax # AX = 0x0000
|
||||||
movw $0x7c00, %bx # BX = 0x7C00
|
movw $0x7c00, %bx # BX = 0x7C00
|
||||||
movw $0x600, %bp # BP = 0x0600
|
movw $0x600, %bp # BP = 0x0600
|
||||||
movw RelocatedStart, %si # SI = Offset(RelocatedStart)
|
movw $RelocatedStart, %si # SI = Offset(RelocatedStart)
|
||||||
movw $0x200, %cx # CX = 0x0200
|
movw $0x200, %cx # CX = 0x0200
|
||||||
subw %si, %cx # CS = 0x0200 - Offset(RelocatedStart)
|
subw %si, %cx # CS = 0x0200 - Offset(RelocatedStart)
|
||||||
leaw (%bp,%si,), %di # DI = 0x0600 + Offset(RelocatedStart)
|
leaw (%bp,%si,), %di # DI = 0x0600 + Offset(RelocatedStart)
|
||||||
|
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
#*
|
#*
|
||||||
#* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
|
#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||||
#* This program and the accompanying materials
|
#* This program and the accompanying materials
|
||||||
#* are licensed and made available under the terms and conditions of the BSD License
|
#* are licensed and made available under the terms and conditions of the BSD License
|
||||||
#* which accompanies this distribution. The full text of the license may be found at
|
#* which accompanies this distribution. The full text of the license may be found at
|
||||||
@ -207,7 +207,7 @@ PrintString:
|
|||||||
movw %ax, %es
|
movw %ax, %es
|
||||||
movw $0x7c0, %ax
|
movw $0x7c0, %ax
|
||||||
movw %ax, %ds
|
movw %ax, %ds
|
||||||
movw $7, %cx
|
movw $6, %cx
|
||||||
movw $160, %di
|
movw $160, %di
|
||||||
rep
|
rep
|
||||||
movsw
|
movsw
|
||||||
@ -288,15 +288,15 @@ Halt:
|
|||||||
jmp Halt
|
jmp Halt
|
||||||
|
|
||||||
StartString:
|
StartString:
|
||||||
.byte 'B', 0x0c, 'S', 0x0c, 't', 0x0c, 'a', 0x0c, 'r', 0x0c, 't', 0x0c, '!', 0x0c
|
.byte 'B', 0x0c, 'S', 0x0c, 't', 0x0c, 'a', 0x0c, 'r', 0x0c, 't', 0x0c
|
||||||
ErrorString:
|
ErrorString:
|
||||||
.byte 'B', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c, '!', 0x0c
|
.byte 'B', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c
|
||||||
|
|
||||||
# ****************************************************************************
|
# ****************************************************************************
|
||||||
# LBA Offset for BootSector, need patched by tool for HD boot.
|
# LBA Offset for BootSector, need patched by tool for HD boot.
|
||||||
# ****************************************************************************
|
# ****************************************************************************
|
||||||
|
|
||||||
#.org 0x01fa
|
.org 0x01fa
|
||||||
LBAOffsetForBootSector:
|
LBAOffsetForBootSector:
|
||||||
.long 0x0
|
.long 0x0
|
||||||
|
|
||||||
@ -304,7 +304,7 @@ LBAOffsetForBootSector:
|
|||||||
# Sector Signature
|
# Sector Signature
|
||||||
# ****************************************************************************
|
# ****************************************************************************
|
||||||
|
|
||||||
#.org 0x01fe
|
.org 0x01fe
|
||||||
SectorSignature:
|
SectorSignature:
|
||||||
.word 0xaa55 # Boot Sector Signature
|
.word 0xaa55 # Boot Sector Signature
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
;------------------------------------------------------------------------------
|
;------------------------------------------------------------------------------
|
||||||
;*
|
;*
|
||||||
;* Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
|
;* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||||
;* This program and the accompanying materials
|
;* This program and the accompanying materials
|
||||||
;* are licensed and made available under the terms and conditions of the BSD License
|
;* are licensed and made available under the terms and conditions of the BSD License
|
||||||
;* which accompanies this distribution. The full text of the license may be found at
|
;* which accompanies this distribution. The full text of the license may be found at
|
||||||
@ -78,7 +78,7 @@ BootSectorEntryPoint:
|
|||||||
; ****************************************************************************
|
; ****************************************************************************
|
||||||
; Start Print
|
; Start Print
|
||||||
; ****************************************************************************
|
; ****************************************************************************
|
||||||
lea si, cs:[StartString]
|
mov si, offset StartString
|
||||||
call PrintString
|
call PrintString
|
||||||
|
|
||||||
; ****************************************************************************
|
; ****************************************************************************
|
||||||
@ -206,7 +206,7 @@ PrintString:
|
|||||||
mov es,ax
|
mov es,ax
|
||||||
mov ax, 07c0h
|
mov ax, 07c0h
|
||||||
mov ds, ax
|
mov ds, ax
|
||||||
mov cx, 7
|
mov cx, 6
|
||||||
mov di, 160
|
mov di, 160
|
||||||
rep movsw
|
rep movsw
|
||||||
ret
|
ret
|
||||||
@ -280,15 +280,15 @@ NotFoundAll:
|
|||||||
jne FoundEFILDR
|
jne FoundEFILDR
|
||||||
BadBootSector:
|
BadBootSector:
|
||||||
DiskError:
|
DiskError:
|
||||||
lea si, cs:[ErrorString]
|
mov si, offset ErrorString
|
||||||
call PrintString
|
call PrintString
|
||||||
Halt:
|
Halt:
|
||||||
jmp Halt
|
jmp Halt
|
||||||
|
|
||||||
StartString:
|
StartString:
|
||||||
db 'B', 0ch, 'S', 0ch, 't', 0ch, 'a', 0ch, 'r', 0ch, 't', 0ch, '!', 0ch
|
db 'B', 0ch, 'S', 0ch, 't', 0ch, 'a', 0ch, 'r', 0ch, 't', 0ch
|
||||||
ErrorString:
|
ErrorString:
|
||||||
db 'B', 0ch, 'E', 0ch, 'r', 0ch, 'r', 0ch, 'o', 0ch, 'r', 0ch, '!', 0ch
|
db 'B', 0ch, 'E', 0ch, 'r', 0ch, 'r', 0ch, 'o', 0ch, 'r', 0ch
|
||||||
|
|
||||||
; ****************************************************************************
|
; ****************************************************************************
|
||||||
; LBA Offset for BootSector, need patched by tool for HD boot.
|
; LBA Offset for BootSector, need patched by tool for HD boot.
|
||||||
|
@ -59,15 +59,16 @@ Start:
|
|||||||
call ClearScreen
|
call ClearScreen
|
||||||
|
|
||||||
# Populate IDT with meaningful offsets for exception handlers...
|
# Populate IDT with meaningful offsets for exception handlers...
|
||||||
sidt Idtr
|
movl $Idtr, %eax
|
||||||
|
sidt (%eax) # get fword address of IDT
|
||||||
|
|
||||||
|
|
||||||
movl Halt, %eax
|
movl $Halt, %eax
|
||||||
movl %eax,%ebx # use bx to copy 15..0 to descriptors
|
movl %eax,%ebx # use bx to copy 15..0 to descriptors
|
||||||
shrl $16,%eax # use ax to copy 31..16 to descriptors
|
shrl $16,%eax # use ax to copy 31..16 to descriptors
|
||||||
# 63..32 of descriptors is 0
|
# 63..32 of descriptors is 0
|
||||||
movl $0x78,%ecx # 78h IDT entries to initialize with unique entry points (exceptions)
|
movl $0x78,%ecx # 78h IDT entries to initialize with unique entry points (exceptions)
|
||||||
movl (Idtr + 2), %esi
|
movl $(Idtr + 2), %esi
|
||||||
movl (%esi),%edi
|
movl (%esi),%edi
|
||||||
|
|
||||||
LOOP_1: # loop through all IDT entries exception handlers and initialize to default handler
|
LOOP_1: # loop through all IDT entries exception handlers and initialize to default handler
|
||||||
@ -77,7 +78,7 @@ LOOP_1: # loop through all IDT entries e
|
|||||||
movw %ax, 6(%edi) # write bits 31..16 of offset
|
movw %ax, 6(%edi) # write bits 31..16 of offset
|
||||||
movl $0, 8(%edi) # write bits 31..16 of offset
|
movl $0, 8(%edi) # write bits 31..16 of offset
|
||||||
addl $16, %edi # move up to next descriptor
|
addl $16, %edi # move up to next descriptor
|
||||||
addw DEFAULT_HANDLER_SIZE, %bx # move to next entry point
|
addw $DEFAULT_HANDLER_SIZE, %bx # move to next entry point
|
||||||
loopl LOOP_1 # loop back through again until all descriptors are initialized
|
loopl LOOP_1 # loop back through again until all descriptors are initialized
|
||||||
|
|
||||||
## at this point edi contains the offset of the descriptor for INT 20
|
## at this point edi contains the offset of the descriptor for INT 20
|
||||||
@ -126,7 +127,7 @@ LOOP_1: # loop through all IDT entries e
|
|||||||
movl 0x30(%ebp),%edi # edi = [[22000 + [22014] + 3c] + 2c] = ImageBase (63..32 is zero, ignore)
|
movl 0x30(%ebp),%edi # edi = [[22000 + [22014] + 3c] + 2c] = ImageBase (63..32 is zero, ignore)
|
||||||
movl 0x28(%ebp),%eax # eax = [[22000 + [22014] + 3c] + 24] = EntryPoint
|
movl 0x28(%ebp),%eax # eax = [[22000 + [22014] + 3c] + 24] = EntryPoint
|
||||||
addl %edi,%eax # eax = ImageBase + EntryPoint
|
addl %edi,%eax # eax = ImageBase + EntryPoint
|
||||||
movl %ebx, EfiLdrOffset
|
movl $EfiLdrOffset, %ebx
|
||||||
movl %eax, (%ebx) # Modify far jump instruction for correct entry point
|
movl %eax, (%ebx) # Modify far jump instruction for correct entry point
|
||||||
|
|
||||||
movw 6(%ebp), %bx # bx = Number of sections
|
movw 6(%ebp), %bx # bx = Number of sections
|
||||||
@ -158,8 +159,8 @@ SectionLoop:
|
|||||||
cmpw $0,%bx
|
cmpw $0,%bx
|
||||||
jne SectionLoop
|
jne SectionLoop
|
||||||
|
|
||||||
movl (Idtr), %eax # get size of IDT
|
movl $Idtr, %edx # get size of IDT
|
||||||
movzx (%edx), %eax
|
movzxw (%edx), %eax
|
||||||
.byte 0xff
|
.byte 0xff
|
||||||
.byte 0xc0
|
.byte 0xc0
|
||||||
# inc eax
|
# inc eax
|
||||||
@ -968,7 +969,7 @@ commonIdtEntry:
|
|||||||
##
|
##
|
||||||
|
|
||||||
call ClearScreen
|
call ClearScreen
|
||||||
mov String1, %esi
|
movl $String1, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 16*8(%ebp),%eax ## move Int number into RAX
|
movl 16*8(%ebp),%eax ## move Int number into RAX
|
||||||
@ -977,11 +978,11 @@ commonIdtEntry:
|
|||||||
ja PrintDefaultString
|
ja PrintDefaultString
|
||||||
PrintExceptionString:
|
PrintExceptionString:
|
||||||
shll $3,%eax ## multiply by 8 to get offset from StringTable to actual string address
|
shll $3,%eax ## multiply by 8 to get offset from StringTable to actual string address
|
||||||
addl StringTable, %eax
|
addl $StringTable, %eax
|
||||||
movl (%eax),%esi
|
movl (%eax),%esi
|
||||||
jmp PrintTheString
|
jmp PrintTheString
|
||||||
PrintDefaultString:
|
PrintDefaultString:
|
||||||
movl IntUnknownString, %esi
|
movl $IntUnknownString, %esi
|
||||||
# patch Int number
|
# patch Int number
|
||||||
movl %eax,%edx
|
movl %eax,%edx
|
||||||
call A2C
|
call A2C
|
||||||
@ -992,7 +993,7 @@ PrintDefaultString:
|
|||||||
movb %al,(%esi)
|
movb %al,(%esi)
|
||||||
PrintTheString:
|
PrintTheString:
|
||||||
call PrintString
|
call PrintString
|
||||||
movl String2, %esi
|
movl $String2, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 19*8(%ebp),%eax # CS
|
movl 19*8(%ebp),%eax # CS
|
||||||
@ -1003,24 +1004,24 @@ PrintTheString:
|
|||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 18*8(%ebp),%eax # RIP
|
movl 18*8(%ebp),%eax # RIP
|
||||||
call PrintQword
|
call PrintQword
|
||||||
movl String3, %esi
|
movl $String3, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
|
|
||||||
movl $0xb8140,%edi
|
movl $0xb8140,%edi
|
||||||
|
|
||||||
movl StringRax, %esi
|
movl $StringRax, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 15*8(%ebp),%eax
|
movl 15*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringRcx, %esi
|
movl $StringRcx, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 14*8(%ebp),%eax
|
movl 14*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringRdx, %esi
|
movl $StringRdx, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 13*8(%ebp),%eax
|
movl 13*8(%ebp),%eax
|
||||||
@ -1028,19 +1029,19 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb81e0,%edi
|
movl $0xb81e0,%edi
|
||||||
|
|
||||||
movl StringRbx, %esi
|
movl $StringRbx, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 12*8(%ebp),%eax
|
movl 12*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringRsp, %esi
|
movl $StringRsp, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 21*8(%ebp),%eax
|
movl 21*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringRbp, %esi
|
movl $StringRbp, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 10*8(%ebp),%eax
|
movl 10*8(%ebp),%eax
|
||||||
@ -1048,19 +1049,19 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb8280,%edi
|
movl $0xb8280,%edi
|
||||||
|
|
||||||
movl StringRsi, %esi
|
movl $StringRsi, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 9*8(%ebp),%eax
|
movl 9*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringRdi, %esi
|
movl $StringRdi, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 8*8(%ebp),%eax
|
movl 8*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringEcode, %esi
|
movl $StringEcode, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 17*8(%ebp),%eax
|
movl 17*8(%ebp),%eax
|
||||||
@ -1068,19 +1069,19 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb8320,%edi
|
movl $0xb8320,%edi
|
||||||
|
|
||||||
movl StringR8, %esi
|
movl $StringR8, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 7*8(%ebp),%eax
|
movl 7*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringR9, %esi
|
movl $StringR9, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 6*8(%ebp),%eax
|
movl 6*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringR10, %esi
|
movl $StringR10, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 5*8(%ebp),%eax
|
movl 5*8(%ebp),%eax
|
||||||
@ -1088,19 +1089,19 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb83c0,%edi
|
movl $0xb83c0,%edi
|
||||||
|
|
||||||
movl StringR11, %esi
|
movl $StringR11, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 4*8(%ebp),%eax
|
movl 4*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringR12, %esi
|
movl $StringR12, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 3*8(%ebp),%eax
|
movl 3*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringR13, %esi
|
movl $StringR13, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 2*8(%ebp),%eax
|
movl 2*8(%ebp),%eax
|
||||||
@ -1108,19 +1109,19 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb8460,%edi
|
movl $0xb8460,%edi
|
||||||
|
|
||||||
movl StringR14, %esi
|
movl $StringR14, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 1*8(%ebp),%eax
|
movl 1*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringR15, %esi
|
movl $StringR15, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 0*8(%ebp),%eax
|
movl 0*8(%ebp),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
|
|
||||||
movl StringSs, %esi
|
movl $StringSs, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 22*8(%ebp),%eax
|
movl 22*8(%ebp),%eax
|
||||||
@ -1128,7 +1129,7 @@ PrintTheString:
|
|||||||
|
|
||||||
movl $0xb8500,%edi
|
movl $0xb8500,%edi
|
||||||
|
|
||||||
movl StringRflags, %esi
|
movl $StringRflags, %esi
|
||||||
call PrintString
|
call PrintString
|
||||||
.byte 0x48
|
.byte 0x48
|
||||||
movl 20*8(%ebp),%eax
|
movl 20*8(%ebp),%eax
|
||||||
@ -1152,7 +1153,7 @@ InnerLoop:
|
|||||||
movl (%esi),%eax
|
movl (%esi),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
addl $8,%esi
|
addl $8,%esi
|
||||||
mov $0x00, %al
|
movb $0x20, %al # blank character
|
||||||
movb %al,(%edi)
|
movb %al,(%edi)
|
||||||
addl $2,%edi
|
addl $2,%edi
|
||||||
loop InnerLoop
|
loop InnerLoop
|
||||||
@ -1183,7 +1184,7 @@ InnerLoop1:
|
|||||||
movl (%esi),%eax
|
movl (%esi),%eax
|
||||||
call PrintQword
|
call PrintQword
|
||||||
addl $8,%esi
|
addl $8,%esi
|
||||||
movb $0x00, %al
|
movb $0x20, %al # blank character
|
||||||
movb %al,(%edi)
|
movb %al,(%edi)
|
||||||
addl $2,%edi
|
addl $2,%edi
|
||||||
loop InnerLoop1
|
loop InnerLoop1
|
||||||
@ -1299,7 +1300,7 @@ ClearScreen:
|
|||||||
pushl %eax
|
pushl %eax
|
||||||
pushl %ecx
|
pushl %ecx
|
||||||
|
|
||||||
movb $0x00, %al
|
movb $0x20, %al # blank character
|
||||||
movb $0xc,%ah
|
movb $0xc,%ah
|
||||||
movl $0xb8000,%edi
|
movl $0xb8000,%edi
|
||||||
movl $80*24,%ecx
|
movl $80*24,%ecx
|
||||||
@ -1347,11 +1348,11 @@ Int18String: .asciz "12h Machine check -"
|
|||||||
Int19String: .asciz "13h SIMD Floating-Point Exception -"
|
Int19String: .asciz "13h SIMD Floating-Point Exception -"
|
||||||
IntUnknownString: .asciz "??h Unknown interrupt -"
|
IntUnknownString: .asciz "??h Unknown interrupt -"
|
||||||
|
|
||||||
StringTable: .long Int0String, Int1String, Int2String, Int3String, \
|
StringTable: .long Int0String, 0, Int1String, 0, Int2String, 0, Int3String, 0, \
|
||||||
Int4String, Int5String, Int6String, Int7String, \
|
Int4String, 0, Int5String, 0, Int6String, 0, Int7String, 0, \
|
||||||
Int8String, Int9String, Int10String, Int11String, \
|
Int8String, 0, Int9String, 0, Int10String, 0, Int11String, 0, \
|
||||||
Int12String, Int13String, Int14String, Int15String,\
|
Int12String, 0, Int13String, 0, Int14String, 0, Int15String, 0, \
|
||||||
Int16String, Int17String, Int18String, Int19String
|
Int16String, 0, Int17String, 0, Int18String, 0, Int19String, 0
|
||||||
|
|
||||||
String2: .asciz " HALT!! *** ("
|
String2: .asciz " HALT!! *** ("
|
||||||
String3: .asciz ")"
|
String3: .asciz ")"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
#*
|
#*
|
||||||
#* Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
|
#* Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||||
#* This program and the accompanying materials
|
#* This program and the accompanying materials
|
||||||
#* are licensed and made available under the terms and conditions of the BSD License
|
#* are licensed and made available under the terms and conditions of the BSD License
|
||||||
#* which accompanies this distribution. The full text of the license may be found at
|
#* which accompanies this distribution. The full text of the license may be found at
|
||||||
@ -311,11 +311,11 @@ Halt:
|
|||||||
ErrorString:
|
ErrorString:
|
||||||
.byte 'S', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c, '!', 0x0c
|
.byte 'S', 0x0c, 'E', 0x0c, 'r', 0x0c, 'r', 0x0c, 'o', 0x0c, 'r', 0x0c, '!', 0x0c
|
||||||
|
|
||||||
# .org 0x01fa # Will cause build break
|
.org 0x01fa
|
||||||
LBAOffsetForBootSector:
|
LBAOffsetForBootSector:
|
||||||
.long 0x0
|
.long 0x0
|
||||||
|
|
||||||
# .org 0x01fe # Will cause build break
|
.org 0x01fe
|
||||||
.word 0xaa55
|
.word 0xaa55
|
||||||
|
|
||||||
#******************************************************************************
|
#******************************************************************************
|
||||||
@ -328,7 +328,7 @@ LBAOffsetForBootSector:
|
|||||||
.equ WRITE_DATA_PORT_CMD, 0x0d1 # 8042 command to write the data port
|
.equ WRITE_DATA_PORT_CMD, 0x0d1 # 8042 command to write the data port
|
||||||
.equ ENABLE_A20_CMD, 0x0df # 8042 command to enable A20
|
.equ ENABLE_A20_CMD, 0x0df # 8042 command to enable A20
|
||||||
|
|
||||||
# .org 0x200 # Will cause build break
|
.org 0x200
|
||||||
jmp start
|
jmp start
|
||||||
Em64String:
|
Em64String:
|
||||||
.byte 'E', 0x0c, 'm', 0x0c, '6', 0x0c, '4', 0x0c, 'T', 0x0c, ' ', 0x0c, 'U', 0x0c, 'n', 0x0c, 's', 0x0c, 'u', 0x0c, 'p', 0x0c, 'p', 0x0c, 'o', 0x0c, 'r', 0x0c, 't', 0x0c, 'e', 0x0c, 'd', 0x0c, '!', 0x0c
|
.byte 'E', 0x0c, 'm', 0x0c, '6', 0x0c, '4', 0x0c, 'T', 0x0c, ' ', 0x0c, 'U', 0x0c, 'n', 0x0c, 's', 0x0c, 'u', 0x0c, 'p', 0x0c, 'p', 0x0c, 'o', 0x0c, 'r', 0x0c, 't', 0x0c, 'e', 0x0c, 'd', 0x0c, '!', 0x0c
|
||||||
|
Loading…
x
Reference in New Issue
Block a user