was boot a simple "Hello World" message

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am not sure you received this mail. I had problems with my email client.


-------------------------------------------------------------------------------------------------------------


I wrote 10 simple examples.
To build them:

make bootsect (to build the bootsector)
make disk (to write it on the floppy)

Basically these are simplified versions of bootsector.S of Linus Torvalds built setp by step from scratch (using the original code). This is useful because the people see how the things works step by step.

here a brief description

example1 -> create a simple bootdisk that print "Hello World"
example2 -> same of example1 only use direct access to videoram instead of int 0x10
example3 -> add to the preovious examples a routine to dump the registers (useful for
debugging)
example4 -> first step of the boot process. Copy bootsector from 0x7c00:0 to 0x9000:0
move the program count there and print "Hello World" again
example5 -> add kill motor
example6 -> load the setup code using int 0x13
example7 -> this example can be discarded at the beginning since the code added is necessary
to make bootable also 1.2Mb and 720Kb disks. For newbies this can be
discarded and use hardcoded 18 sectors. Infact the code has been remove in
example8.
example8 -> hardcoded version of exampe7
example9 -> print "Loading system ..." befor the loading head.S
example10 -> introduction of head.S and jump from bootsector.S to head.S


I am working now on example11 and the read_it routine (for me it is complicated, because I am not an assembler expert) I understand what it does but some instructions are not clear.
It it in coding phase.


Now step by step I want understand the code inside head.S and setup.S and pass the control to a my c program.

There is also example100 where I am trying to boot a simple main.c using a bootload like lilo. But I do not understand well how it works.

Attached the tar gz of my code.

Ah, to test the code it is necessary make a reboot of the machine and start from the floppy.
To avoid this I use bochs (a virtual machine).




--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux