Re: [PATCH v3 0/8] Support for transparent PUD pages for DAX files
From: Dave Chinner
Date: Fri Jan 22 2016 - 06:26:36 EST
On Fri, Jan 15, 2016 at 11:41:50AM -0800, Darrick J. Wong wrote:
> On Fri, Jan 08, 2016 at 02:49:44PM -0500, Matthew Wilcox wrote:
> > From: Matthew Wilcox <willy@xxxxxxxxxxxxxxx>
> >
> > Andrew, I think this is ready for a spin in -mm.
> >
> > v3: Rebased against current mmtom
> > v2: Reduced churn in filesystems by switching to ->huge_fault interface
> > Addressed concerns from Kirill
> >
> > We have customer demand to use 1GB pages to map DAX files. Unlike the 2MB
> > page support, the Linux MM does not currently support PUD pages, so I have
> > attempted to add support for the necessary pieces for DAX huge PUD pages.
> >
> > Filesystems still need work to allocate 1GB pages. With ext4, I can
> > only get 16MB of contiguous space, although it is aligned. With XFS,
> > I can get 80MB less than 1GB, and it's not aligned. The XFS problem
> > may be due to the small amount of RAM in my test machine.
>
> "It's not aligned"... I don't know the details of what you're trying to do, but
> are you trying to create a file where each GB of logical address space maps to
> a contiguous GB of physical space, and both logical and physical offsets align
> to a 1GB boundary?
>
> If the XFS is formatted with stripe unit/width of 1G, an extent size hint of 1G
> is put on the file, and the whole file is allocated in 1G chunks, I think
> you're supposed to be able to make the above happen:
If you really, really want to guarantee 1GB aligned extents for file
data on XFS, use the realtime device with a 1GB extent size.....
Cheers,
Dave.
--
Dave Chinner
david@xxxxxxxxxxxxx