qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-ppc] [RFC PATCH 12/17] PowerPC: booke64: Add DO_KVM kernel hoo


From: Alexander Graf
Subject: Re: [Qemu-ppc] [RFC PATCH 12/17] PowerPC: booke64: Add DO_KVM kernel hooks
Date: Sat, 7 Jul 2012 01:11:16 +0200

On 07.07.2012, at 00:33, Caraman Mihai Claudiu-B02008 wrote:

>> -----Original Message-----
>> From: Benjamin Herrenschmidt [mailto:address@hidden
>> Sent: Thursday, July 05, 2012 1:26 AM
>> To: Alexander Graf
>> Cc: Caraman Mihai Claudiu-B02008; <address@hidden>; KVM list;
>> linuxppc-dev; address@hidden List
>> Subject: Re: [Qemu-ppc] [RFC PATCH 12/17] PowerPC: booke64: Add DO_KVM
>> kernel hooks
>> 
>> On Wed, 2012-07-04 at 16:29 +0200, Alexander Graf wrote:
>> 
>>>> +#ifdef CONFIG_KVM_BOOKE_HV
>>>> +#define KVM_BOOKE_HV_MFSPR(reg, spr)                              \
>>>> +  BEGIN_FTR_SECTION                                       \
>>>> +          mfspr   reg, spr;                               \
>>>> +  END_FTR_SECTION_IFSET(CPU_FTR_EMB_HV)
>>>> +#else
>>>> +#define KVM_BOOKE_HV_MFSPR(reg, spr)
>>>> +#endif
>>> 
>>> Bleks - this is ugly. Do we really need to open-code the #ifdef here?
>>> Can't the feature section code determine that the feature is disabled
>>> and just always not include the code?
>> 
>> You can't but in any case I don't see the point of the conditional here,
>> we'll eventually have to load srr1 no ? We can move the load up to here
>> in all cases or can't we ? 
> 
> I like the idea, but there is a problem with addition macros which may clobber
> r11 and PROLOG_ADDITION_MASKABLE_GEN is such a case.

Mike -v please :)


Alex




reply via email to

[Prev in Thread] Current Thread [Next in Thread]