qemu-ppc
[Top][All Lists]
Advanced

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

Re: [Qemu-ppc] Qemu pSeries AIX ADB boot


From: Alexander Graf
Subject: Re: [Qemu-ppc] Qemu pSeries AIX ADB boot
Date: Tue, 12 Jun 2012 11:36:34 +0200
User-agent: Thunderbird 2.0.0.23 (X11/20090817)

Thomas Huth wrote:
> Am Tue, 12 Jun 2012 10:45:28 +0200
> schrieb Alexander Graf <address@hidden>:
>
>   
>> Michael Sabino wrote:
>>     
> [...]
>   
>>> Here is some sPAPR pSeries Partition Pool code that I think is better
>>> than the version in the aix qemu tree. It seems to compile, but it
>>> does not get me any further as far as I can tell.
>>>
>>> It's based on the suggestion of Alex to look at
>>> http://lxr.free-electrons.com/source/arch/powerpc/kernel/lparcfg.c?a=m68k#L108.
>>>
>>> static target_ulong h_get_ppp(CPUPPCState *env, sPAPREnvironment *spapr,
>>>                               target_ulong opcode, target_ulong *args)
>>> {
>>>     printf("\nh_get_ppp might not be right yet\n");
>>>     env->gpr[4] = 100; // Processor capacity percentage
>>>     env->gpr[5] = 0; // Unallocated processor capacity percentage
>>>       
>> This won't work. args is synchronized back onto the GPRs.
>>     
>
> That does not sound nice ... where does this happen? 

Check out emulate_spapr_hypercall and spapr_hypercall in hw/spapr*c :).

> And what's the
> correct way to set a GPR in a hypercall?
>   

Ah, it does work, because args == &env->gpr[4]. Sorry :). It'd still be
better to set args[0] rather than gpr[4] to be consistent with the rest
of the code.


Alex




reply via email to

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