[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220411183648.GA2120790@nvidia.com>
Date: Mon, 11 Apr 2022 15:36:48 -0300
From: Jason Gunthorpe <jgg@...dia.com>
To: Christoph Hellwig <hch@....de>
Cc: Jani Nikula <jani.nikula@...ux.intel.com>,
Joonas Lahtinen <joonas.lahtinen@...ux.intel.com>,
Rodrigo Vivi <rodrigo.vivi@...el.com>,
Zhenyu Wang <zhenyuw@...ux.intel.com>,
Zhi Wang <zhi.a.wang@...el.com>,
intel-gfx@...ts.freedesktop.org,
intel-gvt-dev@...ts.freedesktop.org,
dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 28/34] drm/i915/gvt: convert to use
vfio_register_emulated_iommu_dev
On Mon, Apr 11, 2022 at 04:13:57PM +0200, Christoph Hellwig wrote:
> -static int intel_vgpu_create(struct mdev_device *mdev)
> -{
> - struct device *pdev = mdev_parent_dev(mdev);
> - struct intel_gvt *gvt = kdev_to_i915(pdev)->gvt;
> - struct intel_vgpu_type *type;
> - struct intel_vgpu *vgpu;
> -
> - type = &gvt->types[mdev_get_type_group_id(mdev)];
> - if (!type)
> - return -EINVAL;
> -
> - vgpu = intel_gvt_create_vgpu(gvt, type);
> - if (IS_ERR(vgpu)) {
> - gvt_err("failed to create intel vgpu: %ld\n", PTR_ERR(vgpu));
> - return PTR_ERR(vgpu);
> - }
> -
> - INIT_WORK(&vgpu->release_work, intel_vgpu_release_work);
> -
> - vgpu->mdev = mdev;
> - mdev_set_drvdata(mdev, vgpu);
> -
> - gvt_dbg_core("intel_vgpu_create succeeded for mdev: %s\n",
> - dev_name(mdev_dev(mdev)));
nit: the debug print has the wrong function name now
Rest looks OK
Reviewed-by: Jason Gunthorpe <jgg@...dia.com>
Jason
Powered by blists - more mailing lists