qemu-ppc
[Top][All Lists]
Advanced

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

Re: [PATCH 1/4] qapi/qdev.json: add DEVICE_NOT_DELETED event


From: Eric Blake
Subject: Re: [PATCH 1/4] qapi/qdev.json: add DEVICE_NOT_DELETED event
Date: Tue, 23 Mar 2021 13:00:24 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1

On 3/12/21 2:07 PM, Daniel Henrique Barboza wrote:
> This new event informs QAPI listeners that a previously issued
> 'device_del' command failed to delete the device from the machine.
> 
> Note that no assertion can be made about the failure reason. The goal of
> this event is to inform management that QEMU is not able to assess
> whether the hotunplug is taking too long to complete or failed in the
> guest and, as result, the device is not removed from QOM. When receiving
> this event, users/management must check inside the guest to verify the
> result of the hotunplug operation.
> 
> This scenario happens with architectures where the guest does not have
> an official way to report the hotunplug error back to the hypervisor,
> such as PowerPC and the pseries machine type.
> 
> Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
> ---
>  qapi/qdev.json | 28 ++++++++++++++++++++++++++++
>  1 file changed, 28 insertions(+)
> 
> diff --git a/qapi/qdev.json b/qapi/qdev.json
> index b83178220b..df9a1b9e67 100644
> --- a/qapi/qdev.json
> +++ b/qapi/qdev.json
> @@ -124,3 +124,31 @@
>  ##
>  { 'event': 'DEVICE_DELETED',
>    'data': { '*device': 'str', 'path': 'str' } }
> +
> +##
> +# @DEVICE_NOT_DELETED:
> +#
> +# Emitted whenever the device removal process expired and the device
> +# still exists in QOM. This indicates that the guest took too long
> +# to acknowlege the device removal, and we can not be sure of whether

acknowledge

> +# the process will be completed in the guest later on or a guest
> +# side error occurred.
> +#
> +# It is not safe to reuse the specified device ID.
> +#
> +# @device: device name
> +#
> +# @path: device path
> +#
> +# Since: 6.0

This is a new event, and we've missed feature freeze; is this fixing a
bug that was not present in 5.2 (in which case it is fine for -rc1), or
is this a long-standing problem where one more release without the
mechanism won't make life any worse?

> +#
> +# Example:
> +#
> +# <- { "event": "DEVICE_NOT_DELETED",
> +#      "data": { "device": "core1",
> +#                "path": "/machine/peripheral/core1" },
> +#      "timestamp": { "seconds": 1615570254, "microseconds": 573986 } }
> +#
> +##
> +{ 'event': 'DEVICE_NOT_DELETED',
> +  'data': { '*device': 'str', 'path': 'str' } }
> \ No newline at end of file

You'll want to fix that.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org




reply via email to

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