]> git.baikalelectronics.ru Git - kernel.git/commit
s390/mm: use refcount_t for refcount
authorChuhong Yuan <hslester96@gmail.com>
Thu, 8 Aug 2019 07:18:26 +0000 (15:18 +0800)
committerVasily Gorbik <gor@linux.ibm.com>
Wed, 21 Aug 2019 10:41:43 +0000 (12:41 +0200)
commit9941bb7b5997e71e2b5b196e728be2889fe7f067
tree0d733b4321ccc910b63fcb1990dd30f52725a242
parent5905f29c2405f2a9add2571d04b8ed8e85bd3141
s390/mm: use refcount_t for refcount

Reference counters are preferred to use refcount_t instead of
atomic_t.
This is because the implementation of refcount_t can prevent
overflows and detect possible use-after-free.
So convert atomic_t ref counters to refcount_t.

Link: http://lkml.kernel.org/r/20190808071826.6649-1-hslester96@gmail.com
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
arch/s390/include/asm/gmap.h
arch/s390/mm/gmap.c