---
name: "pci_find_slot"
section: "9"
platform: "linux"
package: "linux-manual-2.6.26"
version: "2.6.26-29"
release: "Debian 5.0 (Lenny)"
platforms: ["linux"]
url: "https://new.carta.tech/pci_find_slot"
---

# pci\_find\_slot(9)

locate PCI device from a given PCI slot

## NAME

pci\_find\_slot - locate PCI device from a given PCI slot

## SYNOPSIS

**struct pci\_dev \* pci\_find\_slot(unsigned int** *bus***, unsigned int** *devfn***);**

## ARGUMENTS

*bus*

number of PCI bus on which desired PCI device resides

*devfn*

encodes number of PCI slot in which the desired PCI device resides and the logical device number within that slot in case of multi-function devices.

## DESCRIPTION

Given a PCI bus and slot/function number, the desired PCI device is located in system global list of PCI devices. If the device is found, a pointer to its data structure is returned. If no device is found, **NULL** is returned.

## NOTE

Do not use this function any more; use **pci\_get\_slot** instead, as the PCI device returned by this function can disappear at any moment in time.

## COPYRIGHT
