From: Gerd Hoffmann <kraxel@redhat.com>
To: Xiaoguang Chen <xiaoguang.chen@intel.com>,
alex.williamson@redhat.com, intel-gfx@lists.freedesktop.org,
linux-kernel@vger.kernel.org, zhenyuw@linux.intel.com,
zhiyuan.lv@intel.com, intel-gvt-dev@lists.freedesktop.org,
zhi.a.wang@intel.com, kevin.tian@intel.com
Subject: Re: [PATCH v5 5/5] drm/i915/gvt: Adding interface so user space can get the dma-buf
Date: Tue, 23 May 2017 16:09:57 +0200 [thread overview]
Message-ID: <1495548597.30747.8.camel@redhat.com> (raw)
In-Reply-To: <1495535521-2120-6-git-send-email-xiaoguang.chen@intel.com>
Hi,
> diff --git a/include/uapi/linux/vfio.h b/include/uapi/linux/vfio.h
> index ae46105..285dc16 100644
> --- a/include/uapi/linux/vfio.h
> +++ b/include/uapi/linux/vfio.h
> @@ -502,10 +502,58 @@ struct vfio_pci_hot_reset {
>
> #define VFIO_DEVICE_PCI_HOT_RESET _IO(VFIO_TYPE, VFIO_BASE +
> 13)
>
> +/**
> + * VFIO_DEVICE_GET_FD - _IO(VFIO_TYPE, VFIO_BASE + 14, __u32)
> + *
> + * Create a fd for a vfio device based on the input type
> + * Vendor driver should handle this ioctl to create a fd and manage
> the
> + * life cycle of this fd.
> + *
> + * Return: a fd if vendor support that type, -errno if not supported
> + */
> +
> +#define VFIO_DEVICE_GET_FD _IO(VFIO_TYPE, VFIO_BASE + 14)
> +
> +#define VFIO_DEVICE_DMABUF_MGR_FD 0 /* Supported fd types */
> +
> +/*
> + * VFIO_DEVICE_QUERY_PLANE - _IO(VFIO_TYPE, VFIO_BASE + 15, struct
> plane_info)
> + * Query plane information for a plane
> + */
> +struct plane_info {
That is a pretty generic name. vfio_vgpu_plane_info? Or
vfio_dmabuf_plane_info?
> + __u32 plane_id;
> + __u32 drm_format;
> + __u32 width;
> + __u32 height;
> + __u32 stride;
> + __u32 start;
> + __u32 x_pos;
> + __u32 y_pos;
> + __u32 size;
> + __u64 drm_format_mod;
> +};
> +
> +#define VFIO_PRIMARY_PLANE 1
> +#define VFIO_CURSOR_PLANE 2
I think we should use "enum drm_plane_type" values instead of creating
something new.
cheers,
Gerd
next prev parent reply other threads:[~2017-05-23 14:10 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-23 10:31 [PATCH v5 0/5] drm/i915/gvt: Dma-buf support for GVT-g Xiaoguang Chen
2017-05-23 10:31 ` [PATCH v5 1/5] drm/i915/gvt: Extend the GVT-g architecture to support vfio device region Xiaoguang Chen
2017-05-23 10:31 ` [PATCH v5 2/5] drm/i915/gvt: OpRegion support for GVT-g Xiaoguang Chen
2017-05-23 10:31 ` [PATCH v5 3/5] drm/i915/gvt: Frame buffer decoder " Xiaoguang Chen
2017-05-23 10:32 ` [PATCH v5 4/5] drm/i915/gvt: Dmabuf " Xiaoguang Chen
2017-05-23 14:00 ` Gerd Hoffmann
2017-05-23 19:25 ` Alex Williamson
2017-05-25 13:28 ` [Intel-gfx] " Chris Wilson
2017-05-26 8:28 ` Chris Wilson
2017-05-23 10:32 ` [PATCH v5 5/5] drm/i915/gvt: Adding interface so user space can get the dma-buf Xiaoguang Chen
2017-05-23 14:09 ` Gerd Hoffmann [this message]
2017-05-23 15:35 ` Kirti Wankhede
2017-05-23 19:25 ` Alex Williamson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1495548597.30747.8.camel@redhat.com \
--to=kraxel@redhat.com \
--cc=alex.williamson@redhat.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=intel-gvt-dev@lists.freedesktop.org \
--cc=kevin.tian@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=xiaoguang.chen@intel.com \
--cc=zhenyuw@linux.intel.com \
--cc=zhi.a.wang@intel.com \
--cc=zhiyuan.lv@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox