]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/mm: remove unnecessary test in pgtable_cache_init()
authorChristophe Leroy <christophe.leroy@c-s.fr>
Thu, 29 Nov 2018 14:07:09 +0000 (14:07 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 4 Dec 2018 08:45:01 +0000 (19:45 +1100)
commitcd674a6f3628670547e51f991905301c1984eb58
tree2aff70e3823e4cd896668a3c30ad173ee458ff99
parenta04afb4f59893540a66e79cb969b4ede01835a33
powerpc/mm: remove unnecessary test in pgtable_cache_init()

pgtable_cache_add() gracefully handles the case when a cache that
size already exists by returning early with the following test:

if (PGT_CACHE(shift))
return; /* Already have a cache of this size */

It is then not needed to test the existence of the cache before.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/mm/init-common.c