qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Farhan Ali <alifm@linux.ibm.com>
To: qemu-devel@nongnu.org
Cc: alifm@linux.ibm.com, mjrosato@linux.ibm.com,
	schnelle@linux.ibm.com, qemu-s390x@nongnu.org,
	qemu-block@nongnu.org, stefanha@redhat.com, fam@euphon.net,
	philmd@linaro.org, kwolf@redhat.com, hreitz@redhat.com,
	thuth@redhat.com
Subject: [PATCH v1 0/2] Enable QEMU NVMe userspace driver on s390x
Date: Wed, 26 Mar 2025 11:10:05 -0700	[thread overview]
Message-ID: <20250326181007.1099-1-alifm@linux.ibm.com> (raw)

Hi,

Recently on s390x we have enabled mmap support for vfio-pci devices [1].
This allows us to take advantage and use userspace drivers on s390x. However,
on s390x we have special instructions for MMIO access. Starting with z15 
(and newer platforms) we have new PCI Memory I/O (MIO) instructions which 
operate on virtually mapped PCI memory spaces, and can be used from userspace.
On older platforms we would fallback to using existing system calls for MMIO access.

This patch series introduces support the PCI MIO instructions, and enables s390x
support for the userspace NVMe driver on s390x. I would appreciate any review/feedback
on the patches.

Thanks
Farhan

[1] https://lore.kernel.org/linux-s390/20250226-vfio_pci_mmap-v7-0-c5c0f1d26efd@linux.ibm.com/

Farhan Ali (2):
  util: Add functions for s390x mmio read/write
  block/nvme: Enable NVMe userspace driver for s390x

 block/nvme.c                  |  95 ++++++++++++++++++++++++------
 include/qemu/s390x_pci_mmio.h |  17 ++++++
 util/meson.build              |   2 +
 util/s390x_pci_mmio.c         | 105 ++++++++++++++++++++++++++++++++++
 4 files changed, 201 insertions(+), 18 deletions(-)
 create mode 100644 include/qemu/s390x_pci_mmio.h
 create mode 100644 util/s390x_pci_mmio.c

-- 
2.43.0



             reply	other threads:[~2025-03-26 18:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-26 18:10 Farhan Ali [this message]
2025-03-26 18:10 ` [PATCH v1 1/2] util: Add functions for s390x mmio read/write Farhan Ali
2025-03-27 19:20   ` Stefan Hajnoczi
2025-03-27 19:53     ` Farhan Ali
2025-03-26 18:10 ` [PATCH v1 2/2] block/nvme: Enable NVMe userspace driver for s390x Farhan Ali
2025-03-27 19:26   ` Stefan Hajnoczi
2025-03-27 19:49     ` Farhan Ali

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=20250326181007.1099-1-alifm@linux.ibm.com \
    --to=alifm@linux.ibm.com \
    --cc=fam@euphon.net \
    --cc=hreitz@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mjrosato@linux.ibm.com \
    --cc=philmd@linaro.org \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-s390x@nongnu.org \
    --cc=schnelle@linux.ibm.com \
    --cc=stefanha@redhat.com \
    --cc=thuth@redhat.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;
as well as URLs for NNTP newsgroup(s).