OSDev.org

The Place to Start for Operating System Developers
It is currently Thu Mar 28, 2024 10:00 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: a20 and modern hardware
PostPosted: Sat Jun 27, 2015 11:28 pm 
Offline

Joined: Sat Jun 27, 2015 11:05 pm
Posts: 2
Hi all,

Is A20 gating still actually a thing in modern desktop pcs? I remember reading somewhere that intel no longer support a20 gating in their processors, so do modern motherboards and chipsets still boot up with a20 disable? I understand its purpose was to maintain backward compatibility when IBM pcs added more than 1MB of memory, but I would have thought that was so far in the past now it is silly to support it. Maybe some systems will only do it if set to boot in 'legacy bios' rather than uefi, or I suppose virtual machines like virtualbox would emulate it because one of their purposes is to allow people to run legacy software. I really like the osdev wiki, I have just recently had an urge to start experimenting with writing an os as a hobby, but nearly all the info online is very very dated; maybe the topic had a burst of popularity a while ago now few people are interested?


Top
 Profile  
 
 Post subject: Re: a20 and modern hardware
PostPosted: Sat Jun 27, 2015 11:42 pm 
Offline
Member
Member
User avatar

Joined: Wed Dec 01, 2010 3:41 am
Posts: 1761
Location: Hong Kong
EFI systems boots with A20 enabled, and there is no standard way to disable it, it may not even support disabling.

And according to wiki:
Intel no longer supports the A20 gate starting with Haswell. Page 271 of the Intel System Programmers Manual Vol. 3A from June 2013 [3] states: "The functionality of A20M# is used primarily by older operating systems and not used by modern operating systems. On newer Intel 64 processors, A20M# may be absent."


Top
 Profile  
 
 Post subject: Re: a20 and modern hardware
PostPosted: Sun Jun 28, 2015 12:28 am 
Offline
Member
Member

Joined: Thu Jul 05, 2012 5:12 am
Posts: 923
Location: Finland
JF wrote:
I understand its purpose was to maintain backward compatibility when IBM pcs added more than 1MB of memory, but I would have thought that was so far in the past now it is silly to support it.


While we are at topic, I would like to re-share the link mikegonta posted in another topic just a while ago: Who needs the address wraparound anyway.

_________________
Undefined behavior since 2012


Top
 Profile  
 
 Post subject: Re: a20 and modern hardware
PostPosted: Sun Jun 28, 2015 2:33 am 
Offline

Joined: Sat Jun 27, 2015 11:05 pm
Posts: 2
So Im wondering, if I boot a less than 3 years old desktop pc in bios mode (not uefi), would a20 be disabled ? assuming intels chipset that does not support a20 gating anymore, it could not even be present in 'legacy bios' boot, am i correct?

Im just wondering because all the code examples and tutorials and wiki entries and homebrew oses and forums posts on the internet go on at length about it, but it seems like something that does not even exist any more (for newer hardware, not talking about older systems)? (although as I said, nearly all this material is very old, maybe it has just not caught up yet?)


Top
 Profile  
 
 Post subject: Re: a20 and modern hardware
PostPosted: Sun Jun 28, 2015 4:24 am 
Offline
Member
Member

Joined: Mon Mar 25, 2013 7:01 pm
Posts: 5099
JF wrote:
So Im wondering, if I boot a less than 3 years old desktop pc in bios mode (not uefi), would a20 be disabled ?

Probably not. As far as I know, most PCs in the past 5 years (including BIOS-only machines) boot with A20 enabled. All the machines I've tested agree with this.

If you're using a bootloader like GRUB, this is a non-issue: GRUB enables A20 for you. If you're writing your own bootloader, you need to check A20, although you could display an error message and halt instead of enabling A20.


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

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 27 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