diff options
| author | Danilo Krummrich <dakr@kernel.org> | 2024-12-19 18:04:13 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-12-20 17:21:04 +0100 |
| commit | 685376d18e9ae2f08ab6ac36285dc3a949c8cb77 (patch) | |
| tree | 37ff04dfc900d2babec8d8771423d46dfa693bf4 /samples/rust/Kconfig | |
| parent | bf9651f84b4e49ca006fd8b5534f16a38dae875c (diff) | |
samples: rust: add Rust PCI sample driver
This commit adds a sample Rust PCI driver for QEMU's "pci-testdev"
device. To enable this device QEMU has to be called with
`-device pci-testdev`.
The same driver shows how to use the PCI device / driver abstractions,
as well as how to request and map PCI BARs, including a short sequence of
MMIO operations.
Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Tested-by: Dirk Behme <dirk.behme@de.bosch.com>
Link: https://lore.kernel.org/r/20241219170425.12036-12-dakr@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'samples/rust/Kconfig')
| -rw-r--r-- | samples/rust/Kconfig | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/samples/rust/Kconfig b/samples/rust/Kconfig index df384e679901..002af98e70be 100644 --- a/samples/rust/Kconfig +++ b/samples/rust/Kconfig @@ -40,6 +40,17 @@ config SAMPLE_RUST_PRINT If unsure, say N. +config SAMPLE_RUST_DRIVER_PCI + tristate "PCI Driver" + depends on PCI + help + This option builds the Rust PCI driver sample. + + To compile this as a module, choose M here: + the module will be called driver_pci. + + If unsure, say N. + config SAMPLE_RUST_HOSTPROGS bool "Host programs" help |
