Re: [RFC v2 12/12]selftest: Updated protection key selftest

From: Ram Pai
Date: Tue Jun 20 2017 - 20:11:12 EST


On Tue, Jun 20, 2017 at 11:56:04AM +0530, Anshuman Khandual wrote:
> On 06/17/2017 09:22 AM, Ram Pai wrote:
> > Added test support for PowerPC implementation off protection keys.
> >
> > Signed-off-by: Ram Pai <linuxram@xxxxxxxxxx>
>
> First of all, there are a lot of instances where we use *pkru*
> named functions on power even the real implementations have
> taken care of doing appropriate things. That looks pretty
> hacky. We need to change them to generic names first before
> adding both x86 and powerpc procedures inside it.

I have abstracted out the arch-specific code. References to
pkru should now be constricted to x86 code only.

The patch, i acknowledge, is not easily reviewable.
As Michael Ellermen mentioned I will break them into two patches.
One moves the file and the second does the code changes. That way
it will be easy to review.

RP