mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
amd64 pmap.h: make it easier to use the header for other consumers
Guard pmap_invlpg() definition with checks that only provide it when both sys/pcpu.h and machine/cpufunc.h were already included. Requested by: Elliott Mitchell Sponsored by: The FreeBSD Foundation MFC after: 1 week
This commit is contained in:
parent
a2c08eba43
commit
ad97b9bbfc
1 changed files with 2 additions and 0 deletions
|
|
@ -516,6 +516,7 @@ pmap_invalidate_cpu_mask(pmap_t pmap)
|
|||
return (&pmap->pm_active);
|
||||
}
|
||||
|
||||
#if defined(_SYS_PCPU_H_) && defined(_MACHINE_CPUFUNC_H_)
|
||||
/*
|
||||
* It seems that AlderLake+ small cores have some microarchitectural
|
||||
* bug, which results in the INVLPG instruction failing to flush all
|
||||
|
|
@ -533,6 +534,7 @@ pmap_invlpg(pmap_t pmap, vm_offset_t va)
|
|||
invlpg(va);
|
||||
}
|
||||
}
|
||||
#endif /* sys/pcpu.h && machine/cpufunc.h */
|
||||
|
||||
#endif /* _KERNEL */
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue