Re: [PATCH v2 2/2] io_uring: add support for ftruncate

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

 



On 1/23/24 4:33 AM, Tony Solomonik wrote:
> +int io_ftruncate_prep(struct io_kiocb *req, const struct io_uring_sqe *sqe)
> +{
> +	struct io_ftrunc *ft = io_kiocb_to_cmd(req, struct io_ftrunc);
> +
> +	if (sqe->addr || sqe->rw_flags || sqe->buf_index || sqe->splice_fd_in)
> +		return -EINVAL;

Since you're not using len anymore, that should be included in these
checks, and addr3.

-- 
Jens Axboe





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux