Re: [PATCH 06/12] huge_memory: Allow mappings of PUD sized pages

2024-09-21 Thread Dan Williams
Alistair Popple wrote: > Currently DAX folio/page reference counts are managed differently to > normal pages. To allow these to be managed the same as normal pages > introduce dax_insert_pfn_pud. This will map the entire PUD-sized folio > and take references as it would for a normally mapped page.

Re: [PATCH 05/12] mm/memory: Add dax_insert_pfn

2024-09-21 Thread Dan Williams
[ add s390 folks to comment on CONFIG_FS_DAX_LIMITED ] Alistair Popple wrote: > Currently to map a DAX page the DAX driver calls vmf_insert_pfn. This > creates a special devmap PTE entry for the pfn but does not take a > reference on the underlying struct page for the mapping. This is > because DA

Re: [PATCH 04/12] mm: Allow compound zone device pages

2024-09-21 Thread Dan Williams
Alistair Popple wrote: > Zone device pages are used to represent various type of device memory > managed by device drivers. Currently compound zone device pages are > not supported. This is because MEMORY_DEVICE_FS_DAX pages are the only > user of higher order zone device pages and have their own p

Re: [PATCH 03/12] fs/dax: Refactor wait for dax idle page

2024-09-21 Thread Dan Williams
Alistair Popple wrote: > A FS DAX page is considered idle when its refcount drops to one. This > is currently open-coded in all file systems supporting FS DAX. Move > the idle detection to a common function to make future changes easier. > > Signed-off-by: Alistair Popple > Reviewed-by: Jan Kara

Re: [PATCH 02/12] pci/p2pdma: Don't initialise page refcount to one

2024-09-21 Thread Dan Williams
Alistair Popple wrote: > The reference counts for ZONE_DEVICE private pages should be > initialised by the driver when the page is actually allocated by the > driver allocator, not when they are first created. This is currently > the case for MEMORY_DEVICE_PRIVATE and MEMORY_DEVICE_COHERENT pages >

Re: [PATCH 01/12] mm/gup.c: Remove redundant check for PCI P2PDMA page

2024-09-21 Thread Dan Williams
Alistair Popple wrote: > PCI P2PDMA pages are not mapped with pXX_devmap PTEs therefore the > check in __gup_device_huge() is redundant. Remove it > > Signed-off-by: Alistair Popple > Reviewed-by: Jason Gunthorpe > Acked-by: David Hildenbrand > --- > mm/gup.c | 5 - > 1 file changed, 5 del