Skip to content

Conversation

@sktt
Copy link
Contributor

@sktt sktt commented Aug 29, 2023

Going into real mode would crash on the wrmsr that clears the EFER_LME flag. This happened because paging was still enabled. And before disabling paging, we must also set the %ds.

@sktt sktt requested a review from a team as a code owner August 29, 2023 09:27
wipawel
wipawel previously approved these changes Aug 29, 2023
sktt added 3 commits August 29, 2023 15:41
Going into real mode would crash when clearing EFER_LME, i.e., when
transitioning from long to protected mode. This happened because paging
was still enabled. Before disabling paging, we must also set the %ds.

Signed-off-by: Johannes Wikner <[email protected]>
In protected mode, like in head.S, we want to be able to save all
registers. {SAVE,RESTORE}_ALL_REGS32 should therefore always be working
on 32-bit registers and not be build-dependent.

Signed-off-by: Johannes Wikner <[email protected]>
Copy link
Contributor

@minipli-oss minipli-oss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@wipawel wipawel merged commit a5a2a96 into KernelTestFramework:mainline Aug 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants