Fixed errors in ARM linker. Converted all files to Unix format.

This commit is contained in:
2013-12-06 14:20:46 -05:00
parent 74035befbf
commit bf60ad29f4
8 changed files with 386 additions and 386 deletions

View File

@ -1,40 +1,40 @@
# Declare constants for creating a multiboot header
.set ALIGN, 1<<0
.set MEMINFO, 1<<1
.set FLAGS, ALIGN | MEMINFO
.set MAGIC, 0x1BADB002
.set CHECKSUM, -(MAGIC + FLAGS)
# Declare multiboot header
.section .multiboot
.align 4
.long MAGIC
.long FLAGS
.long CHECKSUM
# Create a 16 KiB stack
.section .bootstrap_stack
stack_bottom:
.skip 16384
stack_top:
# Kernel entry point
.section .text
.global _start
.type _start, @function
_start:
# We are now in kernel mode!
# Setup the stack
movl $stack_top, %esp
# Call the main kernel function
call brados_main
# In case the function returns, enter an endless loop
cli
hlt
.Lhang:
jmp .Lhang
# Set the size of the _start symbol for debugging
.size _start, . - _start
# Declare constants for creating a multiboot header
.set ALIGN, 1<<0
.set MEMINFO, 1<<1
.set FLAGS, ALIGN | MEMINFO
.set MAGIC, 0x1BADB002
.set CHECKSUM, -(MAGIC + FLAGS)
# Declare multiboot header
.section .multiboot
.align 4
.long MAGIC
.long FLAGS
.long CHECKSUM
# Create a 16 KiB stack
.section .bootstrap_stack
stack_bottom:
.skip 16384
stack_top:
# Kernel entry point
.section .text
.global _start
.type _start, @function
_start:
# We are now in kernel mode!
# Setup the stack
movl $stack_top, %esp
# Call the main kernel function
call brados_main
# In case the function returns, enter an endless loop
cli
hlt
.Lhang:
jmp .Lhang
# Set the size of the _start symbol for debugging
.size _start, . - _start

View File

@ -1,38 +1,38 @@
/* Kernel entry point */
ENTRY(_start)
/* Define the locations of the object file sections */
SECTIONS
{
/* Sections begin at 1 MiB */
. = 1M;
/* The multiboot header needs to come first, followed by program code */
.text BLOCK(4K) : ALIGN(4K)
{
*(.multiboot)
*(.text)
}
/* Read-only data */
.rodata BLOCK(4K) : ALIGN(4K)
{
*(.rodata)
}
/* Initialized read-write data */
.data BLOCK(4K) : ALIGN(4K)
{
*(.data)
}
/* Uninitialized read-write data and stack */
.bss BLOCK(4K) : ALIGN(4K)
{
*(COMMON)
*(.bss)
*(.bootstrap_stack)
}
/* Add other sections here */
}
/* Kernel entry point */
ENTRY(_start)
/* Define the locations of the object file sections */
SECTIONS
{
/* Sections begin at 1 MiB */
. = 1M;
/* The multiboot header needs to come first, followed by program code */
.text BLOCK(4K) : ALIGN(4K)
{
*(.multiboot)
*(.text)
}
/* Read-only data */
.rodata BLOCK(4K) : ALIGN(4K)
{
*(.rodata)
}
/* Initialized read-write data */
.data BLOCK(4K) : ALIGN(4K)
{
*(.data)
}
/* Uninitialized read-write data and stack */
.bss BLOCK(4K) : ALIGN(4K)
{
*(COMMON)
*(.bss)
*(.bootstrap_stack)
}
/* Add other sections here */
}