selftests/vfio: Add NVIDIA GPU Falcon DMA test driver
Subsystems (4)
v10 cover selftests/vfio: Add NVIDIA GPU Falcon DMA test driver
Patch 1:
Add VFIO_PCI_DRIVER_F_NO_SEND_MSI feature flag for drivers that cannot trigger MSI interrupts. Drivers that lack MSI support opt-in by setting this flag.
Change vfio_pci_driver_send_msi() to return int, checking the flag internally and returning -EOPNOTSUPP when set. Add fcntl_set_msi_nonblock(self) and update ASSERT_NO_MSI(self) to check the flag internally.
Patch 2:
Falcons are general-purpose microcontrollers present on NVIDIA GPUs that can perform DMA operations between system memory and device memory.
Introduce the nv_falcon plugin driver, which extracts and adapts relevant functionality from NVIDIA's gpu-admin-tools project [1] and integrates it into the VFIO selftest framework. As a result, any system equipped with a PCIe slot and a supported NVIDIA GPU can now run VFIO DMA selftests using commonly available hardware.
The core VFIO selftest infrastructure handles:
- VFIO container/group management
- IOMMU domain setup
- DMA buffer allocation and mapping
- Test orchestration and reporting
The plugin drivers provide device-specific implementations for:
- Probing and initializing device
- Triggering DMA operations
- Verifying DMA completion
- Device cleanup
[1] https://github.com/NVIDIA/gpu-admin-tools
Note on version numbering: v1 through v9 were internal review iterations that were mistakenly carried over to the upstream submission. Apologies for the confusion, the internal changelog has been dropped.
Changes in v10:
- Replaced NULL pointer checks on send_msi() with per-device VFIO_PCI_DRIVER_F_NO_SEND_MSI feature flag
- Changed vfio_pci_driver_send_msi() to return int with the feature check moved inside, so callers branch on the return value
- Added fcntl_set_msi_nonblock(self) and updated ASSERT_NO_MSI(self) macros that check the flag internally
- Moved DMA execution from memcpy_start() to memcpy_wait() so that memcpy_start() stores parameters and returns immediately, emulating async behavior to conform to the memcpy_start()/memcpy_wait() contract
- Split GPU_ARCH_PASCAL into GPU_ARCH_PASCAL (P100, PMC reset) and GPU_ARCH_PASCAL_10X (P4/P40, engine reset) to match per-product reset behavior
- Minor cleanups: improved size_to_dma_encoding(), fixed DMA address bits mask
Rubin Du (2):
selftests/vfio: Add NO_SEND_MSI feature flag and MSI helper macros selftests/vfio: Add NVIDIA Falcon driver for DMA testing
.../vfio/lib/drivers/nv_falcons/hw.h | 365 +++++++++ .../vfio/lib/drivers/nv_falcons/nv_falcons.c | 739 ++++++++++++++++++ .../lib/include/libvfio/vfio_pci_driver.h | 5 +- tools/testing/selftests/vfio/lib/libvfio.mk | 2 + .../selftests/vfio/lib/vfio_pci_driver.c | 9 +- .../selftests/vfio/vfio_pci_driver_test.c | 41 +- 6 files changed, 1142 insertions(+), 19 deletions(-) create mode 100644 tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h create mode 100644 tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c
Signature · 1 line
2.43.0
PATCH v10 1/2 selftests/vfio: Add NO_SEND_MSI feature flag and MSI helper macros
Add a features bitmask to struct vfio_pci_driver and define VFIO_PCI_DRIVER_F_NO_SEND_MSI for drivers that cannot trigger MSI interrupts via send_msi(). Drivers that lack MSI support opt-in by setting this flag in their init() callback.
Change vfio_pci_driver_send_msi() to return int, checking the flag internally and returning -EOPNOTSUPP when set.
Add fcntl_set_msi_nonblock(self) and update ASSERT_NO_MSI(self) to check the flag internally.
--- .../lib/include/libvfio/vfio_pci_driver.h | 5 ++- .../selftests/vfio/lib/vfio_pci_driver.c | 6 ++- .../selftests/vfio/vfio_pci_driver_test.c | 41 +++++++++++-------- 3 files changed, 33 insertions(+), 19 deletions(-)
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h +4 -1
@@ -6,6 +6,8 @@struct vfio_pci_device ; +#define VFIO_PCI_DRIVER_F_NO_SEND_MSI (1UL << 0)/* Device cannot trigger MSI */ +struct vfio_pci_driver_ops {const char *name;
@@ -69,6 +71,7 @@ struct vfio_pci_driver {const struct vfio_pci_driver_ops *ops;bool initialized;bool memcpy_in_progress; +unsigned long features;/* Region to be used by the driver (e.g. for in-memory descriptors) */ struct dma_region region;
@@ -92,6 +95,6 @@ void vfio_pci_driver_memcpy_start(struct vfio_pci_device *device, iova_t src, iova_t dst, u64 size, u64 count);int vfio_pci_driver_memcpy_wait (struct vfio_pci_device *device); -void vfio_pci_driver_send_msi (struct vfio_pci_device *device); +int vfio_pci_driver_send_msi (struct vfio_pci_device *device);#endif /* SELFTESTS_VFIO_LIB_INCLUDE_LIBVFIO_VFIO_PCI_DRIVER_H */
tools/testing/selftests/vfio/lib/vfio_pci_driver.c +5 -1
@@ -67,13 +67,17 @@ void vfio_pci_driver_remove(struct vfio_pci_device *device) driver->initialized = false; } -void vfio_pci_driver_send_msi (struct vfio_pci_device *device) +int vfio_pci_driver_send_msi (struct vfio_pci_device *device) {struct vfio_pci_driver *driver = &device->driver; +if (driver->features &VFIO_PCI_DRIVER_F_NO_SEND_MSI ) +return -EOPNOTSUPP ; +VFIO_CHECK_DRIVER_OP (driver, send_msi); driver->ops->send_msi (device); +return 0 ; } void vfio_pci_driver_memcpy_start(struct vfio_pci_device *device,
tools/testing/selftests/vfio/vfio_pci_driver_test.c +24 -17
103 lines not on this page · raw message
Signature · 1 line
2.43.0
David Matlack
maintainerRe: [PATCH v10 1/2] selftests/vfio: Add NO_SEND_MSI feature flag and MSI helper macros
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h line 9
Quoted 9 lines · Rubin Du
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h +1
-0@@ -6,6 +6,8 @@struct vfio_pci_device ; +#define VFIO_PCI_DRIVER_F_NO_SEND_MSI (1UL << 0)/* Device cannot trigger MSI */
I don't see any particular reason to add this flag. All of the checks for...
device->driver.feature & VFIO_PCI_DRIVER_F_NO_SEND_MSI
can just be rewritten as...
!device->driver.ops->send_msi
to accomplish the same thing. And the latter is less characters while still being readable.
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h
Quoted 8 lines
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h +4
-1-void vfio_pci_driver_send_msi (struct vfio_pci_device *device) +int vfio_pci_driver_send_msi (struct vfio_pci_device *device) {struct vfio_pci_driver *driver = &device->driver; +if (driver->features &VFIO_PCI_DRIVER_F_NO_SEND_MSI ) +return -EOPNOTSUPP ; +
I think it would be better to just let vfio_pci_driver_send_msi() fail if send_msi() is NULL.
Tests should not be calling vfio_pci_driver_send_msi() if the driver does not support send_msi(). Tests that require send_msi() should explicitly check for it, rather than detect it by trying to send an MSI.
It's also more readable to explicitly check for send_msi() support rather than silently skipping or exiting if send_msi() returns an error. The latter reads like it could be due to some problem on the device, rather than just a lack of support in the driver.
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h
Quoted 9 lines
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h +4
-5-#define ASSERT_NO_MSI (_eventfd) do { \ - u64 __value; \ - \ - ASSERT_EQ(-1, read(_eventfd, &__value, 8)); \ - ASSERT_EQ(EAGAIN, errno); \ +#define fcntl_set_msi_nonblock (_self) do { \ + if (!(_self->device->driver.features & VFIO_PCI_DRIVER_F_NO_SEND_MSI)) \ + fcntl_set_nonblock(_self->msi_fd); \ +} while (0)
I think it may be worthwhile to have the nv_falcon driver still enable at least one MSI or MSI-x vector on the device and set driver->msi. This will reduce divergence from other drivers, and simplify this commit down to just:
tools/testing/selftests/vfio/vfio_pci_driver_test.c +6 -0
@@ -175,6 +175,9 @@ TEST_F(vfio_pci_driver_test, send_msi) {u64 value; +if (!self->device->driver.ops->send_msi) +SKIP (return,"Driver does not support send_msi()" ); +vfio_pci_driver_send_msi (self->device);ASSERT_EQ (8 ,read (self->msi_fd, &value,8 ));ASSERT_EQ (1 , value);
@@ -201,6 +204,9 @@ TEST_F(vfio_pci_driver_test, mix_and_match) self->dst_iova, self->size); +if (!self->device->driver.ops->send_msi) +continue ; +vfio_pci_driver_send_msi (self->device);ASSERT_EQ (8 ,read (self->msi_fd, &value,8 ));ASSERT_EQ (1 , value);
tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h
Quoted 7 lines
TEST_F(vfio_pci_driver_test, send_msi)
{tools/testing/selftests/vfio/lib/include/libvfio/vfio_pci_driver.h +2
-1u64 value; -vfio_pci_driver_send_msi (self->device); +if (vfio_pci_driver_send_msi (self->device)) +SKIP (return,"Device does not support MSI\n" );
NV GPUs do support MSI/x though, right? This should probably be:
SKIP(return, "Driver does not support send_msi()\n");
Re: [PATCH v10 1/2] selftests/vfio: Add NO_SEND_MSI feature flag and MSI helper macros
Quoted 2 lines · David Matlack
I think it may be worthwhile to have the
nv_falcondriver still enable at least one MSI or MSI-x vector on the device and setdriver->msi.
Enabling MSI/MSI-x on the GPU would require bringing up additional GPU components beyond the Falcon microcontroller. I'd prefer to keep the driver minimal and avoid pulling in complexity that isn't related to exercising the DMA path.
Rubin Du
PATCH v10 2/2 selftests/vfio: Add NVIDIA Falcon driver for DMA testing
In reply to Rubin DuAdd a new VFIO PCI driver for NVIDIA GPUs that enables DMA testing via the Falcon (Fast Logic Controller) microcontrollers. This driver extracts and adapts the DMA test functionality from NVIDIA's gpu-admin-tools project and integrates it into the existing VFIO selftest framework.
Falcons are general-purpose microcontrollers present on NVIDIA GPUs that can perform DMA operations between system memory and device memory. By leveraging Falcon DMA, this driver allows NVIDIA GPUs to be tested alongside Intel IOAT and DSA devices using the same selftest infrastructure.
Supported GPUs:
- Kepler: K520, GTX660, K4000, K80, GT635
- Maxwell Gen1: GTX750, GTX745
- Maxwell Gen2: M60
- Pascal: P100, P4, P40
- Volta: V100
- Turing: T4
- Ampere: A16, A100, A10
- Ada: L4, L40S
- Hopper: H100
The PMU falcon on Kepler and Maxwell Gen1 GPUs uses legacy FBIF register offsets and requires enabling via PMC_ENABLE with the HUB bit set.
Limitations and tradeoffs:
1. Architecture support:
Blackwell and newer architectures may require additional work due to firmware.
2. DMA operations:
The Falcon DMA engine can only process one transfer at a time, with a maximum of 256 bytes per transfer. Since the hardware cannot perform truly asynchronous DMA, the driver emulates async
behavior: memcpy_start() stores the request parameters and returns immediately; memcpy_wait() performs the actual DMA in 256-byte chunks.
The driver is named 'nv_falcon' to reflect that it specifically controls the Falcon microcontrollers for DMA operations, rather than exposing general GPU functionality.
Reference implementation:
https://github.com/NVIDIA/gpu-admin-tools
--- .../vfio/lib/drivers/nv_falcons/hw.h | 365 +++++++++ .../vfio/lib/drivers/nv_falcons/nv_falcons.c | 739 ++++++++++++++++++ tools/testing/selftests/vfio/lib/libvfio.mk | 2 + .../selftests/vfio/lib/vfio_pci_driver.c | 3 + 4 files changed, 1109 insertions(+) create mode 100644 tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h create mode 100644 tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h new file +365 -0
@@ -0,0 +1,365 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* +* Copyright (c) 2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +*/ +#ifndef _NV_FALCONS_HW_H_ +#define _NV_FALCONS_HW_H_ + +/* PMC (Power Management Controller) Registers */ +#define NV_PMC_BOOT_0 0x00000000 +#define NV_PMC_ENABLE 0x00000200 +#define NV_PMC_ENABLE_PWR 0x00002000 +#define NV_PMC_ENABLE_HUB 0x20000000 + +/* Falcon Base Pages for Different Engines */ +#define NV_PPWR_FALCON_BASE 0x10a000 +#define NV_PGSP_FALCON_BASE 0x110000 + +/* Falcon Common Register Offsets (relative to base_page) */ +#define NV_FALCON_DMACTL_OFFSET 0x010c +#define NV_FALCON_CPUCTL_OFFSET 0x0100 +#define NV_FALCON_ENGINE_RESET_OFFSET 0x03c0 + +/* DMEM Control Register Flags */ +#define NV_PPWR_FALCON_DMEMC_AINCR_TRUE 0x01000000 +#define NV_PPWR_FALCON_DMEMC_AINCW_TRUE 0x02000000 + +/* Falcon DMEM port offsets (for port 0) */ +#define NV_FALCON_DMEMC_OFFSET 0x1c0 +#define NV_FALCON_DMEMD_OFFSET 0x1c4 + +/* DMA Register Offsets (relative to base_page) */ +#define NV_FALCON_DMA_ADDR_LOW_OFFSET 0x110 +#define NV_FALCON_DMA_MEM_OFFSET 0x114 +#define NV_FALCON_DMA_CMD_OFFSET 0x118 +#define NV_FALCON_DMA_BLOCK_OFFSET 0x11c +#define NV_FALCON_DMA_ADDR_HIGH_OFFSET 0x128 + +/* DMA Global Address Top Bits Register */ +#define NV_GPU_DMA_ADDR_TOP_BITS_REG 0x100f04 + +/* DMA Command Register Bit Definitions */ +#define NV_FALCON_DMA_CMD_WRITE_BIT 0x20 +#define NV_FALCON_DMA_CMD_SIZE_SHIFT 8 +#define NV_FALCON_DMA_CMD_DONE_BIT 0x2 + +/* +* Falcon DMA is synchronous, so a transfer size and count larger than +* its per-operation maximum adds no value. +*/ + +/* DMA block size and alignment */ +#define NV_FALCON_DMA_MAX_TRANSFER_SIZE 256 +#define NV_FALCON_DMA_MAX_TRANSFER_COUNT 1 + +/* DMACTL register bits */ +#define NV_FALCON_DMACTL_DMEM_SCRUBBING 0x1 +#define NV_FALCON_DMACTL_READY_MASK 0x6 + +/* Falcon Core Selection Register */ +#define NV_FALCON_CORE_SELECT_OFFSET 0x1668 +#define NV_FALCON_CORE_SELECT_MASK 0x30 + +/* Falcon mailbox register (for Ada+ reset check) */ +#define NV_FALCON_MAILBOX_TEST_OFFSET 0x40c +#define NV_FALCON_MAILBOX_RESET_MAGIC 0xbadf5620 + +/* Falcon Message Queue Register Offsets (relative to base_page) */ +#define NV_FALCON_QUEUE_HEAD_BASE_OFFSET 0x2c00 +#define NV_FALCON_QUEUE_TAIL_BASE_OFFSET 0x2c04 +#define NV_FALCON_QUEUE_STRIDE 0x8 +#define NV_FALCON_MSG_QUEUE_HEAD_BASE_OFFSET 0x2c80 +#define NV_FALCON_MSG_QUEUE_TAIL_BASE_OFFSET 0x2c84 + +/* FSP Falcon Base Pages */ +#define NV_FSP_FALCON_BASE 0x8f0100 +/* base_page = cpuctl & ~0xfff */ +#define NV_FSP_FALCON_BASE_PAGE 0x8f0000 +#define NV_FSP_EMEM_BASE 0x8f2000 + +/* FSP EMEM Port Offsets (relative to FSP EMEM base) */ +#define NV_FSP_EMEMC_OFFSET 0xac0 +#define NV_FSP_EMEMD_OFFSET 0xac4 +#define NV_FSP_EMEM_PORT_STRIDE 0x8 + +/* EMEM Control Register Flags (same as DMEM) */ +#define NV_FALCON_EMEMC_AINCR 0x01000000 +#define NV_FALCON_EMEMC_AINCW 0x02000000 + +/* FSP RPC channel configuration */ +#define NV_FSP_RPC_CHANNEL_SIZE 1024 +#define NV_FSP_RPC_MAX_PACKET_SIZE 1024 +#define NV_FSP_RPC_CHANNEL_HOPPER 2 +#define NV_FSP_RPC_EMEM_BASE \ + (NV_FSP_RPC_CHANNEL_HOPPER * NV_FSP_RPC_CHANNEL_SIZE) + +/* FSP EMEM port 2 registers (pre-computed for Hopper channel 2) */ +#define NV_FSP_EMEM_PORT2_CTRL (NV_FSP_EMEM_BASE + NV_FSP_EMEMC_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FSP_EMEM_PORT_STRIDE) +#define NV_FSP_EMEM_PORT2_DATA (NV_FSP_EMEM_BASE + NV_FSP_EMEMD_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FSP_EMEM_PORT_STRIDE) + +/* FSP queue register offsets (pre-computed for Hopper channel 2) */ +#define NV_FSP_QUEUE_HEAD \ + (NV_FSP_FALCON_BASE_PAGE + NV_FALCON_QUEUE_HEAD_BASE_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FALCON_QUEUE_STRIDE) +#define NV_FSP_QUEUE_TAIL \ + (NV_FSP_FALCON_BASE_PAGE + NV_FALCON_QUEUE_TAIL_BASE_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FALCON_QUEUE_STRIDE) +#define NV_FSP_MSG_QUEUE_HEAD \ + (NV_FSP_FALCON_BASE_PAGE + NV_FALCON_MSG_QUEUE_HEAD_BASE_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FALCON_QUEUE_STRIDE) +#define NV_FSP_MSG_QUEUE_TAIL \ + (NV_FSP_FALCON_BASE_PAGE + NV_FALCON_MSG_QUEUE_TAIL_BASE_OFFSET + \ + NV_FSP_RPC_CHANNEL_HOPPER * NV_FALCON_QUEUE_STRIDE) + +/* MCTP Header */ +#define NV_MCTP_HDR_SEID_SHIFT 16 +#define NV_MCTP_HDR_SEID_MASK 0xff +#define NV_MCTP_HDR_SEQ_SHIFT 28 +#define NV_MCTP_HDR_SEQ_MASK 0x3 +#define NV_MCTP_HDR_EOM_BIT 0x40000000 +#define NV_MCTP_HDR_SOM_BIT 0x80000000 + +/* MCTP Message Header */ +#define NV_MCTP_MSG_TYPE_SHIFT 0 +#define NV_MCTP_MSG_TYPE_MASK 0x7f +#define NV_MCTP_MSG_TYPE_VENDOR_DEFINED 0x7e +#define NV_MCTP_MSG_VENDOR_ID_SHIFT 8 +#define NV_MCTP_MSG_VENDOR_ID_MASK 0xffff +#define NV_MCTP_MSG_VENDOR_ID_NVIDIA 0x10de +#define NV_MCTP_MSG_NVDM_TYPE_SHIFT 24 +#define NV_MCTP_MSG_NVDM_TYPE_MASK 0xff + +/* NVDM response type */ +#define NV_NVDM_TYPE_RESPONSE 0x15 + +/* Minimum response size: mctp_hdr + msg_hdr + status_hdr + type + status */ +#define NV_FSP_RPC_MIN_RESPONSE_WORDS 5 + +/* FBIF (Frame Buffer Interface) Registers */ +/* Legacy PMU FBIF offsets (Kepler, Maxwell Gen1) */ +#define NV_PMU_LEGACY_FBIF_CTL_OFFSET 0x624 +#define NV_PMU_LEGACY_FBIF_TRANSCFG_OFFSET 0x600 + +/* PMU FBIF offsets */ +#define NV_PMU_FBIF_CTL_OFFSET 0xe24 +#define NV_PMU_FBIF_TRANSCFG_OFFSET 0xe00 + +/* GSP FBIF offsets */ +#define NV_GSP_FBIF_CTL_OFFSET 0x624 +#define NV_GSP_FBIF_TRANSCFG_OFFSET 0x600 + +/* OFA Falcon Base Page and FBIF offsets (used for Hopper+ DMA) */ +#define NV_OFA_FALCON_BASE 0x844000 +#define NV_OFA_FBIF_CTL_OFFSET 0x424 +#define NV_OFA_FBIF_TRANSCFG_OFFSET 0x400 + +/* OFA DMA support check register (Hopper+) */ +#define NV_OFA_DMA_SUPPORT_CHECK_REG 0x8443c0 + +/* FSP NVDM command types */ +#define NV_NVDM_TYPE_FBDMA 0x22 +#define NV_FBDMA_SUBCMD_ENABLE 0x1 + +/* FBIF CTL2 offset (relative to fbif_ctl) */ +#define NV_FBIF_CTL2_OFFSET 0x60 + +/* FBIF TRANSCFG register bits */ +#define NV_FBIF_TRANSCFG_TARGET_MASK 0x3 +#define NV_FBIF_TRANSCFG_SYSMEM_DEFAULT 0x5 + +/* FBIF CTL register bits */ +#define NV_FBIF_CTL_ALLOW_PHYS_MODE 0x10 +#define NV_FBIF_CTL_ALLOW_FULL_PHYS_MODE 0x80 + +/* Memory clear register offsets */ +#define NV_MEM_CLEAR_OFFSET 0x100b20 +#define NV_BOOT_COMPLETE_OFFSET 0x118234 +#define NV_BOOT_COMPLETE_MASK 0x3ff + +/* FSP boot complete register (Hopper+) */ +#define NV_FSP_BOOT_COMPLETE_OFFSET 0x200bc +#define NV_FSP_BOOT_COMPLETE_MASK 0xff + +enum gpu_arch { +GPU_ARCH_UNKNOWN =-1 , +GPU_ARCH_KEPLER =0 , +GPU_ARCH_MAXWELL_GEN1 , +GPU_ARCH_MAXWELL_GEN2 , +GPU_ARCH_PASCAL , +GPU_ARCH_PASCAL_10X , +GPU_ARCH_VOLTA , +GPU_ARCH_TURING , +GPU_ARCH_AMPERE , +GPU_ARCH_ADA , +GPU_ARCH_HOPPER , +}; + +enum falcon_type { +FALCON_TYPE_PMU_LEGACY =0 , +FALCON_TYPE_PMU , +FALCON_TYPE_GSP , +FALCON_TYPE_OFA , +}; + +struct falcon { +u32 base_page; +u32 dmactl; +u32 engine_reset; +u32 fbif_ctl; +u32 fbif_ctl2; +u32 fbif_transcfg; +u32 dmem_control_reg; +u32 dmem_data_reg; +bool no_outside_reset; +}; + +struct gpu_properties { +u32 pmc_enable_mask; +bool memory_clear_supported; +enum falcon_type falcon_type; +}; + +struct gpu_device { +enum gpu_arch arch; +void *bar0; +bool is_memory_clear_supported; +const struct falcon *falcon; +u32 pmc_enable_mask; +bool fsp_dma_enabled; + +/* Pending memcpy parameters, set by memcpy_start() */ +u64 memcpy_src; +u64 memcpy_dst; +u64 memcpy_size; +u64 memcpy_count; +}; + +static const u32 verified_gpu_map[] = { +0x0e40a0a2 ,/* K520 */ +0x0e6000a1 ,/* GTX660 */ +0x0e63a0a1 ,/* K4000 */ +0x0f22d0a1 ,/* K80 */ +0x108000a1 ,/* GT635 */ +0x117010a2 ,/* GTX750 */ +0x117020a2 ,/* GTX745 */ +0x124320a1 ,/* M60 */ +0x130000a1 ,/* P100 */ +0x134000a1 ,/* P4 */ +0x132000a1 ,/* P40 */ +0x140000a1 ,/* V100 */ +0x164000a1 ,/* T4 */ +0xb77000a1 ,/* A16 */ +0x170000a1 ,/* A100 */ +0xb72000a1 ,/* A10 */ +0x180000a1 ,/* H100 */ +0x194000a1 ,/* L4 */ +0x192000a1 ,/* L40S */ +}; + +#define VERIFIED_GPU_MAP_SIZE ARRAY_SIZE(verified_gpu_map) + +static const struct gpu_properties gpu_properties_map[] = { + [GPU_ARCH_KEPLER ] = { + .pmc_enable_mask =NV_PMC_ENABLE_PWR |NV_PMC_ENABLE_HUB , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_PMU_LEGACY , + }, + [GPU_ARCH_MAXWELL_GEN1 ] = { + .pmc_enable_mask =NV_PMC_ENABLE_PWR |NV_PMC_ENABLE_HUB , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_PMU_LEGACY , + }, + [GPU_ARCH_MAXWELL_GEN2 ] = { + .pmc_enable_mask =NV_PMC_ENABLE_PWR , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_PMU , + }, + [GPU_ARCH_PASCAL ] = { + .pmc_enable_mask =NV_PMC_ENABLE_PWR , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_PMU , + }, + [GPU_ARCH_PASCAL_10X ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_PMU , + }, + [GPU_ARCH_VOLTA ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = false, + .falcon_type =FALCON_TYPE_GSP , + }, + [GPU_ARCH_TURING ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = true, + .falcon_type =FALCON_TYPE_GSP , + }, + [GPU_ARCH_AMPERE ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = true, + .falcon_type =FALCON_TYPE_GSP , + }, + [GPU_ARCH_ADA ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = true, + .falcon_type =FALCON_TYPE_PMU , + }, + [GPU_ARCH_HOPPER ] = { + .pmc_enable_mask =0 , + .memory_clear_supported = true, + .falcon_type =FALCON_TYPE_OFA , + }, +}; + +static const struct falcon falcon_map[] = { + [FALCON_TYPE_PMU_LEGACY ] = { + .base_page =NV_PPWR_FALCON_BASE , + .dmactl =NV_PPWR_FALCON_BASE +NV_FALCON_DMACTL_OFFSET , + .engine_reset =NV_PPWR_FALCON_BASE +NV_FALCON_ENGINE_RESET_OFFSET , + .fbif_ctl =NV_PPWR_FALCON_BASE +NV_PMU_LEGACY_FBIF_CTL_OFFSET , + .fbif_ctl2 =NV_PPWR_FALCON_BASE + +NV_PMU_LEGACY_FBIF_CTL_OFFSET +NV_FBIF_CTL2_OFFSET , + .fbif_transcfg =NV_PPWR_FALCON_BASE +NV_PMU_LEGACY_FBIF_TRANSCFG_OFFSET , + .dmem_control_reg =NV_PPWR_FALCON_BASE +NV_FALCON_DMEMC_OFFSET , + .dmem_data_reg =NV_PPWR_FALCON_BASE +NV_FALCON_DMEMD_OFFSET , + .no_outside_reset = false, + }, + [FALCON_TYPE_PMU ] = { + .base_page =NV_PPWR_FALCON_BASE , + .dmactl =NV_PPWR_FALCON_BASE +NV_FALCON_DMACTL_OFFSET , + .engine_reset =NV_PPWR_FALCON_BASE +NV_FALCON_ENGINE_RESET_OFFSET , + .fbif_ctl =NV_PPWR_FALCON_BASE +NV_PMU_FBIF_CTL_OFFSET , + .fbif_ctl2 =NV_PPWR_FALCON_BASE +NV_PMU_FBIF_CTL_OFFSET +NV_FBIF_CTL2_OFFSET , + .fbif_transcfg =NV_PPWR_FALCON_BASE +NV_PMU_FBIF_TRANSCFG_OFFSET , + .dmem_control_reg =NV_PPWR_FALCON_BASE +NV_FALCON_DMEMC_OFFSET , + .dmem_data_reg =NV_PPWR_FALCON_BASE +NV_FALCON_DMEMD_OFFSET , + .no_outside_reset = false, + }, + [FALCON_TYPE_GSP ] = { + .base_page =NV_PGSP_FALCON_BASE , + .dmactl =NV_PGSP_FALCON_BASE +NV_FALCON_DMACTL_OFFSET , + .engine_reset =NV_PGSP_FALCON_BASE +NV_FALCON_ENGINE_RESET_OFFSET , + .fbif_ctl =NV_PGSP_FALCON_BASE +NV_GSP_FBIF_CTL_OFFSET , + .fbif_ctl2 =NV_PGSP_FALCON_BASE +NV_GSP_FBIF_CTL_OFFSET +NV_FBIF_CTL2_OFFSET , + .fbif_transcfg =NV_PGSP_FALCON_BASE +NV_GSP_FBIF_TRANSCFG_OFFSET , + .dmem_control_reg =NV_PGSP_FALCON_BASE +NV_FALCON_DMEMC_OFFSET , + .dmem_data_reg =NV_PGSP_FALCON_BASE +NV_FALCON_DMEMD_OFFSET , + .no_outside_reset = false, + }, + [FALCON_TYPE_OFA ] = { + .base_page =NV_OFA_FALCON_BASE , + .dmactl =NV_OFA_FALCON_BASE +NV_FALCON_DMACTL_OFFSET , + .engine_reset =NV_OFA_FALCON_BASE +NV_FALCON_ENGINE_RESET_OFFSET , + .fbif_ctl =NV_OFA_FALCON_BASE +NV_OFA_FBIF_CTL_OFFSET , + .fbif_ctl2 =NV_OFA_FALCON_BASE +NV_OFA_FBIF_CTL_OFFSET +NV_FBIF_CTL2_OFFSET , + .fbif_transcfg =NV_OFA_FALCON_BASE +NV_OFA_FBIF_TRANSCFG_OFFSET , + .dmem_control_reg =NV_OFA_FALCON_BASE +NV_FALCON_DMEMC_OFFSET , + .dmem_data_reg =NV_OFA_FALCON_BASE +NV_FALCON_DMEMD_OFFSET , + .no_outside_reset = true, + }, +}; + + +#endif /* _NV_FALCONS_HW_H_ */
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +739 -0
739 lines not on this page · raw message
tools/testing/selftests/vfio/lib/libvfio.mk +2 -0
@@ -14,6 +14,8 @@ LIBVFIO_C += drivers/ioat/ioat.c LIBVFIO_C += drivers/dsa/dsa.c endif +LIBVFIO_C += drivers/nv_falcons/nv_falcons.c + LIBVFIO_OUTPUT := $(OUTPUT)/libvfio LIBVFIO_O := $(patsubst %.c, $(LIBVFIO_OUTPUT)/%.o, $(LIBVFIO_C))
tools/testing/selftests/vfio/lib/vfio_pci_driver.c +3 -0
@@ -7,11 +7,14 @@ extern struct vfio_pci_driver_ops dsa_ops;extern struct vfio_pci_driver_ops ioat_ops;#endif +extern struct vfio_pci_driver_ops nv_falcon_ops; +static struct vfio_pci_driver_ops *driver_ops[] = { #ifdef __x86_64__ &dsa_ops, &ioat_ops, #endif + &nv_falcon_ops, };void vfio_pci_driver_probe (struct vfio_pci_device *device)
Signature · 1 line
2.43.0
David Matlack
maintainerRe: [PATCH v10 2/2] selftests/vfio: Add NVIDIA Falcon driver for DMA testing
Quoted 12 lines · Rubin Du
Add a new VFIO PCI driver for NVIDIA GPUs that enables DMA testing via the Falcon (Fast Logic Controller) microcontrollers. This driver extracts and adapts the DMA test functionality from NVIDIA's gpu-admin-tools project and integrates it into the existing VFIO selftest framework.
Falcons are general-purpose microcontrollers present on NVIDIA GPUs that can perform DMA operations between system memory and device memory. By leveraging Falcon DMA, this driver allows NVIDIA GPUs to be tested alongside Intel IOAT and DSA devices using the same selftest infrastructure.
Quoted 3 lines
The driver is named '
nv_falcon' to reflect that it specifically controls the Falcon microcontrollers for DMA operations, rather than exposing general GPU functionality.
Do you forsee this driver ever expanding to utilize other functionality on the GPU other than the Falcon microcontroller, e.g. to add send_msi() support in the future and/or support asynchronous memcpy?
If so, the name "nv_falcon" could get out of date and maybe "nv_gpu" would be a better name for this driver?
Quoted 7 lines
Reference implementation:
https://github.com/NVIDIA/gpu-admin-toolsSigned-off-by Rubin Du <[email protected]>--- .../vfio/lib/drivers/nv_falcons/hw.h | 365 +++++++++ .../vfio/lib/drivers/nv_falcons/nv_falcons.c | 739 ++++++++++++++++++
Please make the directory and file names match the driver. i.e. s/nv_falcons/nv_falcon/.
Quoted 8 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h new file +2
-0@@ -0,0 +1,365 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/*
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h line 12
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h new file +10
-0+* Copyright (c) 2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +*/ +#ifndef _NV_FALCONS_HW_H_ +#define _NV_FALCONS_HW_H_ + +/* PMC (Power Management Controller) Registers */ +#define NV_PMC_BOOT_0 0x00000000 +#define NV_PMC_ENABLE 0x00000200 +#define NV_PMC_ENABLE_PWR 0x00002000 +#define NV_PMC_ENABLE_HUB 0x20000000
Please make the alignment of macro values consistent here and below.
Quoted 29 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h new file +28
-0+ +/* Falcon Base Pages for Different Engines */ +#define NV_PPWR_FALCON_BASE 0x10a000 +#define NV_PGSP_FALCON_BASE 0x110000 + +/* Falcon Common Register Offsets (relative to base_page) */ +#define NV_FALCON_DMACTL_OFFSET 0x010c +#define NV_FALCON_CPUCTL_OFFSET 0x0100 +#define NV_FALCON_ENGINE_RESET_OFFSET 0x03c0 + +/* DMEM Control Register Flags */ +#define NV_PPWR_FALCON_DMEMC_AINCR_TRUE 0x01000000 +#define NV_PPWR_FALCON_DMEMC_AINCW_TRUE 0x02000000 + +/* Falcon DMEM port offsets (for port 0) */ +#define NV_FALCON_DMEMC_OFFSET 0x1c0 +#define NV_FALCON_DMEMD_OFFSET 0x1c4 + +/* DMA Register Offsets (relative to base_page) */ +#define NV_FALCON_DMA_ADDR_LOW_OFFSET 0x110 +#define NV_FALCON_DMA_MEM_OFFSET 0x114 +#define NV_FALCON_DMA_CMD_OFFSET 0x118 +#define NV_FALCON_DMA_BLOCK_OFFSET 0x11c +#define NV_FALCON_DMA_ADDR_HIGH_OFFSET 0x128 +struct gpu_device { +enum gpu_arch arch; +void *bar0; +bool is_memory_clear_supported;
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/hw.h new file +10
-0+const struct falcon *falcon; +u32 pmc_enable_mask; +bool fsp_dma_enabled; + +/* Pending memcpy parameters, set by memcpy_start() */ +u64 memcpy_src; +u64 memcpy_dst; +u64 memcpy_size; +u64 memcpy_count; +};
nit: I would move this to the driver .c file since that's where its used and this isn't a hardware definition. It will make the driver easier to read to have this struct definition in the same file.
Quoted 16 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0@@ -0,0 +1,739 @@ +// SPDX-License-Identifier: GPL-2.0-only +/* +* Copyright (c) 2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. +*/ +#include <stdint.h> +#include <strings.h> +#include <unistd.h> +#include <stdbool.h> +#include <string.h> +#include <time.h>
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 20
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+ +#include <linux/errno.h> +#include <linux/io.h> +#include <linux/pci_ids.h> + +#include <libvfio.h> + +#include "hw.h" + +static inline struct gpu_device *to_nv_gpu (struct vfio_pci_device *device)
nit: Please align the naming here. i.e. rename this function to to_gpu_device() or rename struct gpu_device to struct nv_gpu.
Quoted 25 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +24
-0+{ +return device->driver.region.vaddr; +} +static int gpu_poll_register (struct vfio_pci_device *device, +const char *name,u32 offset, +u32 expected,u32 mask,u32 timeout_ms) +{ +struct gpu_device *gpu =to_nv_gpu (device); +u32 value; +struct timespec start, now; +u64 elapsed_ms; + +clock_gettime (CLOCK_MONOTONIC , &start); + +for (;;) { + value =gpu_read32 (gpu, offset); +if ((value & mask) == expected) +return 0 ; + +clock_gettime (CLOCK_MONOTONIC , &now); + elapsed_ms = (now.tv_sec - start.tv_sec) *1000 + + (now.tv_nsec - start.tv_nsec) /1000000 ; + +if (elapsed_ms >= timeout_ms)
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 98
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+break ; + +usleep (1000 ); + } + +dev_err (device, +"Timeout polling %s (0x%x): value=0x%x expected=0x%x mask=0x%x after %llu ms\n" , + name, offset, value, expected, mask, + (unsigned long long )elapsed_ms); +return -ETIMEDOUT ;
Please fix all the callers of this function that ignore the return value. Presumably you should be using VFIO_ASSERT_EQ(ret, 0) to bail the test if something goes wrong (other than during memcpy_wait(), which has a way to return an error to the caller).
Quoted 5 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +5
-0+static void gpu_enable_bus_master (struct vfio_pci_device *device) +{ +u16 cmd; + + cmd =vfio_pci_config_readw (device,PCI_COMMAND );
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 356
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+vfio_pci_config_writew (device,PCI_COMMAND , cmd |PCI_COMMAND_MASTER ); +} + +static void gpu_disable_bus_master (struct vfio_pci_device *device) +{ +u16 cmd; + + cmd =vfio_pci_config_readw (device,PCI_COMMAND ); +vfio_pci_config_writew (device,PCI_COMMAND , cmd & ~PCI_COMMAND_MASTER ); +}
These can be generic to any PCI device so please add them as static inline helpers in vfio_pci_device.h for other tests to use in the future (and rename them to something more generic like vfio_pci_disable_bus_master()).
Quoted 26 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +26
-0+static int nv_gpu_falcon_dma (struct vfio_pci_device *device, +u64 address, +u32 size_encoding, +bool write) +{ +struct gpu_device *gpu =to_nv_gpu (device); +const struct falcon *falcon = gpu->falcon; +u32 dma_cmd; +int ret; + +gpu_write32 (gpu,NV_GPU_DMA_ADDR_TOP_BITS_REG , + (address >>47 ) &0x1ffff ); +gpu_write32 (gpu, falcon->base_page +NV_FALCON_DMA_ADDR_HIGH_OFFSET , + (address >>40 ) &0x7f ); +gpu_write32 (gpu, falcon->base_page +NV_FALCON_DMA_ADDR_LOW_OFFSET , + (address >>8 ) &0xffffffff ); +gpu_write32 (gpu, falcon->base_page +NV_FALCON_DMA_BLOCK_OFFSET , + address &0xff ); +gpu_write32 (gpu, falcon->base_page +NV_FALCON_DMA_MEM_OFFSET ,0 ); + + dma_cmd = (size_encoding <<NV_FALCON_DMA_CMD_SIZE_SHIFT ); + +/* Set direction: write (DMEM->mem) or read (mem->DMEM) */ +if (write) + dma_cmd |=NV_FALCON_DMA_CMD_WRITE_BIT ; +
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 559
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+gpu_write32 (gpu, falcon->base_page +NV_FALCON_DMA_CMD_OFFSET , dma_cmd); + + ret =gpu_poll_register (device,"dma_done" , + falcon->base_page +NV_FALCON_DMA_CMD_OFFSET , +NV_FALCON_DMA_CMD_DONE_BIT ,NV_FALCON_DMA_CMD_DONE_BIT , +1000 ); +if (ret) +return ret; + +return 0 ;
nit: This can just be "return ret;" or "return gpu_poll_register(...);".
Quoted 28 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +28
-0+static void nv_gpu_init (struct vfio_pci_device *device) +{ +struct gpu_device *gpu =to_nv_gpu (device); +const struct gpu_properties *props; +enum gpu_arch gpu_arch; +u32 pmc_boot_0; +int ret; + +VFIO_ASSERT_GE (device->driver.region.size,sizeof (*gpu)); + +/* Read PMC_BOOT_0 register from BAR0 to identify GPU */ + pmc_boot_0 =readl (device->bars[0 ].vaddr +NV_PMC_BOOT_0 ); + +/* Look up GPU architecture */ + gpu_arch =nv_gpu_arch_lookup (pmc_boot_0); +if (gpu_arch ==GPU_ARCH_UNKNOWN ) { +dev_err (device,"Unsupported GPU architecture\n" ); +return ; + } + + props = &gpu_properties_map[gpu_arch]; + +/* Populate GPU structure */ + gpu->arch = gpu_arch; + gpu->bar0 = device->bars[0 ].vaddr; + gpu->is_memory_clear_supported = props->memory_clear_supported; + gpu->falcon = &falcon_map[props->falcon_type]; + gpu->pmc_enable_mask = props->pmc_enable_mask;
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 665
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+ +falcon_enable (device); + +/* Initialize falcon for DMA */ + ret =nv_gpu_falcon_dma_init (device); +VFIO_ASSERT_EQ (ret,0 ,"Failed to initialize falcon DMA: %d\n" , ret); + + device->driver.features |=VFIO_PCI_DRIVER_F_NO_SEND_MSI ; + device->driver.max_memcpy_size =NV_FALCON_DMA_MAX_TRANSFER_SIZE ; + device->driver.max_memcpy_count =NV_FALCON_DMA_MAX_TRANSFER_COUNT ;
The small memcpy size is going to be a problem tests that want to DMA to larger regions. They will have to do chunk up the memcpy in a loop.
One option would be to have this driver expose a larger max_memcpy_size and implement the loop in the memcpy_start()/wait() callback, which is actually what you have below.
But I think a better approach would be to just make the loop common across all drivers so that tests never have to care about max_memcpy_size when using vfio_pci_driver_memcpy().
Can you add a precursor commit to this series that adds a loop to vfio_pci_driver_memcpy() so that it performs whatever sized memcpy the user asks for by chunking it up in to max_memcpy_size or smaller chunks? In that same commit, please update the vfio_pci_driver_test so we get coverage of the new chunking logic (get rid of the code that rounds down self->size fo max_memcpy_size, except for the memcpy_storm test).
In other words:
- vfio_pci_driver_memcpy() should allow any size memcpy and will chunk it up as necessary depending on what the driver supports.
- vfio_pci_driver_memcpy_start() semantics don't change. This still gives tests direct access to the driver memcpy_start() op and thus must obey max_memcpy_size.
This should also allow you to greatly simplify the implementation of memcpy_wait() down below.
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 701
Quoted 10 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +10
-0+static int nv_gpu_memcpy_wait (struct vfio_pci_device *device) +{ +struct gpu_device *gpu =to_nv_gpu (device); +u64 iteration; +u64 offset; +int ret; + +VFIO_ASSERT_NE (gpu->memcpy_count,0 ); + +for (iteration =0 ; iteration < gpu->memcpy_count; iteration++) {
This loop is unnecessary. You set max_memcpy_count to NV_FALCON_DMA_MAX_TRANSFER_COUNT which is 1. So vfio_pci_driver_memcpy_start() will guarantee that memcpy_count is at most 1.
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c line 708
Quoted 7 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +7
-0+ offset =0 ; + +while (offset < gpu->memcpy_size) { +int chunk_encoding; + + chunk_encoding =size_to_dma_encoding ( + gpu->memcpy_size - offset);
This loop is also unnecessary. You set max_memcpy_size to NV_FALCON_DMA_MAX_TRANSFER_SIZE, so vfio_pci_driver_memcpy_start() will guarantee memcpy_size is at most that.
Quoted 22 lines
tools/testing/selftests/vfio/lib/drivers/nv_falcons/nv_falcons.c new file +22
-0+if (chunk_encoding <0 ) { + ret = -EINVAL ; + goto out; + } + + ret =nv_gpu_memcpy_chunk (device, + gpu->memcpy_src + offset, + gpu->memcpy_dst + offset, + chunk_encoding); +if (ret) + goto out; + + offset +=0x4 << chunk_encoding; + } + } + + ret =0 ; +out: + gpu->memcpy_count =0 ; + +return ret; +}
Re: [PATCH v10 2/2] selftests/vfio: Add NVIDIA Falcon driver for DMA testing
Quoted 6 lines · David Matlack
Do you forsee this driver ever expanding to utilize other functionality on the GPU other than the Falcon microcontroller, e.g. to add
send_msi()support in the future and/or support asynchronous memcpy?If so, the name "
nv_falcon" could get out of date and maybe "nv_gpu" would be a better name for this driver?
No, I don't foresee this driver expanding beyond the Falcon microcontroller. It is not intended to be a general-purpose GPU selftest driver.
Thank you for the review. I'll address the other points in v11.
Rubin Du