Re: [PATCH 4.19 117/118] ovl: support stacked SEEK_HOLE/SEEK_DATA

From: Pavel Machek
Date: Sun Jun 16 2019 - 16:04:21 EST


Hi!

> ---
> fs/overlayfs/file.c | 44 ++++++++++++++++++++++++++++++++++++++++----
> 1 file changed, 40 insertions(+), 4 deletions(-)
>
> --- a/fs/overlayfs/file.c
> +++ b/fs/overlayfs/file.c
> @@ -146,11 +146,47 @@ static int ovl_release(struct inode *ino
>
> static loff_t ovl_llseek(struct file *file, loff_t offset, int whence)
> {
> - struct inode *realinode = ovl_inode_real(file_inode(file));
> + struct inode *inode = file_inode(file);
> + struct fd real;
> + const struct cred *old_cred;
> + ssize_t ret;
>
> - return generic_file_llseek_size(file, offset, whence,
> - realinode->i_sb->s_maxbytes,
> - i_size_read(realinode));
> + /*
> + * The two special cases below do not need to involve real fs,
> + * so we can optimizing concurrent callers.
> + */

AFAICT correct english is "optimize".

Thanks,
Pavel

--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

Attachment: signature.asc
Description: Digital signature