Re: mm: WARNING in __delete_from_page_cache

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

 



On Tue 26-01-16 07:54:56, Matthew Wilcox wrote:
> On Tue, Jan 26, 2016 at 03:42:34AM +0000, Williams, Dan J wrote:
> > @@ -2907,7 +2912,12 @@ extern void replace_mount_options(struct super_block *sb, char *options);
> >  
> >  static inline bool io_is_direct(struct file *filp)
> >  {
> > -	return (filp->f_flags & O_DIRECT) || IS_DAX(file_inode(filp));
> 
> I think this should just be a one-liner:
> 
> -	return (filp->f_flags & O_DIRECT) || IS_DAX(file_inode(filp));
> +	return (filp->f_flags & O_DIRECT) || IS_DAX(filp->f_mapping->host);
> 
> This does the right thing for block device inodes and filesystem inodes.
> (see the opening stanzas of __dax_fault for an example).

Ah, right. This looks indeed better.

								Honza
-- 
Jan Kara <jack@xxxxxxxx>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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