diff options
author | Christoph Hellwig <hch@lst.de> | 2020-06-08 07:42:43 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-06-08 21:05:58 +0300 |
commit | bce2b68b891af3dd02fdc1603786c1c28db8bfad (patch) | |
tree | dc6e05e7bf8ad289ac4211b51bbf96f05faa8b4d | |
parent | 48304f7994d74ef8fddde3ff27ce41aa61453d39 (diff) | |
download | linux-bce2b68b891af3dd02fdc1603786c1c28db8bfad.tar.xz |
exec: use flush_icache_user_range in read_code
read_code operates on user addresses.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Link: http://lkml.kernel.org/r/20200515143646.3857579-27-hch@lst.de
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | fs/exec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/exec.c b/fs/exec.c index 88260ec0ac34..02d0c5d19be5 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -1059,7 +1059,7 @@ ssize_t read_code(struct file *file, unsigned long addr, loff_t pos, size_t len) { ssize_t res = vfs_read(file, (void __user *)addr, len, &pos); if (res > 0) - flush_icache_range(addr, addr + len); + flush_icache_user_range(addr, addr + len); return res; } EXPORT_SYMBOL(read_code); |