When rebooting (exiting) from the BTX loader, make sure to restore the
GDT from the correct segment, otherwise a triple fault would be caused. In some virtual environments (VMware, VirtualBox, etc) this could lead to a unhandled error or hang in the guest emulation software. Thanks to avg and jhb for a few hints in the right direction. Noticed by: Jeremy Chadwick <jdc@koitsu.org> (and many others) MFC after: 1 week
This commit is contained in:
parent
ffae621edd
commit
dbfc29017c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=249846
@ -248,7 +248,7 @@ exit: cli # Disable interrupts
|
||||
/*
|
||||
* Restore the GDT in case we caught a kernel trap.
|
||||
*/
|
||||
lgdt gdtdesc # Set GDT
|
||||
lgdt %cs:gdtdesc # Set GDT
|
||||
/*
|
||||
* To 16 bits.
|
||||
*/
|
||||
|
@ -248,7 +248,7 @@ exit: cli # Disable interrupts
|
||||
/*
|
||||
* Restore the GDT in case we caught a kernel trap.
|
||||
*/
|
||||
lgdt gdtdesc # Set GDT
|
||||
lgdt %cs:gdtdesc # Set GDT
|
||||
/*
|
||||
* To 16 bits.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user