angods wrote:Sorry, I'm new to the forum and I thought I did something wrong when my previous post didn't show up after clicking "View your posts".
New users need Moderator approval before their posts are globally visible. The reason being that we had (have?) a bit of a spam problem, and this is one way around it.
angods wrote:So the CS really uses the "hidden pointer" as it's base. And when I jump it replaces the pointer with GDT[SegmentOffset].Base?
Yes. This applies more generally to all segments: Their hidden parts are not updated until the descriptors are written, and when they are written, the contents of the segments are updated according to the operating mode in use at the time. This is one reason to overwrite all segments quickly after changing modes: The descriptors still read the same, so if your interrupt code pushes a segment to stack and then pops it back in (and this happens automatically for CS and SS), then the previous value might simply be invalid in the new mode. This is also a very fickle issue, so debugging it can be hard.
Not that that's a concern when switching to protected mode for the first time, since you still need to load a new IDT, and will likely only do that when the segments were reloaded.