Re: [PATCH v11 00/21] Add support for NV-DIMMs to ext4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 01 Oct 2014 11:45:47 -0400, Jeff Moyer said:

> This sounds an awful lot like posix_fadvise' POSIX_FADV_NOREUSE flag.

Gaah. Premature click.  man posix_fadvise says this:

       In kernels before 2.6.18, POSIX_FADV_NOREUSE had the same semantics  as
       POSIX_FADV_WILLNEED.   This  was  probably  a bug; since kernel 2.6.18,
       this flag is a no-op.

and mm/fadvise.c says this:
        switch (advice) {
        case POSIX_FADV_NORMAL:
                f.file->f_ra.ra_pages = bdi->ra_pages;
                spin_lock(&f.file->f_lock);
                f.file->f_mode &= ~FMODE_RANDOM;
                spin_unlock(&f.file->f_lock);
...
	                 */
                force_page_cache_readahead(mapping, f.file, start_index,
                                           nrpages);
                break;
        case POSIX_FADV_NOREUSE:
                break;
        case POSIX_FADV_DONTNEED:
                if (!bdi_write_congested(mapping->backing_dev_info))
                        __filemap_fdatawrite_range(mapping, offset, endbyte,
                                                   WB_SYNC_NONE);

                /* First and last FULL page! */

So... not much interface there, actually.  One wonders if removing the 'break;'
and allowing a fall-through would actually be an improvement....

Attachment: pgp1md1GG2QSn.pgp
Description: PGP signature


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux