Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pciback(4) [netbsd man page]

PCIBACK(4)						 BSD/xen Kernel Interfaces Manual						PCIBACK(4)

NAME
pciback -- Xen backend paravirtualized PCI pass-through driver SYNOPSIS
pciback* at pci? DESCRIPTION
The pciback driver is the backend part of the PCI pass-through functionality that can be used by the Xen dom0 to export pci(4) devices to a guest domain. To export a PCI device to a guest domain, the device has to be attached to pciback in the dom0. When the guest domain is NetBSD, the device attached to the pciback driver will attach to a xpci(4) bus inside the guest domain. EXAMPLES
To attach a device to the pciback driver, follow these steps: 1. look for the device PCI ID, via pcictl(8). 2. edit boot.cfg(5) and add the PCI ID to the list of PCI IDs that you want to attach to pciback, in bus:device.function notation. The list is passed to dom0 module via the pciback.hide parameter: pciback.hide=(bus:dev.fun)(bus:dev.func)(...) See also boot(8). 3. reboot dom0. 4. add the PCI ID to the list of PCI devices in the domain configuration file: pci = ['bus:dev.fun', '...'] 5. start the guest domain. SEE ALSO
pci(4), xpci(4), boot(8), pcictl(8) HISTORY
The pciback driver first appeared in NetBSD 5.1. AUTHORS
The pciback driver was written by Manuel Bouyer <bouyer@NetBSD.org>. CAVEATS
Currently, to attach a device to the pciback backend, this procedure has to be performed at boot(8) time. In the future, it will be possible to do it without requiring a dom0 reboot. SECURITY CONSIDERATIONS
As PCI passthrough offers the possibility for guest domains to send arbitrary PCI commands to a physical device, this has direct impact on the overall stability and security of the system. For example, in case of erroneous or malicious commands, the device could overwrite physi- cal memory portions, via DMA. BSD
January 8, 2011 BSD

Check Out this Related Man Page

PCI(3)							   BSD Library Functions Manual 						    PCI(3)

NAME
pci -- library interface for PCI bus access LIBRARY
PCI Bus Access Library (libpci, -lpci) SYNOPSIS
#include <pci.h> int pcibus_conf_read(int pcifd, u_int bus, u_int dev, u_int func, u_int reg, pcireg_t *valp); int pcibus_conf_write(int pcifd, u_int bus, u_int dev, u_int func, u_int reg, pcireg_t val); int pcidev_conf_read(int devfd, u_int reg, pcireg_t *valp); int pcidev_conf_write(int devfd, u_int reg, pcireg_t val); char * pci_findvendor(pcireg_t id_reg); void pci_devinfo(pcireg_t id_reg, pcireg_t class_reg, char *devinfo, size_t len); void pci_conf_print(int pcifd, u_int bus, u_int dev, u_int func); DESCRIPTION
The pci library provides support for accessing the PCI bus by user programs. These functions are available in the libpci library. Programs should be linked with -lpci. CONFIGURATION SPACE FUNCTIONS
The following functions are used to access PCI configuration space: pcibus_conf_read() Access the PCI configuration register reg on the device located at bus, dev, func, and place the result in *valp. pcifd must be an open file descriptor to a PCI bus within the target PCI domain. pcibus_conf_write() Write the value specified by val into the PCI configuration register reg on the device located at bus, dev, func. pcifd must be an open file descriptor to a PCI bus within the target PCI domain. pcidev_conf_read() Access the PCI configuration register reg on the device associated with the open file descriptor devfd and place the result in *valp. pcidev_conf_write() Write the value specified by val into the PCI configuration register reg on the device associated with the open file descriptor devfd. MISCELLANEOUS FUNCTIONS
The following miscellaneous functions are available: pci_findvendor() Return an ASCII description of the PCI vendor in the PCI ID register id_reg. pci_devinfo() Return an ASCII description of the PCI vendor, PCI product, and PCI class specified by the PCI ID register id_reg and PCI class ID reg- ister class_reg. The description is placed into the buffer pointed to by devinfo; the size of that buffer is specified in len. pci_conf_print() Print the PCI configuration information for the device located at bus, dev, func. pcifd must be an open file descriptor to a PCI bus within the target PCI domain. RETURN VALUES
The pcibus_conf_read(), pcibus_conf_write(), pcidev_conf_read(), and pcidev_conf_write() functions return 0 on success and -1 on failure. The pci_findvendor() function returns NULL if the PCI vendor description cannot be found. SEE ALSO
pci(4) HISTORY
The pcibus_conf_read(), pcibus_conf_write(), pcidev_conf_read(), pcidev_conf_write(), pci_findvendor(), pci_devinfo(), and pci_conf_print() functions first appeared in NetBSD 1.6. BSD
April 24, 2004 BSD
Man Page