RE: [PATCH 03/13] fs: Restore kiocb.ki_hint

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

 



 
> Restore support for passing write hint information from a filesystem to the
> block layer. Write hint information can be set via fcntl(fd, F_SET_RW_HINT,
> &hint). This patch reverts commit 41d36a9f3e53 ("fs: remove kiocb.ki_hint").
> 
> Cc: Christoph Hellwig <hch@xxxxxx>
> Cc: Dave Chinner <dchinner@xxxxxxxxxx>
> Signed-off-by: Bart Van Assche <bvanassche@xxxxxxx>

.....

> diff --git a/io_uring/rw.c b/io_uring/rw.c
> index c8c822fa7980..c41ae6654116 100644
> --- a/io_uring/rw.c
> +++ b/io_uring/rw.c
> @@ -677,6 +677,7 @@ static int io_rw_init_file(struct io_kiocb *req,
> fmode_t mode)
>                 req->flags |= io_file_get_flags(file);
> 
>         kiocb->ki_flags = file->f_iocb_flags;
> +       kiocb->ki_hint = file_inode(file)->i_write_hint;
Originally ki_hint_validate() was used here as well?

Thanks,
Avri

>         ret = kiocb_set_rw_flags(kiocb, rw->flags);
>         if (unlikely(ret))
>                 return ret;




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

  Powered by Linux