Page MenuHomeFreeBSD

D39945.diff
No OneTemporary

D39945.diff

diff --git a/sys/amd64/amd64/mp_machdep.c b/sys/amd64/amd64/mp_machdep.c
--- a/sys/amd64/amd64/mp_machdep.c
+++ b/sys/amd64/amd64/mp_machdep.c
@@ -215,6 +215,8 @@
/* See comment in pmap_bootstrap(). */
pc->pc_pcid_next = PMAP_PCID_KERN + 2;
pc->pc_pcid_gen = 1;
+ pc->pc_kpmap_store.pm_pcid = PMAP_PCID_KERN;
+ pc->pc_kpmap_store.pm_gen = 1;
pc->pc_smp_tlb_gen = 1;
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
--- a/sys/amd64/amd64/pmap.c
+++ b/sys/amd64/amd64/pmap.c
@@ -2036,13 +2036,9 @@
if (pmap_pcid_enabled) {
kernel_pmap->pm_pcidp = (void *)(uintptr_t)
offsetof(struct pcpu, pc_kpmap_store);
- for (i = 0; i < MAXCPU; i++) {
- struct pmap_pcid *pcidp;
- pcidp = zpcpu_get_cpu(kernel_pmap->pm_pcidp, i);
- pcidp->pm_pcid = PMAP_PCID_KERN;
- pcidp->pm_gen = 1;
- }
+ PCPU_SET(kpmap_store.pm_pcid, PMAP_PCID_KERN);
+ PCPU_SET(kpmap_store.pm_gen, 1);
/*
* PMAP_PCID_KERN + 1 is used for initialization of

File Metadata

Mime Type
text/plain
Expires
Sun, Jan 12, 3:53 AM (20 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15760858
Default Alt Text
D39945.diff (973 B)

Event Timeline