diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2022-09-16 03:25:47 +0300 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2022-11-25 21:01:55 +0300 |
commit | de4eda9de2d957ef2d6a8365a01e26a435e958cb (patch) | |
tree | 49b0d60dedb65af7f0d3e874ee9c661e6b09697b /drivers/net/ppp | |
parent | a41dad905e5a388f88435a517de102e9b2c8e43d (diff) | |
download | linux-de4eda9de2d957ef2d6a8365a01e26a435e958cb.tar.xz |
use less confusing names for iov_iter direction initializers
READ/WRITE proved to be actively confusing - the meanings are
"data destination, as used with read(2)" and "data source, as
used with write(2)", but people keep interpreting those as
"we read data from it" and "we write data to it", i.e. exactly
the wrong way.
Call them ITER_DEST and ITER_SOURCE - at least that is harder
to misinterpret...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/net/ppp')
-rw-r--r-- | drivers/net/ppp/ppp_generic.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ppp/ppp_generic.c b/drivers/net/ppp/ppp_generic.c index 9206c660a72e..be2fab0469cf 100644 --- a/drivers/net/ppp/ppp_generic.c +++ b/drivers/net/ppp/ppp_generic.c @@ -480,7 +480,7 @@ static ssize_t ppp_read(struct file *file, char __user *buf, ret = -EFAULT; iov.iov_base = buf; iov.iov_len = count; - iov_iter_init(&to, READ, &iov, 1, count); + iov_iter_init(&to, ITER_DEST, &iov, 1, count); if (skb_copy_datagram_iter(skb, 0, &to, skb->len)) goto outf; ret = skb->len; |