Skip to content
Commit 5e451be7 authored by Anshuman Khandual's avatar Anshuman Khandual Committed by Linus Torvalds
Browse files

mm/madvise: move up the behavior parameter validation



madvise_behavior_valid() should be called before acting upon the
behavior parameter.  Hence move up the function.  This also includes
MADV_SOFT_OFFLINE and MADV_HWPOISON options as valid behavior parameter
for the system call madvise().

Link: http://lkml.kernel.org/r/20170418052844.24891-1-khandual@linux.vnet.ibm.com
Signed-off-by: default avatarAnshuman Khandual <khandual@linux.vnet.ibm.com>
Acked-by: default avatarDavid Rientjes <rientjes@google.com>
Acked-by: default avatarNaoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 97167a76
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment