On Fri, Jul 18, 2025 at 01:06:30PM +0200, David Hildenbrand wrote: > On 18.07.25 12:47, Lorenzo Stoakes wrote: > > On Thu, Jul 17, 2025 at 10:14:33PM +0200, David Hildenbrand wrote: > > > On 17.07.25 22:03, Lorenzo Stoakes wrote: > > > > On Thu, Jul 17, 2025 at 01:52:11PM +0200, David Hildenbrand wrote: > > > > > Let's introduce vm_normal_page_pud(), which ends up being fairly > > > > > simple > > > > > because of our new common helpers and there not being a PUD-sized zero > > > > > folio. > > > > > > > > > > Use vm_normal_page_pud() in folio_walk_start() to resolve a TODO, > > > > > structuring the code like the other (pmd/pte) cases. Defer > > > > > introducing vm_normal_folio_pud() until really used. > > > > > > > > I mean fine :P but does anybody really use this? > > > > > > This is a unified PFN walker (!hugetlb + hugetlb), so you can easily run > > > into hugetlb PUDs, DAX PUDs and huge pfnmap (vfio) PUDs :) > > > > Ahhh ok. I hate hugetlb so very very much. > > > > Oscar is doing the Lord's work improving things but the trauma is still > > there... :P > > > > Also yeah DAX ahem. > > > > I'm not familiar with huge pfnmap PUDs, could you give me a hint on this? > > :>) > > vmf_insert_pfn_pmd(), called from drivers/vfio/pci/vfio_pci_core.c > > Essentially, we create huge PUDs when mapping device BARs to user space.
Ah makes sense. Thanks!