Skip to content

Commit

Permalink
mm: mark fault_around_bytes __read_mostly
Browse files Browse the repository at this point in the history
fault_around_bytes can only be changed via debugfs.  Let's mark it
read-mostly.

Signed-off-by: Kirill A. Shutemov <[email protected]>
Suggested-by: David Rientjes <[email protected]>
Acked-by: David Rientjes <[email protected]>
Cc: Dave Hansen <[email protected]>
Cc: Andrey Ryabinin <[email protected]>
Cc: Sasha Levin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
kiryl authored and torvalds committed Aug 7, 2014
1 parent aecd6f4 commit 3a91053
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mm/memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -2766,7 +2766,8 @@ void do_set_pte(struct vm_area_struct *vma, unsigned long address,
update_mmu_cache(vma, address, pte);
}

static unsigned long fault_around_bytes = rounddown_pow_of_two(65536);
static unsigned long fault_around_bytes __read_mostly =
rounddown_pow_of_two(65536);

#ifdef CONFIG_DEBUG_FS
static int fault_around_bytes_get(void *data, u64 *val)
Expand Down

0 comments on commit 3a91053

Please sign in to comment.