Re: [PATCH 26/33] qemu: Add qemuDomainDefaultPanicModel()

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

 



On Wed, Jan 24, 2024 at 20:37:46 +0100, Andrea Bolognani wrote:
> Factor out the existing code.
> 
> Signed-off-by: Andrea Bolognani <abologna@xxxxxxxxxx>
> ---
>  src/qemu/qemu_domain.c | 23 +++++++++++++++--------
>  1 file changed, 15 insertions(+), 8 deletions(-)
> 
> diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
> index c9d213dd7b..8a37cda464 100644
> --- a/src/qemu/qemu_domain.c
> +++ b/src/qemu/qemu_domain.c
> @@ -4346,6 +4346,19 @@ qemuDomainDefaultSerialModel(const virDomainDef *def,
>  }
>  
>  
> +static int
> +qemuDomainDefaultPanicModel(const virDomainDef *def)
> +{
> +    if (qemuDomainIsPSeries(def))
> +        return VIR_DOMAIN_PANIC_MODEL_PSERIES;
> +
> +    if (ARCH_IS_S390(def->os.arch))
> +        return VIR_DOMAIN_PANIC_MODEL_S390;
> +

You see, this is much better ;)

> +    return VIR_DOMAIN_PANIC_MODEL_ISA;
> +}
> +

Reviewed-by: Peter Krempa <pkrempa@xxxxxxxxxx>
_______________________________________________
Devel mailing list -- devel@xxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxx




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux