Skip to content

Commit

Permalink
mm/gup.c: make unnecessarily global vma_permits_fault() static
Browse files Browse the repository at this point in the history
Make vma_permits_fault() static as it is only used in mm/gup.c

This fixes a sparse warning.

Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Tobias Klauser <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
tklauser authored and torvalds committed Dec 13, 2016
1 parent 5f33a08 commit 771ab43
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mm/gup.c
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,8 @@ static long __get_user_pages(struct task_struct *tsk, struct mm_struct *mm,
return i;
}

bool vma_permits_fault(struct vm_area_struct *vma, unsigned int fault_flags)
static bool vma_permits_fault(struct vm_area_struct *vma,
unsigned int fault_flags)
{
bool write = !!(fault_flags & FAULT_FLAG_WRITE);
bool foreign = !!(fault_flags & FAULT_FLAG_REMOTE);
Expand Down

0 comments on commit 771ab43

Please sign in to comment.