Re: [PATCH v1 02/11] mm: convert track_pfn_insert() to pfnmap_sanitize_pgprot()

From: David Hildenbrand
Date: Fri Apr 25 2025 - 15:56:52 EST


- track_pfn_insert(vma, &pgprot, pfn);
+ if (pfnmap_sanitize_pgprot(pfn_t_to_pfn(pfn), PAGE_SIZE, &pgprot))
+ return VM_FAULT_FALLBACK;

Would "pgtable" leak if it fails? If it's PAGE_SIZE, IIUC it won't ever
trigger, though.

Missed that comment. I can document that pgprot will only be touched if the function succeeds.

--
Cheers,

David / dhildenb