EPROM confusion
EPROM confusion
[quote="'Intel® 64 and IA-32 Architectures Software Developer's Manual Volume 3A: System Programming Guide'"]9.7.1 Real-Address Mode IDT
In real-address mode, the only system data structure that must be loaded into memory is the IDT (also called the “interrupt vector tableâ€
In real-address mode, the only system data structure that must be loaded into memory is the IDT (also called the “interrupt vector tableâ€
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
It describes that in real mode you need to set up an interrupt table (the "real mode IDT"/ IVT).
Furthermore, the interrupt handlers must be within the 1MB limit of real mode where the processor can access it, and that it can be located on any form of memory (either RAM or ROM).
What it does not say is that the code and hardware responsible for doing this is implemented in the PC BIOS. When the computer boots, it will create the IVT and will set all the pointers to the appropriate interrupt handlers. Since the bios is contained in ROM mapped to 0xf0000-0xfffff, it conforms to all the requirements the documentation states.
It also means that you do not have to worry about setting up the IVT or about (EP)ROM.
Common sense tells us not to write to the bios area, as things are stored there that are beyond the average human's comprehension which also happen to be required for the computer to work properly.
so for the bios rom, pros: nice area for showing off 1337 skills, cons: one mistake and your box is braindead.
You could add another rom chip into an x86 system, but that's a different subject and requires quite a bit more arcane knowledge to make it work.
Furthermore, the interrupt handlers must be within the 1MB limit of real mode where the processor can access it, and that it can be located on any form of memory (either RAM or ROM).
What it does not say is that the code and hardware responsible for doing this is implemented in the PC BIOS. When the computer boots, it will create the IVT and will set all the pointers to the appropriate interrupt handlers. Since the bios is contained in ROM mapped to 0xf0000-0xfffff, it conforms to all the requirements the documentation states.
It also means that you do not have to worry about setting up the IVT or about (EP)ROM.
Common sense tells us not to write to the bios area, as things are stored there that are beyond the average human's comprehension which also happen to be required for the computer to work properly.
so for the bios rom, pros: nice area for showing off 1337 skills, cons: one mistake and your box is braindead.
You could add another rom chip into an x86 system, but that's a different subject and requires quite a bit more arcane knowledge to make it work.
Thats more or less what i thought would be the answer, but better be on the safe side when trying to understand this rather complicated stuff.Combuster wrote:What it does not say is that the code and hardware responsible for doing this is implemented in the PC BIOS. When the computer boots, it will create the IVT and will set all the pointers to the appropriate interrupt handlers. Since the bios is contained in ROM mapped to 0xf0000-0xfffff, it conforms to all the requirements the documentation states.
It also means that you do not have to worry about setting up the IVT or about (EP)ROM.
Thanks
- Colonel Kernel
- Member
- Posts: 1437
- Joined: Tue Oct 17, 2006 6:06 pm
- Location: Vancouver, BC, Canada
- Contact:
- Brynet-Inc
- Member
- Posts: 2426
- Joined: Tue Oct 17, 2006 9:29 pm
- Libera.chat IRC: brynet
- Location: Canada
- Contact:
- Colonel Kernel
- Member
- Posts: 1437
- Joined: Tue Oct 17, 2006 6:06 pm
- Location: Vancouver, BC, Canada
- Contact:
- Colonel Kernel
- Member
- Posts: 1437
- Joined: Tue Oct 17, 2006 6:06 pm
- Location: Vancouver, BC, Canada
- Contact:
Ideas about design and theory, not questions about hardware and implementation details. Read some of the other posts in "OS Design & Theory" to get an idea.Zacariaz wrote:pardon me, but what should i post in "OS Design and Theory" then?Colonel Kernel wrote:This is "OS Design & Theory". Please post this type of question in "OS Development" next time.
An example of a good question for Design & Theory: "Should I use a microkernel or monolithic architecture for my OS?" An example of a bad question for Design & Theory: "How do I set up the page tables so that my kernel is mapped in the higher half?"
Does this help?
Top three reasons why my OS project died:
- Too much overtime at work
- Got married
- My brain got stuck in an infinite loop while trying to design the memory manager
I'm not seeing a specific answer to this question in the replies, so far, I don't think. So here's the answer as best I know.Zacariaz wrote: I any case, what would the pros and cons be to using EPROM as suggested?
The statement you quoted in the Intel manual is aimed at motherboard manufacturers, not programmers or OS developers. As an OS developer, the use of ROM is hidden from you. You cannot access it directly. You cannot do anything with it, if it is there. The BIOS is what gets stored in that ROM, and is usually "shadowed" into your computer's RAM at physical address 0xF0000 to 0xFFFFF. Your OS probably can't, and probably shouldn't (assuming it can) even turn the shadowing off.