qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 06/18] xen: add grant table interface for XenDev


From: Anthony PERARD
Subject: Re: [Qemu-devel] [PATCH 06/18] xen: add grant table interface for XenDevice-s
Date: Mon, 3 Dec 2018 15:45:56 +0000
User-agent: Mutt/1.11.0 (2018-11-25)

On Wed, Nov 21, 2018 at 03:11:59PM +0000, Paul Durrant wrote:
> The legacy PV backend infrastructure provides functions to map, unmap and
> copy pages granted by frontends. Similar functionality will be required
> by XenDevice implementations so this patch adds the necessary support.
> 
> Signed-off-by: Paul Durrant <address@hidden>
> ---
> +typedef struct XenDeviceGrantCopySegment {
> +    union {
> +        void *virt;
> +        struct {
> +            uint32_t ref;
> +            off_t offset;
> +        } foreign;
> +    } source, dest;

Why is there a union between `source` and `dest`, I don't see any way
(another field) to distinguish which is which. Can't we have a
segment without `source`/`dest`? It mimic the
xengnttab_grant_copy_segment_t but that doesn't seems very useful as it
doesn't really prevent mistake.

> +    size_t len;
> +} XenDeviceGrantCopySegment;

Anyway, it's not very important:

Reviewed-by: Anthony PERARD <address@hidden>

Thanks,

-- 
Anthony PERARD



reply via email to

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