diff options
author | Christoph Hellwig <hch@lst.de> | 2020-02-21 05:04:15 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-02-21 20:22:15 +0100 |
commit | fed98ef4d8b665316479dd35cbd92d3e2ff470a3 (patch) | |
tree | 07e493a5bfc0ab14c8d02c796b79152f9cc14043 /mm/swapfile.c | |
parent | scripts/get_maintainer.pl: deprioritize old Fixes: addresses (diff) | |
download | linux-fed98ef4d8b665316479dd35cbd92d3e2ff470a3.tar.xz linux-fed98ef4d8b665316479dd35cbd92d3e2ff470a3.zip |
mm/swapfile.c: fix a comment in sys_swapon()
claim_swapfile now always takes i_rwsem.
Link: http://lkml.kernel.org/r/20200114161225.309792-2-hch@lst.de
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/swapfile.c')
-rw-r--r-- | mm/swapfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/swapfile.c b/mm/swapfile.c index 2c33ff456ed5..b2a2e45c9a36 100644 --- a/mm/swapfile.c +++ b/mm/swapfile.c @@ -3157,7 +3157,7 @@ SYSCALL_DEFINE2(swapon, const char __user *, specialfile, int, swap_flags) mapping = swap_file->f_mapping; inode = mapping->host; - /* If S_ISREG(inode->i_mode) will do inode_lock(inode); */ + /* will take i_rwsem; */ error = claim_swapfile(p, inode); if (unlikely(error)) goto bad_swap; |