diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2010-03-15 19:58:55 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2010-03-15 19:58:55 -0400 |
commit | c35e1e50c389c6d63227e7f8d922cbcf4dea68aa (patch) | |
tree | 3b2e3bd7a6814184671de1d13c4fb10faa67a6e7 /src/system.c | |
parent | 11cc662d04f29b9639f222efc9cc51bbfa2ff737 (diff) | |
download | seabios-hppa-c35e1e50c389c6d63227e7f8d922cbcf4dea68aa.zip seabios-hppa-c35e1e50c389c6d63227e7f8d922cbcf4dea68aa.tar.gz seabios-hppa-c35e1e50c389c6d63227e7f8d922cbcf4dea68aa.tar.bz2 |
Restore segment limits in handle_1589 code.
Before transitioning back to real mode, the segment registers should
be reloaded so that the hidden register limits are updated.
Diffstat (limited to 'src/system.c')
-rw-r--r-- | src/system.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/system.c b/src/system.c index f3031af..898c3cc 100644 --- a/src/system.c +++ b/src/system.c @@ -143,6 +143,11 @@ handle_1587(struct bregs *regs) " xorw %%di, %%di\n" " rep movsw\n" + // Restore DS and ES segment limits to 0xffff + " movw $(5<<3), %%ax\n" // 5th descriptor in table (SS) + " movw %%ax, %%ds\n" + " movw %%ax, %%es\n" + // Disable protected mode " movl %%cr0, %%eax\n" " andl $~" __stringify(CR0_PE) ", %%eax\n" |