[PATCH v3 1/2] selftests/powerpc: Add MSR bits

Breno Leitao leitao at debian.org
Mon Jan 7 23:44:12 AEDT 2019


hi Christophe,

On 1/3/19 3:19 PM, LEROY Christophe wrote:
> Breno Leitao <leitao at debian.org> a écrit :
> 
>> This patch simply adds definitions for the MSR bits and some macros to
>> test for MSR TM bits.
>>
>> This was copied from arch/powerpc/include/asm/reg.h generic MSR part.
> 
> Can't we find a way to avoid duplicating such defines ?

I think there are three possible ways, but none of them respect the premises
we are used too. These are the possible ways I can think of:

1) Including arch/powerpc/include/asm as part of the selftest compilation
process.
   Problem: This might break the selftest independence of the kbuild system.

2) Generate a temporary header file inside selftests/include which contains
these macros at compilation time.
   Problem: The problem as above.

3) Define MSR fields at userspace headers (/usr/include).
   Problem: I am not sure userspace should have MSR bits information.

Do you suggest me to investigate any other way?


More information about the Linuxppc-dev mailing list