瀏覽代碼

[PATCH] swap: update swapfile i_sem comment

Update swap extents comment: nowadays we guard with S_SWAPFILE not i_sem.

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Hugh Dickins 19 年之前
父節點
當前提交
b0d9bcd4bb
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      mm/swapfile.c

+ 1 - 1
mm/swapfile.c

@@ -926,7 +926,7 @@ add_swap_extent(struct swap_info_struct *sis, unsigned long start_page,
  * requirements, they are simply tossed out - we will never use those blocks
  * requirements, they are simply tossed out - we will never use those blocks
  * for swapping.
  * for swapping.
  *
  *
- * For S_ISREG swapfiles we hold i_sem across the life of the swapon.  This
+ * For S_ISREG swapfiles we set S_SWAPFILE across the life of the swapon.  This
  * prevents root from shooting her foot off by ftruncating an in-use swapfile,
  * prevents root from shooting her foot off by ftruncating an in-use swapfile,
  * which will scribble on the fs.
  * which will scribble on the fs.
  *
  *