lkml.org 
[lkml]   [2022]   [Jan]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v4 40/68] cachefiles: Implement cache registration and withdrawal
Date
Jeff Layton <jlayton@kernel.org> wrote:

> > + /* check parameters */
> > + ret = -EOPNOTSUPP;
> > + if (d_is_negative(root) ||
> > + !d_backing_inode(root)->i_op->lookup ||
> > + !d_backing_inode(root)->i_op->mkdir ||
> > + !(d_backing_inode(root)->i_opflags & IOP_XATTR) ||
> > + !root->d_sb->s_op->statfs ||
> > + !root->d_sb->s_op->sync_fs ||
> > + root->d_sb->s_blocksize > PAGE_SIZE)
> > + goto error_unsupported;
> > +
>
> That's quite a collection of tests.
>
> Most are obvious, but some comments explaining the need for others would
> not be a bad thing. In particular, why is s_blocksize > PAGE_SIZE
> unsupported?

It can't do page-sized DIO requests to a filesystem with a block size larger
than a page. In the future I can work around that in conjunction with
netfslib by expanding read and write sizes.

> Also, should you vet whether the fs supports i_op->tmpfile here ?

That's a good idea.

David

\
 
 \ /
  Last update: 2022-01-06 18:45    [W:0.564 / U:0.288 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site