qemu-devel
[Top][All Lists]
Advanced

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

Re: [PULL v4 36/43] sgx-epc: Add the fill_device_info() callback support


From: Eric Blake
Subject: Re: [PULL v4 36/43] sgx-epc: Add the fill_device_info() callback support
Date: Wed, 8 Sep 2021 09:54:03 -0500
User-agent: NeoMutt/20210205-739-420e15

On Wed, Sep 08, 2021 at 12:04:19PM +0200, Paolo Bonzini wrote:
> From: Yang Zhong <yang.zhong@intel.com>
> 
> Since there is no fill_device_info() callback support, and when we
> execute "info memory-devices" command in the monitor, the segfault
> will be found.
> 
> This patch will add this callback support and "info memory-devices"
> will show sgx epc memory exposed to guest. The result as below:
> 
> +++ b/qapi/machine.json
> @@ -1220,6 +1220,29 @@
>    'data': { 'sgx-epc': ['SgxEPC'] }
>  }
>  
> +##
> +# @SgxEPCDeviceInfo:
> +#
> +# Sgx EPC state information
> +#
> +# @id: device's ID
> +#
> +# @memaddr: physical address in memory, where device is mapped
> +#
> +# @size: size of memory that the device provides
> +#
> +# @memdev: memory backend linked with device
> +#
> +# Since: 6.1

And another spot for a followup patch for 6.2 designation.

> +##
> +{ 'struct': 'SgxEPCDeviceInfo',
> +  'data': { '*id': 'str',
> +            'memaddr': 'size',
> +            'size': 'size',
> +            'memdev': 'str'
> +          }
> +}
> +
>  ##
>  # @MemoryDeviceInfo:
>  #
> @@ -1234,7 +1257,8 @@
>    'data': { 'dimm': 'PCDIMMDeviceInfo',
>              'nvdimm': 'PCDIMMDeviceInfo',
>              'virtio-pmem': 'VirtioPMEMDeviceInfo',
> -            'virtio-mem': 'VirtioMEMDeviceInfo'
> +            'virtio-mem': 'VirtioMEMDeviceInfo',
> +            'sgx-epc': 'SgxEPCDeviceInfo'
>            }
>  }
>  
> -- 
> 2.31.1
> 
> 
> 

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




reply via email to

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