diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2021-04-27 19:33:24 +0300 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2021-06-10 18:45:22 +0300 |
commit | 55ca375c5dcc7aebd89de42f00ff18f5c40d25f3 (patch) | |
tree | b4fd73d7f8c70139cc5a01295927952d8dc87d40 /lib/iov_iter.c | |
parent | c1d4d6a9ae88b87262fb5426823930bc471f6034 (diff) | |
download | linux-55ca375c5dcc7aebd89de42f00ff18f5c40d25f3.tar.xz |
copy_page_from_iter(): don't need kmap_atomic() for kvec/bvec cases
kmap_local_page() is enough.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'lib/iov_iter.c')
-rw-r--r-- | lib/iov_iter.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/iov_iter.c b/lib/iov_iter.c index 8aff4eb4fdfd..ba7eb6557750 100644 --- a/lib/iov_iter.c +++ b/lib/iov_iter.c @@ -871,9 +871,9 @@ size_t copy_page_from_iter(struct page *page, size_t offset, size_t bytes, if (likely(iter_is_iovec(i))) return copy_page_from_iter_iovec(page, offset, bytes, i); if (iov_iter_is_bvec(i) || iov_iter_is_kvec(i) || iov_iter_is_xarray(i)) { - void *kaddr = kmap_atomic(page); + void *kaddr = kmap_local_page(page); size_t wanted = _copy_from_iter(kaddr + offset, bytes, i); - kunmap_atomic(kaddr); + kunmap_local(kaddr); return wanted; } WARN_ON(1); |