]> git.baikalelectronics.ru Git - kernel.git/commit
tile: use simpler API for random address requests
authorJason Cooper <jason@lakedaemon.net>
Tue, 11 Oct 2016 20:54:05 +0000 (13:54 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 11 Oct 2016 22:06:32 +0000 (15:06 -0700)
commit0a3dd72c5ec3140b781294a667ddb32402e6b8db
tree283f9357259cc7ad8a528df2ba9eb1144a037f5d
parent07bc6870a54a46c25015d572b04b78ca26c68014
tile: use simpler API for random address requests

Currently, all callers to randomize_range() set the length to 0 and
calculate end by adding a constant to the start address.  We can simplify
the API to remove a bunch of needless checks and variables.

Use the new randomize_addr(start, range) call to set the requested
address.

Link: http://lkml.kernel.org/r/20160803233913.32511-6-jason@lakedaemon.net
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Acked-by: Kees Cook <keescook@chromium.org>
Cc: "Theodore Ts'o" <tytso@mit.edu>
Cc: Chris Metcalf <cmetcalf@mellanox.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/tile/mm/mmap.c