Re: [PATCH] Add IORING_FEAT_FILES_SKIP feature flag

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

 



On Thu May 20, 2021 at 6:54 PM EDT, Pavel Begunkov wrote:
> On 5/20/21 10:55 PM, Drew DeVault wrote:
> > On Thu May 20, 2021 at 9:32 AM EDT, Jens Axboe wrote:
> >>> diff --git a/src/include/liburing/io_uring.h b/src/include/liburing/io_uring.h
> >>> index 5a3cb90..091dcf7 100644
> >>> --- a/src/include/liburing/io_uring.h
> >>> +++ b/src/include/liburing/io_uring.h
> >>> @@ -285,6 +285,7 @@ struct io_uring_params {
> >>>  #define IORING_FEAT_SQPOLL_NONFIXED	(1U << 7)
> >>>  #define IORING_FEAT_EXT_ARG		(1U << 8)
> >>>  #define IORING_FEAT_NATIVE_WORKERS	(1U << 9)
> >>> +#define IORING_FEAT_FILES_SKIP		IORING_FEAT_NATIVE_WORKERS
> >>
> >> I don't think this is a great idea. It can be used as a "probably we
> >> have this feature" in userspace, but I don't like aliasing on the
> >> kernel side.
> > 
> > This patch is for liburing, following the feedback on the kernel patch
> > (which didn't alias, but regardless).
>
> This file is a copy (almost) of the kernel's uapi header, so better be
> off this file and have naming that wouldn't alias with names in this
> header.
>
> I think that's the problem Jens mean. Jens, is it? And I do still
> believe it's a better way to not have an itchy one release gap
> between actual feature introduction and new feat flag.

It does itch, but I don't think it's actually wrong, per-se. Unless we
expect features to be removed or optionally available, it might make
sense to have used an incrementing number rather than a bitfield.

What should userspace programs do if they're not sure if they can use
FILES_SKIP? What was the previous behavior if -2 is used? I'm guessing
it was EINVAL, EBADF, something like that.




[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