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;




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux