| 1 |
# SPDX-License-Identifier: GPL-2.0-only |
| 2 |
config VIRTIO_ANCHOR |
| 3 |
bool |
| 4 |
|
| 5 |
config VIRTIO |
| 6 |
tristate |
| 7 |
select VIRTIO_ANCHOR |
| 8 |
help |
| 9 |
This option is selected by any driver which implements the virtio |
| 10 |
bus, such as CONFIG_VIRTIO_PCI, CONFIG_VIRTIO_MMIO, CONFIG_RPMSG |
| 11 |
or CONFIG_S390_GUEST. |
| 12 |
|
| 13 |
config VIRTIO_PCI_LIB |
| 14 |
tristate |
| 15 |
help |
| 16 |
Modern PCI device implementation. This module implements the |
| 17 |
basic probe and control for devices which are based on modern |
| 18 |
PCI device with possible vendor specific extensions. Any |
| 19 |
module that selects this module must depend on PCI. |
| 20 |
|
| 21 |
config VIRTIO_PCI_LIB_LEGACY |
| 22 |
tristate |
| 23 |
help |
| 24 |
Legacy PCI device (Virtio PCI Card 0.9.x Draft and older device) |
| 25 |
implementation. |
| 26 |
This module implements the basic probe and control for devices |
| 27 |
which are based on legacy PCI device. Any module that selects this |
| 28 |
module must depend on PCI. |
| 29 |
|
| 30 |
menuconfig VIRTIO_MENU |
| 31 |
bool "Virtio drivers" |
| 32 |
default y |
| 33 |
|
| 34 |
if VIRTIO_MENU |
| 35 |
|
| 36 |
config VIRTIO_HARDEN_NOTIFICATION |
| 37 |
bool "Harden virtio notification" |
| 38 |
depends on BROKEN |
| 39 |
help |
| 40 |
Enable this to harden the device notifications and suppress |
| 41 |
those that happen at a time where notifications are illegal. |
| 42 |
|
| 43 |
Experimental: Note that several drivers still have issues that |
| 44 |
may cause crashes or hangs when correct handling of |
| 45 |
notifications is enforced; depending on the subset of |
| 46 |
drivers and devices you use, this may or may not work. |
| 47 |
|
| 48 |
If unsure, say N. |
| 49 |
|
| 50 |
config VIRTIO_PCI |
| 51 |
tristate "PCI driver for virtio devices" |
| 52 |
depends on PCI |
| 53 |
select VIRTIO_PCI_LIB |
| 54 |
select VIRTIO |
| 55 |
help |
| 56 |
This driver provides support for virtio based paravirtual device |
| 57 |
drivers over PCI. This requires that your VMM has appropriate PCI |
| 58 |
virtio backends. Most QEMU based VMMs should support these devices |
| 59 |
(like KVM or Xen). |
| 60 |
|
| 61 |
If unsure, say M. |
| 62 |
|
| 63 |
config VIRTIO_PCI_ADMIN_LEGACY |
| 64 |
bool |
| 65 |
depends on VIRTIO_PCI && (X86 || COMPILE_TEST) |
| 66 |
default y |
| 67 |
|
| 68 |
config VIRTIO_PCI_LEGACY |
| 69 |
bool "Support for legacy virtio draft 0.9.X and older devices" |
| 70 |
default y |
| 71 |
depends on VIRTIO_PCI |
| 72 |
select VIRTIO_PCI_LIB_LEGACY |
| 73 |
help |
| 74 |
Virtio PCI Card 0.9.X Draft (circa 2014) and older device support. |
| 75 |
|
| 76 |
This option enables building a transitional driver, supporting |
| 77 |
both devices conforming to Virtio 1 specification, and legacy devices. |
| 78 |
If disabled, you get a slightly smaller, non-transitional driver, |
| 79 |
with no legacy compatibility. |
| 80 |
|
| 81 |
So look out into your driveway. Do you have a flying car? If |
| 82 |
so, you can happily disable this option and virtio will not |
| 83 |
break. Otherwise, leave it set. Unless you're testing what |
| 84 |
life will be like in The Future. |
| 85 |
|
| 86 |
If unsure, say Y. |
| 87 |
|
| 88 |
config VIRTIO_VDPA |
| 89 |
tristate "vDPA driver for virtio devices" |
| 90 |
depends on VDPA |
| 91 |
select VIRTIO |
| 92 |
help |
| 93 |
This driver provides support for virtio based paravirtual |
| 94 |
device driver over vDPA bus. For this to be useful, you need |
| 95 |
an appropriate vDPA device implementation that operates on a |
| 96 |
physical device to allow the datapath of virtio to be |
| 97 |
offloaded to hardware. |
| 98 |
|
| 99 |
If unsure, say M. |
| 100 |
|
| 101 |
config VIRTIO_PMEM |
| 102 |
tristate "Support for virtio pmem driver" |
| 103 |
depends on VIRTIO |
| 104 |
depends on LIBNVDIMM |
| 105 |
help |
| 106 |
This driver provides access to virtio-pmem devices, storage devices |
| 107 |
that are mapped into the physical address space - similar to NVDIMMs |
| 108 |
- with a virtio-based flushing interface. |
| 109 |
|
| 110 |
If unsure, say Y. |
| 111 |
|
| 112 |
config VIRTIO_BALLOON |
| 113 |
tristate "Virtio balloon driver" |
| 114 |
depends on VIRTIO |
| 115 |
select BALLOON |
| 116 |
select PAGE_REPORTING |
| 117 |
help |
| 118 |
This driver supports increasing and decreasing the amount |
| 119 |
of memory within a KVM guest. |
| 120 |
|
| 121 |
If unsure, say M. |
| 122 |
|
| 123 |
config VIRTIO_MEM |
| 124 |
tristate "Virtio mem driver" |
| 125 |
depends on X86_64 || ARM64 || RISCV || S390 |
| 126 |
depends on VIRTIO |
| 127 |
depends on MEMORY_HOTPLUG |
| 128 |
depends on MEMORY_HOTREMOVE |
| 129 |
depends on CONTIG_ALLOC |
| 130 |
depends on EXCLUSIVE_SYSTEM_RAM |
| 131 |
help |
| 132 |
This driver provides access to virtio-mem paravirtualized memory |
| 133 |
devices, allowing to hotplug and hotunplug memory. |
| 134 |
|
| 135 |
This driver currently supports x86-64, arm64, riscv and s390. |
| 136 |
Although it should compile on other architectures that implement |
| 137 |
memory hot(un)plug, architecture-specific and/or common |
| 138 |
code changes may be required for virtio-mem, kdump and kexec to |
| 139 |
work as expected. |
| 140 |
|
| 141 |
If unsure, say M. |
| 142 |
|
| 143 |
config VIRTIO_INPUT |
| 144 |
tristate "Virtio input driver" |
| 145 |
depends on VIRTIO |
| 146 |
depends on INPUT |
| 147 |
help |
| 148 |
This driver supports virtio input devices such as |
| 149 |
keyboards, mice and tablets. |
| 150 |
|
| 151 |
If unsure, say M. |
| 152 |
|
| 153 |
config VIRTIO_MMIO |
| 154 |
tristate "Platform bus driver for memory mapped virtio devices" |
| 155 |
depends on HAS_IOMEM && HAS_DMA |
| 156 |
select VIRTIO |
| 157 |
help |
| 158 |
This drivers provides support for memory mapped virtio |
| 159 |
platform device driver. |
| 160 |
|
| 161 |
If unsure, say N. |
| 162 |
|
| 163 |
config VIRTIO_MMIO_CMDLINE_DEVICES |
| 164 |
bool "Memory mapped virtio devices parameter parsing" |
| 165 |
depends on VIRTIO_MMIO |
| 166 |
help |
| 167 |
Allow virtio-mmio devices instantiation via the kernel command line |
| 168 |
or module parameters. Be aware that using incorrect parameters (base |
| 169 |
address in particular) can crash your system - you have been warned. |
| 170 |
See Documentation/admin-guide/kernel-parameters.rst for details. |
| 171 |
|
| 172 |
If unsure, say 'N'. |
| 173 |
|
| 174 |
config VIRTIO_DMA_SHARED_BUFFER |
| 175 |
tristate |
| 176 |
depends on DMA_SHARED_BUFFER |
| 177 |
help |
| 178 |
This option adds a flavor of dma buffers that are backed by |
| 179 |
virtio resources. |
| 180 |
|
| 181 |
config VIRTIO_DEBUG |
| 182 |
bool "Debug facilities" |
| 183 |
depends on VIRTIO |
| 184 |
help |
| 185 |
Enable this to expose debug facilities over debugfs. |
| 186 |
This allows to debug features, to see what features the device |
| 187 |
advertises and to set filter for features used by driver. |
| 188 |
|
| 189 |
If unsure, say N. |
| 190 |
|
| 191 |
config VIRTIO_RTC |
| 192 |
tristate "Virtio RTC driver" |
| 193 |
depends on VIRTIO |
| 194 |
depends on PTP_1588_CLOCK_OPTIONAL |
| 195 |
help |
| 196 |
This driver provides current time from a Virtio RTC device. The driver |
| 197 |
provides the time through one or more clocks. The Virtio RTC PTP |
| 198 |
clocks and/or the Real Time Clock driver for Virtio RTC must be |
| 199 |
enabled to expose the clocks to userspace. |
| 200 |
|
| 201 |
To compile this code as a module, choose M here: the module will be |
| 202 |
called virtio_rtc. |
| 203 |
|
| 204 |
If unsure, say M. |
| 205 |
|
| 206 |
if VIRTIO_RTC |
| 207 |
|
| 208 |
comment "WARNING: Consider enabling VIRTIO_RTC_PTP and/or VIRTIO_RTC_CLASS." |
| 209 |
depends on !VIRTIO_RTC_PTP && !VIRTIO_RTC_CLASS |
| 210 |
|
| 211 |
comment "Enable PTP_1588_CLOCK in order to enable VIRTIO_RTC_PTP." |
| 212 |
depends on PTP_1588_CLOCK=n |
| 213 |
|
| 214 |
config VIRTIO_RTC_PTP |
| 215 |
bool "Virtio RTC PTP clocks" |
| 216 |
default y |
| 217 |
depends on PTP_1588_CLOCK |
| 218 |
help |
| 219 |
This exposes any Virtio RTC clocks as PTP Hardware Clocks (PHCs) to |
| 220 |
userspace. The PHC sysfs attribute "clock_name" describes the clock |
| 221 |
type. |
| 222 |
|
| 223 |
If unsure, say Y. |
| 224 |
|
| 225 |
config VIRTIO_RTC_ARM |
| 226 |
bool "Virtio RTC cross-timestamping using Arm Generic Timer" |
| 227 |
default y |
| 228 |
depends on VIRTIO_RTC_PTP && ARM_ARCH_TIMER |
| 229 |
help |
| 230 |
This enables Virtio RTC cross-timestamping using the Arm Generic Timer. |
| 231 |
It only has an effect if the Virtio RTC device also supports this. The |
| 232 |
cross-timestamp is available through the PTP clock driver precise |
| 233 |
cross-timestamp ioctl (PTP_SYS_OFFSET_PRECISE2 aka |
| 234 |
PTP_SYS_OFFSET_PRECISE). |
| 235 |
|
| 236 |
If unsure, say Y. |
| 237 |
|
| 238 |
comment "Enable RTC_CLASS in order to enable VIRTIO_RTC_CLASS." |
| 239 |
depends on RTC_CLASS=n |
| 240 |
|
| 241 |
config VIRTIO_RTC_CLASS |
| 242 |
bool "Real Time Clock driver for Virtio RTC" |
| 243 |
default y |
| 244 |
depends on RTC_CLASS |
| 245 |
help |
| 246 |
This exposes the Virtio RTC UTC-like clock as a Linux Real Time Clock. |
| 247 |
It only has an effect if the Virtio RTC device has a UTC-like clock |
| 248 |
which smears leap seconds to avoid steps. The Real Time Clock is |
| 249 |
read-only, and may support setting an alarm. |
| 250 |
|
| 251 |
If unsure, say Y. |
| 252 |
|
| 253 |
endif # VIRTIO_RTC |
| 254 |
|
| 255 |
endif # VIRTIO_MENU |