OSDev.org

The Place to Start for Operating System Developers
It is currently Fri Apr 19, 2024 12:02 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: What is the best, proper way to pass informations to the OS?
PostPosted: Fri Feb 27, 2015 3:53 pm 
Offline

Joined: Fri Dec 26, 2014 3:28 pm
Posts: 5
And what do you think are the mandatory and recommended ones on a UEFI x64 platform?

_________________
I'm not a native English speaker, feel free to correct me.


Top
 Profile  
 
 Post subject: Re: What is the best, proper way to pass informations to the
PostPosted: Fri Feb 27, 2015 7:10 pm 
Offline
Member
Member

Joined: Mon Apr 09, 2007 12:10 pm
Posts: 775
Location: London, UK
There is no official 'proper' way to pass information from a UEFI bootloader to the OS. You'd usually want to use a structure in memory and pass its address as an argument to your kernel main function. Your structure could follow the multiboot format if you like (then your kernel could be booted unmodified from multiboot-compliant loaders too) or could be of your own design.

Things you would definitely want to include:
- a memory map
- locations of modules (if any)
- framebuffer properties (if you don't immediately start using a native graphics driver in your OS)
- some sort of flag to identify this as a UEFI system (and therefore legacy devices and the BIOS may not be available)

Optional things:
- ACPI/SMBIOS/PXE table locations (UEFI provides these so you don't need to search for them and in addition the ACPI spec only guarantees their locations in low memory/EBDA for PC-BIOS systems anyway)
- UEFI path of the device containing the bootloader image
- Current system time (before you synchronize with NTP etc)

Regards,
John.

_________________
Tysos | rpi-boot


Top
 Profile  
 
 Post subject: Re: What is the best, proper way to pass informations to the
PostPosted: Sun Mar 01, 2015 12:17 pm 
Offline

Joined: Fri Dec 26, 2014 3:28 pm
Posts: 5
Thank you jnc, always the first one to reply when we ask UEFI-related questions!

_________________
I'm not a native English speaker, feel free to correct me.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 34 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group