Click to See Complete Forum and Search --> : How to Switch into Protected Mode


pdp8
November 25th, 2008, 12:39 PM
I need to make modifications to BIOS code which runs at PowerUp or Boot time and I need to access more than the lower 1,048,576 bytes of memory.

Is it possible to switch into Protected Mode at this time in order to access more memory? If so, how? What is the instruction sequence?

Alternatively, can anyone suggest a different approach?


Thanks,
Bob.

iviggers
November 28th, 2008, 11:20 PM
Hi PDP8,
Haven't dealt with that recently or in depth, but in order to switch into PMode you need to disable interrupts (opcode cli), define the table of global/local descriptors, define interrupts table, change the Least Significant Bit of special register CL0 and enable interrupts (opcode sti).

Depending on your specific purpose and the logic intended you might not really need access to memory above the 1Mb. Would you provide more info?

Good luck.

Iņaki Viggers

pdp8
December 1st, 2008, 12:51 PM
All I need to do is read several bytes of data from the upper end of the 4GB address space, where an MD5 message digest of the bios will have been stored.

The intent is to compare the current MD5 with the pre-stored value to ensure that the BIOS has not been tampered with.