Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-06 Thread Gerd Hoffmann
On Mon, 2017-06-05 at 13:56 +0530, Kirti Wankhede wrote: > > On 6/2/2017 2:08 PM, Gerd Hoffmann wrote: > > > > > struct vfio_vgpu_surface_info { > > > __u64 start; > > > __u32 width; > > > __u32 height; > > > __u32 stride; > > > __u32 size; > > >

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-06 Thread Gerd Hoffmann
On Mon, 2017-06-05 at 13:56 +0530, Kirti Wankhede wrote: > > On 6/2/2017 2:08 PM, Gerd Hoffmann wrote: > > > > > struct vfio_vgpu_surface_info { > > > __u64 start; > > > __u32 width; > > > __u32 height; > > > __u32 stride; > > > __u32 size; > > >

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-05 Thread Kirti Wankhede
On 6/2/2017 2:08 PM, Gerd Hoffmann wrote: > >> struct vfio_vgpu_surface_info { >> __u64 start; >> __u32 width; >> __u32 height; >> __u32 stride; >> __u32 size; >> __u32 x_pos; >> __u32 y_pos; >> __u32 padding; >> /* Only

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-05 Thread Kirti Wankhede
On 6/2/2017 2:08 PM, Gerd Hoffmann wrote: > >> struct vfio_vgpu_surface_info { >> __u64 start; >> __u32 width; >> __u32 height; >> __u32 stride; >> __u32 size; >> __u32 x_pos; >> __u32 y_pos; >> __u32 padding; >> /* Only

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-02 Thread Gerd Hoffmann
> struct vfio_vgpu_surface_info { > __u64 start; > __u32 width; > __u32 height; > __u32 stride; > __u32 size; > __u32 x_pos; > __u32 y_pos; > __u32 padding; > /* Only used when VFIO_VGPU_SURFACE_DMABUF_* flags set */ >    

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-02 Thread Gerd Hoffmann
> struct vfio_vgpu_surface_info { > __u64 start; > __u32 width; > __u32 height; > __u32 stride; > __u32 size; > __u32 x_pos; > __u32 y_pos; > __u32 padding; > /* Only used when VFIO_VGPU_SURFACE_DMABUF_* flags set */ >    

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-01 Thread Kirti Wankhede
rnel@vger.kernel.org; >>> zhen...@linux.intel.com; Lv, Zhiyuan <zhiyuan...@intel.com>; intel-gvt- >>> d...@lists.freedesktop.org; Wang, Zhi A <zhi.a.w...@intel.com>; Tian, Kevin >>> <kevin.t...@intel.com> >>> Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgp

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-01 Thread Kirti Wankhede
>>>>> -Original Message- >>>>> From: Gerd Hoffmann [mailto:kra...@redhat.com] >>>>> Sent: Monday, May 29, 2017 3:20 PM >>>>> To: Chen, Xiaoguang ; >>>>> alex.william...@redhat.com; ch...@chris-wilson.co.uk; i

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-01 Thread Alex Williamson
vt- > >d...@lists.freedesktop.org; Wang, Zhi A <zhi.a.w...@intel.com>; Tian, Kevin > ><kevin.t...@intel.com> > >Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations > > > > > > > >On 5/31/2017 11:48 AM, Chen, Xiaoguang wrote:

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-06-01 Thread Alex Williamson
illiam...@redhat.com; ch...@chris-wilson.co.uk; > >intel-...@lists.freedesktop.org; linux-kernel@vger.kernel.org; > >zhen...@linux.intel.com; Lv, Zhiyuan ; intel-gvt- > >d...@lists.freedesktop.org; Wang, Zhi A ; Tian, Kevin > > > >Subject: Re: [PATCH v6 4/6] vfio: Defi

RE: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Chen, Xiaoguang
@chris-wilson.co.uk; >intel-...@lists.freedesktop.org; linux-kernel@vger.kernel.org; >zhen...@linux.intel.com; Lv, Zhiyuan <zhiyuan...@intel.com>; intel-gvt- >d...@lists.freedesktop.org; Wang, Zhi A <zhi.a.w...@intel.com>; Tian, Kevin ><kevin.t...@intel.com> >Subject: Re: [PATCH v6 4/6] v

RE: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Chen, Xiaoguang
.kernel.org; >zhen...@linux.intel.com; Lv, Zhiyuan ; intel-gvt- >d...@lists.freedesktop.org; Wang, Zhi A ; Tian, Kevin > >Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations > > > >On 5/31/2017 11:48 AM, Chen, Xiaoguang wrote: >> Hi, >>

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Kirti Wankhede
com; ch...@chris-wilson.co.uk; intel- >> g...@lists.freedesktop.org; linux-kernel@vger.kernel.org; >> zhen...@linux.intel.com; Lv, Zhiyuan <zhiyuan...@intel.com>; intel-gvt- >> d...@lists.freedesktop.org; Wang, Zhi A <zhi.a.w...@intel.com>; Tian, Kevin >> <kevin.

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Kirti Wankhede
intel- >> g...@lists.freedesktop.org; linux-kernel@vger.kernel.org; >> zhen...@linux.intel.com; Lv, Zhiyuan ; intel-gvt- >> d...@lists.freedesktop.org; Wang, Zhi A ; Tian, Kevin >> >> Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations >>

RE: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Chen, Xiaoguang
l@vger.kernel.org; >zhen...@linux.intel.com; Lv, Zhiyuan <zhiyuan...@intel.com>; intel-gvt- >d...@lists.freedesktop.org; Wang, Zhi A <zhi.a.w...@intel.com>; Tian, Kevin ><kevin.t...@intel.com> >Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations &g

RE: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-31 Thread Chen, Xiaoguang
ntel.com; Lv, Zhiyuan ; intel-gvt- >d...@lists.freedesktop.org; Wang, Zhi A ; Tian, Kevin > >Subject: Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations > >> +struct vfio_vgpu_dmabuf_info { >> +__u32 argsz; >> +__u32 flags; >> +

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-29 Thread Gerd Hoffmann
> +struct vfio_vgpu_dmabuf_info { > + __u32 argsz; > + __u32 flags; > + struct vfio_vgpu_plane_info plane_info; > + __s32 fd; > + __u32 pad; > +}; Hmm, now you have argsz and flags twice in vfio_vgpu_dmabuf_info ... I think we should have something like this: struct

Re: [PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-29 Thread Gerd Hoffmann
> +struct vfio_vgpu_dmabuf_info { > + __u32 argsz; > + __u32 flags; > + struct vfio_vgpu_plane_info plane_info; > + __s32 fd; > + __u32 pad; > +}; Hmm, now you have argsz and flags twice in vfio_vgpu_dmabuf_info ... I think we should have something like this: struct

[PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-27 Thread Xiaoguang Chen
Here we defined a new ioctl to create a fd for a vfio device based on the input type. Now only one type is supported that is a dma-buf management fd. Two ioctls are defined for the dma-buf management fd: query the vfio vgpu's plane information and create a dma-buf for a plane. Signed-off-by:

[PATCH v6 4/6] vfio: Define vfio based vgpu's dma-buf operations

2017-05-27 Thread Xiaoguang Chen
Here we defined a new ioctl to create a fd for a vfio device based on the input type. Now only one type is supported that is a dma-buf management fd. Two ioctls are defined for the dma-buf management fd: query the vfio vgpu's plane information and create a dma-buf for a plane. Signed-off-by: