On Tue, 18 Feb 2025 23:17:29 +0200 Gwan-gyeong Mun gwan-gyeong.mun@intel.com wrote:
That actually mirrors how __kernel_physical_mapping_init() does it: watch for an actual PGD write and sync there. It shouldn't be too slow because it only calls sync_global_pgds() during actual PGD population which is horribly rare.
Could we do something like that, please? It might mean defining a new __weak symbol in mm/sparse-vmemmap.c and then calling out to an x86 implementation like vmemmap_set_pmd().
Hi Dave Hansen,
Thanks for the feedback. I do agree with a generic code rather than a diverse code for x86 implementation. If everyone else agrees, I'll send a new patch in this style.
Please do.
I'll drop this version of the patch, thanks.