Linux PCI subsystem development
 help / color / mirror / Atom feed
* [PATCH v5 0/2] vfio/nova-vgpu: add the NVIDIA VFIO variant driver
@ 2026-12-04 14:48 Simon Song
  2026-12-04 14:48 ` [PATCH v5 1/2] gpu: nova-core: publish typed SR-IOV PF APIs Simon Song
  2026-12-04 14:48 ` [PATCH v5 2/2] vfio/nova-vgpu: add the Rust VFIO variant driver Simon Song
  0 siblings, 2 replies; 6+ messages in thread
From: Simon Song @ 2026-12-04 14:48 UTC (permalink / raw)
  To: dakr, acourbot, kvm, rust-for-linux, nova-gpu, linux-pci
  Cc: Simon Song, alex, jgg, yishaih, skolothumtho, kevin.tian, airlied,
	simona, ojeda, alex.gaynor, boqun.feng, gary, bjorn3_gh, lossin,
	a.hindborg, aliceryhl, tmgross, jhubbard, ecourtney, cjia, smitra,
	kjaju, alkumar, ankita, aniketa, kwankhede, targupta,
	linux-kernel, zhiwang, zhiw, boqun, daniel.almeida, tamird, work,
	jgg, bhelgaas, kwilczynski, dri-devel, peter, Liam R. Howlett,
	linux-mm, Lorenzo Stoakes

This is v5 of the NVIDIA VFIO variant driver. Up to v4 these two patches
were patches 4 and 5 of "Rust VFIO PCI support and NVIDIA vGPU driver"
[1]. That series is now split in two. The first four patches, the Rust
VFIO PCI abstractions, are posted as [2]. This series carries the
driver and depends on [2].

Patch 1 publishes nova-core's typed SR-IOV PF interface. Patch 2 adds
the VFIO variant driver, which uses that interface to create, reset and
release vGPU instances while VFIO provides userspace access to the PCI
device.

This series depends on:
- v5 of the Rust VFIO PCI abstractions [2], and
- v6 of the vGPU manager series [3].

A branch with both and this series on top is at [4]. To bring up a vGPU,
userspace also has to assign a vGPU type to the VF. The tools do that
through nova-core's fwctl interface [5], which is not part of that
branch.

Changes since v4 [1]:
- Split from the Rust VFIO PCI abstractions [2] (Gary, Danilo).
- Patch 1 (v4 patch 4): rebase onto v6 of the vGPU manager series [3].
- Patch 2 (v4 patch 5):
  - Reset the vGPU instance in reset_prepare() again, before the PCI
    reset, as in v3. A VF FLR alone does not release the guest's
    resources in the firmware. Only the PF driver can request that, and
    the reason is documented at the call (Alex).
  - Refuse VFIO_DEVICE_IOEVENTFD for a vGPU, since the VFIO PCI core
    would write to the BAR without the BAR1 limit.
  - Use UserSlice for the config space read and write overrides (Gary,
    Danilo).
  - Use the RegionInfo accessors in get_region_info() (Gary).
  - Follow the abstraction changes: Registration::new() without the
    driver type, and the renamed lifetimes.

v4 patches 4 and 5 are now patches 1 and 2.

[1] https://lore.kernel.org/r/20261127224928.1511382-1-xinmengs@nvidia.com
[2] https://lore.kernel.org/all/20261204041727.4021092-1-xinmengs@nvidia.com/
[3] https://lore.kernel.org/all/cover.1796191007.git.alkumar@nvidia.com/
[4] https://github.com/xinmengsong/linux/tree/nova-vgpu-vfio-v5
[5] https://lore.kernel.org/all/cover.1796197508.git.alkumar@nvidia.com/

Danilo Krummrich (1):
  vfio/nova-vgpu: add the Rust VFIO variant driver

Zhi Wang (1):
  gpu: nova-core: publish typed SR-IOV PF APIs

 drivers/gpu/Makefile                    |  15 +-
 drivers/gpu/nova-core/driver.rs         |  34 +-
 drivers/gpu/nova-core/nova_core.rs      |   3 +-
 drivers/gpu/nova-core/vgpu.rs           |   1 -
 drivers/gpu/nova-core/vgpu/vgpu_api.rs  | 171 ++++++--
 drivers/vfio/pci/Kconfig                |   2 +
 drivers/vfio/pci/Makefile               |   2 +
 drivers/vfio/pci/nova-vgpu/Kconfig      |  20 +
 drivers/vfio/pci/nova-vgpu/Makefile     |   3 +
 drivers/vfio/pci/nova-vgpu/nova_vgpu.rs | 522 ++++++++++++++++++++++++
 rust/bindings/bindings_helper.h         |   1 +
 rust/kernel/vfio.rs                     |   3 +
 12 files changed, 732 insertions(+), 45 deletions(-)
 create mode 100644 drivers/vfio/pci/nova-vgpu/Kconfig
 create mode 100644 drivers/vfio/pci/nova-vgpu/Makefile
 create mode 100644 drivers/vfio/pci/nova-vgpu/nova_vgpu.rs


