PVBUS(4)
π NAME π
Okay so bestie, this is pvbus(4) β the paravirtual device tree root β and itβs living its best life in the Kernel Interfaces Manual. Itβs the root of the paravirtual device tree vibe. β¨
β¨ SYNOPSIS β¨
pvbus0 at mainbus0
#include <sys/types.h>
#include <sys/ioctl.h>
#include <dev/pv/pvvar.h>
π¦ DESCRIPTION π¦
So like, pvbus is used on virtual machines that are running on hypervisors. It provides a pseudo-bus for all the paravirtual devices that do not attach to a well-known bus like pci(4). The pvbus driver is the one doing the main-character work: detecting the hypervisor interface, checking the capabilities, attaching the paravirtual devices, and providing access to supported information stores. π
π Supported hypervisors π
- KVM β Kernel-based Virtual Machine
- Hyper-V β Microsoft Hyper-V
- OpenBSD β OpenBSD
vmm(4) - VMware β VMware vSphere Hypervisor and ESXi
- Xen β Xen VMM
π«Ά heads up: a hypervisor can attempt to emulate other hypervisors, so multiple hypervisor interfaces may be available on the same host.
π VMware paravirtual devices π
vmt(4)β VMware Tools driver and βguestinfoβ information store
π§ Hyper-V paravirtual devices π§
hvn(4)β Hyper-V virtual networking interfacehvs(4)β Hyper-V virtual diskhyperv(4)β Hyper-V guest nexus device
π¦ Xen paravirtual devices π¦
xbf(4)β Xen Blkfront virtual diskxen(4)β Xen domU nexus device and XenStore information storexnf(4)β Xen Netfront virtual networking interface
π IOCTL INTERFACE π
pvbus supports ioctl(2) commands to exchange information with the hypervisor interface, as implemented in the hostctl(8) program. Each detected hypervisor interface is available as a character special device file, /dev/pvbus0, /dev/pvbus1, etc. All available commands use the same pvbus_req structure:
struct pvbus_req {
size_t pvr_keylen;
char *pvr_key;
size_t pvr_valuelen;
char *pvr_value;
};
Bestie, the caller is responsible for attaching character buffers to the pvr_key and pvr_value fields and to set their length in pvr_keylen and pvr_valuelen accordingly. All keys and values are nul-terminated strings. π
The following ioctl(2) commands are available:
PVBUSIOC_KVREADβ Read the value frompvr_keyand return it inpvr_value. Ifpvr_valuelenis not enough for the value, the command will fail anderrno(2)is set toERANGE.PVBUSIOC_KVTYPEβ Return the type of the attached hypervisor interface as a string inpvr_key; see βSupported hypervisorsβ.PVBUSIOC_KVWRITEβ Write the new valuepvr_valueto the keypvr_key. This command requires write permissions on the device file.
π FILES π
/dev/pvbusuβpvbusdevice unit u file.
π₯ SEE ALSO π₯
autoconf(4), intro(4), mainbus(4), vmm(4), hostctl(8)
πΈ HISTORY πΈ
The pvbus pseudo-bus first appeared in OpenBSD 5.8. β
π AUTHORS π
The pvbus pseudo-bus was written by Reyk Floeter <reyk@openbsd.org>.
π okay thatβs the whole page, bestie β footer vibes: Debian, January 7, 2023, page PVBUS(4). slay and byeee β¨
π¦ where this page comes from
- nixpkgs unstable: cvs-export
- Copyright (c) 2015 Reyk Floeter <reyk@openbsd.org>
- Copyright (c) 2006 Jason McIntyre <jmc@openbsd.org>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms