diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
commit | fc22b3d6507c6745911b9dfcc68f1e665ae13dbc (patch) | |
tree | ce1e3bce06471410239a6f41282e328770aa404a /upstream/mageia-cauldron/man9/pcibios_find_class.9 | |
parent | Initial commit. (diff) | |
download | manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.tar.xz manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.zip |
Adding upstream version 4.22.0.upstream/4.22.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'upstream/mageia-cauldron/man9/pcibios_find_class.9')
-rw-r--r-- | upstream/mageia-cauldron/man9/pcibios_find_class.9 | 82 |
1 files changed, 82 insertions, 0 deletions
diff --git a/upstream/mageia-cauldron/man9/pcibios_find_class.9 b/upstream/mageia-cauldron/man9/pcibios_find_class.9 new file mode 100644 index 00000000..b18741e2 --- /dev/null +++ b/upstream/mageia-cauldron/man9/pcibios_find_class.9 @@ -0,0 +1,82 @@ +.\" -*- nroff -*- +.TH pcibios_find_class 9 "August 5, 1997" "Linux DDI" "BIOS32 Functions" +.hlm 0 +.na +.SH NAME +pcibios_find_class, pcibios_find_device \- find a PCI class or device +.SH SYNOPSIS +.B #include <linux/bios32.h> +.sp +.TP +.BI "int pcibios_find_class(unsigned int " class_code \ +", unsigned short " index ", unsigned char* " bus \ +", unsigned char* " device_fn ");" +.TP +.BI "int pcibios_find_device(unsigned\ short\ "\ vendor \ +", unsigned\ short\ " device_id\ \ +", unsigned\ short\ " index ", unsigned\ char*\ " bus \ +", unsigned\ char*\ " device_fn ");" +.hlm 1 +.ad +.SH DESCRIPTION +The +.B pcibios_find_class +function searches for a certain class of device on the PCI bus. In this +instance, class is used to represent a few different categories of +devices. Some examples are storage, network, display, and memory +classes. The classes are defined by the PCI Specification, and the +.I class_code +is matched with the dword in the configuration space of the device at +offset 0x08. +.PP +The +.B pcibios_find_device +function finds a device on the PCI bus that has the matching device +and vendor ids. The vendor ids are assigned to the PCI Sig to vendors, +who in turn assign device ids to the devices they develop. The vendor +and device ids are encoded in dword 0x00 of the configuration space. +.PP +Both +.B pcibios_find_class +and +.B pcibios_find_device +include an extra +.I index +parameter, which is used to select the specific +device if there are multiple matches. An +.I index +of 0 matches the firts located board, 1 the second, and so on. +.PP +The +.I bus +and +.I device_fn +parameters are PCI specific cookies that are passed to other pcibios +functions to access the configuration space of the located device. +.SH "RETURN VALUE" +On success, the functions return +.IR PCIBIOS_SUCCESSFUL "." +Otherwise, one of the following error codes is returned: +.RS +.TP +PCIBIOS_DEVICE_NOT_FOUND +There is no device that matches the search criteria, +.TP +PCIBIOS_BAD_VENDOR_ID +The vendor id is invalid. (0xffff is not a valid id.) +.TP +PCIBIOS_FUNC_NOT_SUPPRTED +The PCI subsystem is not available +.RE +.SH AVAILABILITY +Linux 1.0+ +.SH "SEE ALSO" +.BR pcibios_present "(9)" +.PP +.BR /usr/include/linux/pci.h ", " +.BR /usr/include/linux/bios32.h +.PP +.I "PCI Local Bus Specification" +.SH AUTHOR +Kirk Petersen (kirk@speakeasy.org) +.SH BUGS |