qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] target/arm/kvm: gic: Prevent creating userspace


From: Philippe Mathieu-Daudé
Subject: Re: [Qemu-devel] [PATCH] target/arm/kvm: gic: Prevent creating userspace GICv3 with KVM
Date: Mon, 5 Feb 2018 21:10:48 -0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2

Hi Christoffer,

On 02/01/2018 05:53 PM, Christoffer Dall wrote:
> KVM doesn't support emulating a GICv3 in userspace, only GICv2.  We
> currently attempt this anyway, and as a result a KVM guest doesn't
> receive interrupts and the user is left wondering why.  Report an error
> to the user if this particular combination is requested.
> 
> Signed-off-by: Christoffer Dall <address@hidden>
> ---
>  target/arm/kvm_arm.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/target/arm/kvm_arm.h b/target/arm/kvm_arm.h
> index ff53e9fafb..cfb7e5af72 100644
> --- a/target/arm/kvm_arm.h
> +++ b/target/arm/kvm_arm.h
> @@ -234,6 +234,10 @@ static inline const char *gicv3_class_name(void)

Any reason why these functions are inlined in this include?

Also - not related to your patch - while gicv3_class_name() is
self-explicit, gic_class_name() isn't (to me at least).

There are many check for gic_version 1/2/3 in virt.c, which we could
clean using more generic functions such gic_class_name(int gic_version)
and Co.

Alistair/Edgar:
Why the ZynqMP is not using the GICv3 for the APU? I remember hearing
something about not fully implemented so not working correctly.

>          exit(1);
>  #endif
>      } else {
> +        if (kvm_enabled()) {
> +            error_report("Userspace GICv3 is not supported with KVM");
> +            exit(1);

Reviewed-by: Philippe Mathieu-Daudé <address@hidden>

> +        }
>          return "arm-gicv3";
>      }
>  }
> 

Regards,

Phil.

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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