'\" t .\" Title: pci_alloc_irq_vectors .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: April 2019 .\" Manual: Hardware Interfaces .\" Source: Kernel Hackers Manual 4.9.168 .\" Language: English .\" .TH "PCI_ALLOC_IRQ_VECTOR" "9" "April 2019" "Kernel Hackers Manual 4\&.9\&." "Hardware Interfaces" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" pci_alloc_irq_vectors \- allocate multiple IRQs for a device .SH "SYNOPSIS" .HP \w'int\ pci_alloc_irq_vectors('u .BI "int pci_alloc_irq_vectors(struct\ pci_dev\ *\ " "dev" ", unsigned\ int\ " "min_vecs" ", unsigned\ int\ " "max_vecs" ", unsigned\ int\ " "flags" ");" .SH "ARGUMENTS" .PP \fIdev\fR .RS 4 PCI device to operate on .RE .PP \fImin_vecs\fR .RS 4 minimum number of vectors required (must be >= 1) .RE .PP \fImax_vecs\fR .RS 4 maximum (desired) number of vectors .RE .PP \fIflags\fR .RS 4 flags or quirks for the allocation .RE .SH "DESCRIPTION" .PP Allocate up to \fImax_vecs\fR interrupt vectors for \fIdev\fR, using MSI\-X or MSI vectors if available, and fall back to a single legacy vector if neither is available\&. Return the number of vectors allocated, (which might be smaller than \fImax_vecs\fR) if successful, or a negative error code on error\&. If less than \fImin_vecs\fR interrupt vectors are available for \fIdev\fR the function will fail with \-ENOSPC\&. .PP To get the Linux IRQ number used for a vector that can be passed to \fBrequest_irq\fR use the \fBpci_irq_vector\fR helper\&. .SH "COPYRIGHT" .br