]> git.baikalelectronics.ru Git - kernel.git/commit
mm: remove unnecessary local variable addr in __get_user_pages_fast()
authorWei Yang <richard.weiyang@gmail.com>
Fri, 26 Oct 2018 22:07:55 +0000 (15:07 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 26 Oct 2018 23:26:34 +0000 (16:26 -0700)
commit9b6eedd8d627fae3135abf9696906fd1c839ddcc
treed9fe02eaf997d41db0e0f5895e37b5e8c83e4458
parent350876a67ac33f3786383bc36758e576cae006f9
mm: remove unnecessary local variable addr in __get_user_pages_fast()

The local variable `addr' in __get_user_pages_fast() is just a shadow of
`start'.  Since `start' never changes after assignment to `addr', it is
fine to replace `start' with it.

Also the meaning of [start, end] is more obvious than [addr, end] when
passed to gup_pgd_range().

Link: http://lkml.kernel.org/r/20180925021448.20265-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/gup.c