All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Eric Auger <eric.auger@redhat.com>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>,
	David Airlie <airlied@gmail.com>,
	Alex Williamson <alex.williamson@redhat.com>,
	Ankit Agrawal <ankita@nvidia.com>,
	Christian Borntraeger <borntraeger@linux.ibm.com>,
	Brett Creeley <brett.creeley@amd.com>,
	dri-devel@lists.freedesktop.org,
	Eric Farman <farman@linux.ibm.com>,
	Giovanni Cabiddu <giovanni.cabiddu@intel.com>,
	Vasily Gorbik <gor@linux.ibm.com>,
	Heiko Carstens <hca@linux.ibm.com>,
	intel-gfx@lists.freedesktop.org,
	Jani Nikula <jani.nikula@linux.intel.com>,
	Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
	Kevin Tian <kevin.tian@intel.com>,
	kvm@vger.kernel.org, Kirti Wankhede <kwankhede@nvidia.com>,
	linux-s390@vger.kernel.org, Longfang Liu <liulongfang@huawei.com>,
	Matthew Rosato <mjrosato@linux.ibm.com>,
	Nikhil Agarwal <nikhil.agarwal@amd.com>,
	Nipun Gupta <nipun.gupta@amd.com>,
	Peter Oberparleiter <oberpar@linux.ibm.com>,
	Halil Pasic <pasic@linux.ibm.com>,
	Pranjal Shrivastava <praan@google.com>,
	qat-linux@intel.com, Rodrigo Vivi <rodrigo.vivi@intel.com>,
	Simona Vetter <simona@ffwll.ch>,
	Shameer Kolothum <skolothumtho@nvidia.com>,
	Mostafa Saleh <smostafa@google.com>,
	Sven Schnelle <svens@linux.ibm.com>,
	Tvrtko Ursulin <tursulin@ursulin.net>,
	virtualization@lists.linux.dev,
	Vineeth Vijayan <vneethv@linux.ibm.com>,
	Yishai Hadas <yishaih@nvidia.com>,
	Zhenyu Wang <zhenyuw.linux@gmail.com>,
	Zhi Wang <zhi.wang.linux@gmail.com>,
	patches@lists.linux.dev
Subject: Re: [PATCH 09/22] vfio/platform: Provide a get_region_info op
Date: Mon, 3 Nov 2025 10:27:56 -0400	[thread overview]
Message-ID: <20251103142756.GR1235738@nvidia.com> (raw)
In-Reply-To: <0815321f-00d5-402c-b84d-99bc862b4575@redhat.com>