base-commit: 1b2c8b267ff3c9a8c83b7524debc637de02ee32b
prerequisite-patch-id: 6cfd7afd456e2122926d365321b00321036b9f2e
prerequisite-patch-id: 9228595f76dde48297670da5be99228c11fd917b
prerequisite-patch-id: 36f4f21082a9b20f5c75ce2e1a6fcaca39e2c1bf
prerequisite-patch-id: 3aa22f5e6eb0d188b6dc00bea385f1bc07aed2d6
prerequisite-patch-id: 741e15ad117e9018d6c568904cafe98e4f407acb
prerequisite-patch-id: 88d67b250d7c1b36afa23062ed3a712952e53490
prerequisite-patch-id: e8c13a777d612873aef5f8528b8360203981c3b3
prerequisite-patch-id: ca19c76a3af38d83a09e2b838225d5d22f3a58b1
prerequisite-patch-id: 4af23dd1b6074197be42ae98dbfb1214d020f5e5
prerequisite-patch-id: aa564955d07ecf6328d589ef175050933f12229d
prerequisite-patch-id: 2d77cbed5133696f05afffe0bbdf3cd2aeab9c30
prerequisite-patch-id: 7891b8799b904e8c587f7f68e5392ba936516d17
prerequisite-patch-id: 6e0a59e846fbb633b473c9b7e3c171ad859319d9
prerequisite-patch-id: dd31a51c79b2ee7a1870b3c5009f9fbe6e7b1d3d
prerequisite-patch-id: a45ddea8f025622742b378c3c5573498e66f39da
prerequisite-patch-id: 0cd47cf0b17fb9affc0099f7855d80c830c39e58
prerequisite-patch-id: 8bfda508149f5d50067673061fcd9987474a257f
prerequisite-patch-id: 9384489c5d19741b1cee28cb071f8f716fb0dc4f
prerequisite-patch-id: f29998e45c8372cc908d5237228f91d42c3e43ea
prerequisite-patch-id: b481e232431cb851412ffdf6a9b7a44f47bc29af
prerequisite-patch-id: 4be056b9e82b70bfece963bfd086581fb401dbcd
prerequisite-patch-id: 0b230677e51e12e58490d73225dcb713bc44a478
prerequisite-patch-id: a16a85dbc2894235193a72d59b259d2238bdb913
prerequisite-patch-id: 3f9088001ef25ffe240614642c41ad45a0624e99
prerequisite-patch-id: 7a489f3ec55dd259bc0fa65ae9d1b57189535b10
prerequisite-patch-id: 39d0211450a65d96a1db21b23ff99844ae318bb7
prerequisite-patch-id: 7b1390f798f69d262456afb050819bd446523b09
prerequisite-patch-id: 077ec934d669d3dd79a72e7b28f42304c0c54663
prerequisite-patch-id: ba4b3d4d72646658b5ce430b5c4e63ee5b048fcc
prerequisite-patch-id: 9844732646e998f81007b05b7d7e25cc628550eb
prerequisite-patch-id: 03a53e966692f58650e15b62ce0ba3be28333359
prerequisite-patch-id: 645d0c28e5ca61d1b6b0241508b933069d0368bb
prerequisite-patch-id: bf5955cc50e5ba2969f603ac580c82164c6d1f61
prerequisite-patch-id: e5d4407b295817aa64be5de87ec299be6f9be04d
prerequisite-patch-id: 48490c862395458dd1004abf6e9c2ceefca9236b
prerequisite-patch-id: b317b0f2b8520334b041b50bcac0d8b69673d834
prerequisite-patch-id: 35094e8dce6326b76dd43d54aef361ba58a32023
prerequisite-patch-id: 1fe49043278361d3c07b196b4bd3229aa6aa7537
-- 
2.43.7


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-12-04 23:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-12-04 14:48 [PATCH v5 0/2] vfio/nova-vgpu: add the NVIDIA VFIO variant driver Simon Song
2026-12-04 14:48 ` [PATCH v5 1/2] gpu: nova-core: publish typed SR-IOV PF APIs Simon Song
2026-12-04 14:48 ` [PATCH v5 2/2] vfio/nova-vgpu: add the Rust VFIO variant driver Simon Song
2026-12-04 23:12   ` Alex Williamson
2026-12-04 23:28     ` Danilo Krummrich
2026-12-04 23:37       ` Alex Williamson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox