From 1595632297f12b3aa2f1adfdcd06ea47bf31486c Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Sat, 10 Jun 2017 09:30:59 +0200 Subject: rearranged boot loader: first load 3 sectors of stage 2 in simple int 13h read. then in stage 2 do a much better detection of disk geometries in the future (for now, it's the same) and load the kernel sectors with a more complex loading routine --- src/Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/Makefile') diff --git a/src/Makefile b/src/Makefile index 55f8975..3ec465d 100644 --- a/src/Makefile +++ b/src/Makefile @@ -13,7 +13,8 @@ all: image.bin kernel.sym # + M * 512 (M is currently 7) = 3144 for kernel.bin # + 1 * 512 = 512 for magic.bin # (M + N + 1 is the number of sectors to be read in stage 2, as stage 1 -# loads only the first sector, so adapt NOF_LOAD_SECTORS to 39) +# loads only the first sector, and stage 1 loads 3 sectors of stage 2, +# adapt NOF_LOAD_SECTORS to 36) # then we make sure the image has the size of a 1.44 MB floppy # (emulators like qemu do some guess work for CHS resolution based # on the size of the image) @@ -23,7 +24,7 @@ image.bin: boot.bin kernel.bin magic.bin cat image.tmp magic.bin > image.bin truncate -s 1474560 image.bin -boot.bin: boot.asm boot_gdt.asm stage1_functions.asm stage2_functions.asm stage2_switch_mode.asm stage2_a20.asm +boot.bin: boot.asm boot_gdt.asm stage1_functions.asm stage2_real_functions.asm stage2_pm_functions.asm stage2_switch_mode.asm stage2_a20.asm $(NASM) boot.asm -DMAGIC='"$(MAGIC)"' -f bin -o boot.bin kernel.bin: kernel.elf -- cgit v1.2.3-54-g00ecf