OSDN Git Service

powerpc/book3s64/pkeys: Simplify pkey disable branch
authorAneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Thu, 9 Jul 2020 03:29:32 +0000 (08:59 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 20 Jul 2020 12:57:58 +0000 (22:57 +1000)
commita4678d4b477c3d2901f101986ca01406f3b7eaea
tree4ac51568c4bbbb1906620bc37e74c99e94694403
parenta24204c307962214996627e3f4caa8772b9b0cf4
powerpc/book3s64/pkeys: Simplify pkey disable branch

Make the default value FALSE (pkey enabled) and set to TRUE when we
find the total number of keys supported to be zero.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200709032946.881753-10-aneesh.kumar@linux.ibm.com
arch/powerpc/include/asm/pkeys.h
arch/powerpc/mm/book3s64/pkeys.c