On Mon, Nov 03, 2025 at 02:59:29PM +0100, Eric Auger wrote:
> Hi Jason,
> 
> On 10/24/25 1:09 AM, Jason Gunthorpe wrote:
> > Move it out of vfio_platform_ioctl() and re-indent it. Add it to all
> > platform drivers.
> >
> > Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
> > ---
> >  drivers/vfio/platform/vfio_amba.c             |  1 +
> >  drivers/vfio/platform/vfio_platform.c         |  1 +
> >  drivers/vfio/platform/vfio_platform_common.c  | 50 +++++++++++--------
> >  drivers/vfio/platform/vfio_platform_private.h |  2 +
> >  4 files changed, 32 insertions(+), 22 deletions(-)
> >
> > diff --git a/drivers/vfio/platform/vfio_amba.c b/drivers/vfio/platform/vfio_amba.c
> > index 9f5c527baa8a36..d600deaf23b6d7 100644
> > --- a/drivers/vfio/platform/vfio_amba.c
> > +++ b/drivers/vfio/platform/vfio_amba.c
> > @@ -115,6 +115,7 @@ static const struct vfio_device_ops vfio_amba_ops = {
> >  	.open_device	= vfio_platform_open_device,
> >  	.close_device	= vfio_platform_close_device,
> >  	.ioctl		= vfio_platform_ioctl,
> > +	.get_region_info = vfio_platform_ioctl_get_region_info,

> Any rationale behind why using _ioctl naming in some drivers and not in
> some others?

No, I was making changes sort of in line to the code that was already
there.. The _ioctl_ came from PCI where I had labeled all the sub
functions that broke out of the ioctl function with _ioctl_ to make it
clear they were part of those system calls.

I guess these can have _ioctl_ added in:

drivers/gpu/drm/i915/gvt/kvmgt.c:       .get_region_info_caps = intel_vgpu_get_region_info,
drivers/s390/cio/vfio_ccw_ops.c:        .get_region_info_caps = vfio_ccw_mdev_get_region_info,
drivers/vfio/fsl-mc/vfio_fsl_mc.c:      .get_region_info_caps = vfio_fsl_mc_get_region_info,
drivers/vfio/pci/hisilicon/hisi_acc_vfio_pci.c: .get_region_info_caps = hisi_acc_vfio_get_region,
samples/vfio-mdev/mbochs.c:     .get_region_info_caps = mbochs_get_region_info,

drivers/vfio/pci/hisilicon/hisi_acc_vfio_pci.c: .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/mlx5/main.c:   .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/nvgrace-gpu/main.c:    .get_region_info_caps = nvgrace_gpu_ioctl_get_region_info,
drivers/vfio/pci/nvgrace-gpu/main.c:    .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/pds/vfio_dev.c:        .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/cdx/main.c:        .get_region_info_caps = vfio_cdx_ioctl_get_region_info,
drivers/vfio/pci/qat/main.c:    .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/vfio_pci.c:    .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/virtio/main.c: .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/pci/virtio/main.c: .get_region_info_caps = virtiovf_pci_ioctl_get_region_info,
drivers/vfio/pci/virtio/main.c: .get_region_info_caps = vfio_pci_ioctl_get_region_info,
drivers/vfio/platform/vfio_amba.c:      .get_region_info_caps = vfio_platform_ioctl_get_region_info,
drivers/vfio/platform/vfio_platform.c:  .get_region_info_caps = vfio_platform_ioctl_get_region_info,
samples/vfio-mdev/mdpy.c:       .get_region_info_caps = mdpy_ioctl_get_region_info,
samples/vfio-mdev/mtty.c:       .get_region_info_caps = mtty_ioctl_get_region_info,

Thanks,
Jason

  reply	other threads:[~2025-11-03 14:28 UTC|newest]

Thread overview: 66+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-23 23:09 [PATCH 00/22] vfio: Give VFIO_DEVICE_GET_REGION_INFO its own op Jason Gunthorpe
2025-10-23 23:09 ` [PATCH 01/22] vfio: Provide a get_region_info op Jason Gunthorpe
2025-11-03  5:57   ` Pranjal Shrivastava
2025-11-03 14:17   ` Eric Auger
2025-10-23 23:09 ` [PATCH 02/22] vfio/hisi: Convert to the " Jason Gunthorpe
2025-10-28  1:55   ` liulongfang
2025-10-28  7:07     ` Tian, Kevin
2025-11-03  6:06   ` Pranjal Shrivastava
2025-11-03 13:31     ` Jason Gunthorpe
2025-11-07  1:29     ` liulongfang
2025-10-23 23:09 ` [PATCH 03/22] vfio/virtio: " Jason Gunthorpe
2025-11-03  6:21   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 04/22] vfio/nvgrace: " Jason Gunthorpe
2025-11-03  6:41   ` Pranjal Shrivastava
2025-11-03 13:35     ` Ankit Agrawal
2025-10-23 23:09 ` [PATCH 05/22] vfio/pci: Fill in the missing get_region_info ops Jason Gunthorpe
2025-11-03  6:43   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 06/22] vfio/mtty: Provide a get_region_info op Jason Gunthorpe
2025-11-03  7:17   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 07/22] vfio/mdpy: " Jason Gunthorpe
2025-11-03  7:18   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 08/22] vfio/mbochs: " Jason Gunthorpe
2025-11-03  7:19   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 09/22] vfio/platform: " Jason Gunthorpe
2025-11-03  7:14   ` Pranjal Shrivastava
2025-11-03  9:53   ` Mostafa Saleh
2025-11-03 13:59   ` Eric Auger
2025-11-03 14:27     ` Jason Gunthorpe [this message]
2025-10-23 23:09 ` [PATCH 10/22] vfio/fsl: " Jason Gunthorpe
2025-11-03  7:30   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 11/22] vfio/cdx: " Jason Gunthorpe
2025-11-03  7:31   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 12/22] vfio/ccw: " Jason Gunthorpe
2025-10-23 23:09 ` [PATCH 13/22] vfio/gvt: " Jason Gunthorpe
2025-10-24 10:12   ` Jani Nikula
2025-10-23 23:09 ` [PATCH 14/22] vfio: Require drivers to implement get_region_info Jason Gunthorpe
2025-11-03  7:39   ` Pranjal Shrivastava
2025-11-05 20:48     ` Alex Williamson
2025-11-05 20:56       ` Jason Gunthorpe
2025-11-05 21:19         ` Pranjal Shrivastava
2025-11-03  9:55   ` Mostafa Saleh
2025-10-23 23:09 ` [PATCH 15/22] vfio: Add get_region_info_caps op Jason Gunthorpe
2025-11-03 10:16   ` Pranjal Shrivastava
2025-11-03 11:03     ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 16/22] vfio/mbochs: Convert mbochs to use vfio_info_add_capability() Jason Gunthorpe
2025-10-23 23:09 ` [PATCH 17/22] vfio/gvt: Convert to get_region_info_caps Jason Gunthorpe
2025-10-23 23:09 ` [PATCH 18/22] vfio/ccw: " Jason Gunthorpe
2025-10-28  7:09   ` Tian, Kevin
2025-10-23 23:09 ` [PATCH 19/22] vfio/pci: Convert all PCI drivers " Jason Gunthorpe
2025-10-28 17:08   ` Brett Creeley
2025-11-03 10:25   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 20/22] vfio/platform: Convert " Jason Gunthorpe
2025-11-03  9:57   ` Mostafa Saleh
2025-11-03 10:21   ` Pranjal Shrivastava
2025-11-03 14:20   ` Eric Auger
2025-11-07  1:05     ` Jason Gunthorpe
2025-10-23 23:09 ` [PATCH 21/22] vfio: Move the remaining drivers " Jason Gunthorpe
2025-11-03 10:29   ` Pranjal Shrivastava
2025-10-23 23:09 ` [PATCH 22/22] vfio: Remove the get_region_info op Jason Gunthorpe
2025-11-03 10:52   ` Pranjal Shrivastava
2025-11-07  0:43     ` Jason Gunthorpe
2025-10-24  0:11 ` ✗ Fi.CI.BUILD: failure for vfio: Give VFIO_DEVICE_GET_REGION_INFO its own op Patchwork
2025-10-28  7:10 ` [PATCH 00/22] " Tian, Kevin
2025-11-03  9:53 ` Mostafa Saleh
2025-11-05 20:58   ` Alex Williamson
2025-11-06 20:37     ` Jason Gunthorpe

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=20251103142756.GR1235738@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=agordeev@linux.ibm.com \
    --cc=airlied@gmail.com \
    --cc=alex.williamson@redhat.com \
    --cc=ankita@nvidia.com \
    --cc=borntraeger@linux.ibm.com \
    --cc=brett.creeley@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=eric.auger@redhat.com \
    --cc=farman@linux.ibm.com \
    --cc=giovanni.cabiddu@intel.com \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=kevin.tian@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=kwankhede@nvidia.com \
    --cc=linux-s390@vger.kernel.org \
    --cc=liulongfang@huawei.com \
    --cc=mjrosato@linux.ibm.com \
    --cc=nikhil.agarwal@amd.com \
    --cc=nipun.gupta@amd.com \
    --cc=oberpar@linux.ibm.com \
    --cc=pasic@linux.ibm.com \
    --cc=patches@lists.linux.dev \
    --cc=praan@google.com \
    --cc=qat-linux@intel.com \
    --cc=rodrigo.vivi@intel.com \
    --cc=simona@ffwll.ch \
    --cc=skolothumtho@nvidia.com \
    --cc=smostafa@google.com \
    --cc=svens@linux.ibm.com \
    --cc=tursulin@ursulin.net \
    --cc=virtualization@lists.linux.dev \
    --cc=vneethv@linux.ibm.com \
    --cc=yishaih@nvidia.com \
    --cc=zhenyuw.linux@gmail.com \
    --cc=zhi.wang.linux@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.