Page MenuHomeFreeBSD

amd64: move gdt into pcpu
ClosedPublic

Authored by kib on Nov 10 2019, 10:56 AM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 20 2023, 1:08 AM
Unknown Object (File)
Dec 12 2023, 2:36 PM
Unknown Object (File)
Nov 25 2023, 12:09 AM
Unknown Object (File)
Nov 11 2023, 1:41 AM
Unknown Object (File)
Nov 4 2023, 8:01 PM
Unknown Object (File)
Oct 23 2023, 11:10 PM
Unknown Object (File)
Oct 21 2023, 8:32 AM
Unknown Object (File)
Oct 10 2023, 12:39 AM

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

sys/amd64/amd64/pmap.c
1782 ↗(On Diff #64144)

Why does GSBASE need to be set again?

sys/amd64/amd64/pmap.c
1782 ↗(On Diff #64144)

Because lgdt() != LGDT, it reloads %gs. I could have used bare_lgdt(), but think that we better reload there segment cache as well, actually.

Just an update: I'm at test number 534 out of 677 with an uptime of 20 hours (tests are sorted by increasing run time).
No problems so far.

I wish one could use PCPU_GET(gdt) instead of *PCPU_PTR(gdt) to look more readable, but I understand why we can't do that.

I ran the full stress2 test using 64144. No problems seen.

This revision was not accepted when it landed; it landed in state Needs Review.Nov 12 2019, 3:47 PM
This revision was automatically updated to reflect the committed changes.
This revision was not accepted when it landed; it landed in state Needs Review.Nov 12 2019, 3:51 PM
Closed by commit rS354646: amd64: move GDT into PCPU area. (authored by kib). · Explain Why
This revision was automatically updated to reflect the committed changes.