Messages in this thread | | | From | David Howells <> | Subject | Re: [PATCH v6 05/34] iov_iter: Change the direction macros into an enum | Date | Wed, 18 Jan 2023 23:24:50 +0000 |
| |
Al Viro <viro@zeniv.linux.org.uk> wrote:
> > Compile time type checking. > > Huh? int-to-enum conversion is quiet; it would catch explicit > huge constants, but that's it...
*shrug*.
But can we at least get rid of the:
iov_iter_foo(&iter, ITER_SOURCE, ...);
WARN_ON(direction & ~(READ | WRITE));
mismatch? Either use ITER_SOURCE/DEST or use READ/WRITE but not mix them.
David
| |