diff options
author | Jens Axboe <axboe@kernel.dk> | 2023-12-04 10:47:50 -0700 |
---|---|---|
committer | Christian Brauner <brauner@kernel.org> | 2023-12-05 11:57:37 +0100 |
commit | 9fd7874c0e5c89d7da0b4442271696ec0f8edcba (patch) | |
tree | 02f05ac2574b38dcc3b39a942c34c0d4b04c29f7 /drivers/char | |
parent | 6ac805d13870925c787a28e3fe5cc73610cacd03 (diff) |
iov_iter: replace import_single_range() with import_ubuf()
With the removal of the 'iov' argument to import_single_range(), the two
functions are now fully identical. Convert the import_single_range()
callers to import_ubuf(), and remove the former fully.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Link: https://lore.kernel.org/r/20231204174827.1258875-3-axboe@kernel.dk
Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/random.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/random.c b/drivers/char/random.c index e79ae238b30d..456be28ba67c 100644 --- a/drivers/char/random.c +++ b/drivers/char/random.c @@ -1384,7 +1384,7 @@ SYSCALL_DEFINE3(getrandom, char __user *, ubuf, size_t, len, unsigned int, flags return ret; } - ret = import_single_range(ITER_DEST, ubuf, len, &iter); + ret = import_ubuf(ITER_DEST, ubuf, len, &iter); if (unlikely(ret)) return ret; return get_random_bytes_user(&iter); @@ -1501,7 +1501,7 @@ static long random_ioctl(struct file *f, unsigned int cmd, unsigned long arg) return -EINVAL; if (get_user(len, p++)) return -EFAULT; - ret = import_single_range(ITER_SOURCE, p, len, &iter); + ret = import_ubuf(ITER_SOURCE, p, len, &iter); if (unlikely(ret)) return ret; ret = write_pool_user(&iter); |