[Top][All Lists]

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

Re: [Qemu-ppc] [Qemu-devel] [PATCH 13/13] target-ppc: Give a meaningful

From: Peter Maydell
Subject: Re: [Qemu-ppc] [Qemu-devel] [PATCH 13/13] target-ppc: Give a meaningful error if too many threads are specified
Date: Thu, 13 Dec 2012 14:17:34 +0000

On 13 December 2012 13:19, Alexander Graf <address@hidden> wrote:
> On 13.12.2012, at 14:17, David Gibson wrote:
>> On Thu, Dec 13, 2012 at 01:57:16PM +0100, Alexander Graf wrote:
>>> What if I am using TCG on PPC?
>> Then the stub version of kvmppc_smt_threads() returns 1, and since the
>> PPC TCG doesn't do any SMT emulation, that would seem to be correct...
> int kvmppc_smt_threads(void)
> {
>     return cap_ppc_smt ? cap_ppc_smt : 1;
> }
> So because we don't call kvm_arch_init, the cap is 0 and thus we return 1?

No, if we aren't CONFIG_KVM then that source file and version of
the function aren't compiled at all. David means the stub
function, which is in kvm_ppc.h:
static inline int kvmppc_smt_threads(void)
    return 1;

(if you don't like stubs lurking in the header file you could
have a target-ppc/kvm-stub.c by analogy with the i386 one I suppose)

-- PMM

reply via email to

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