1 .\" Contributed by Niki A. Rahimi, LTC Security Development
2 .\" narahimi@us.ibm.com
4 .\" %%%LICENSE_START(FREELY_REDISTRIBUTABLE)
5 .\" May be freely distributed.
8 .TH PCICONFIG_READ 2 2003-07-14 "Linux" "Linux Programmer's Manual"
10 pciconfig_read, pciconfig_write, pciconfig_iobase \- pci device information handling
15 .BI "int pciconfig_read(unsigned long " bus ", unsigned long " dfn ,
16 .BI " unsigned long " off ", unsigned long " len ", void *" buf );
17 .BI "int pciconfig_write(unsigned long " bus ", unsigned long " dfn ,
18 .BI " unsigned long " off ", unsigned long " len ", void *" buf );
19 .BI "int pciconfig_iobase(long " which ", unsigned long " bus ,
20 .BI " unsigned long " devfn );
24 Most of the interaction with PCI devices is already handled by the
26 and thus these calls should not normally need to be accessed from user space.
37 .BR pciconfig_write ()
46 .BR pciconfig_iobase ()
47 You pass it a bus/devfn pair and get a physical address for either the
48 memory offset (for things like prep, this is 0xc0000000),
49 the IO base for PIO cycles, or the ISA holes if any.
53 On success zero is returned.
54 On error, \-1 is returned and
58 .BR pciconfig_write ()
59 On success zero is returned.
60 On error, \-1 is returned and
64 .BR pciconfig_iobase ()
65 Returns information on locations of various I/O
66 regions in physical memory according to the
72 .BR IOBASE_BRIDGE_NUMBER ,
82 This does not apply to
83 .BR pciconfig_iobase ().
90 .BR pciconfig_iobase (),
92 For the other calls, could not find a slot.
95 The system has not implemented these calls
100 This return value is valid only for
101 .BR pciconfig_iobase ().
102 It is returned if the value for
107 User does not have the
110 This does not apply to
111 .BR pciconfig_iobase ().
113 These calls are Linux-specific, available since Linux 2.0.26/2.1.11.
117 This page is part of release 3.64 of the Linux
120 A description of the project,
121 and information about reporting bugs,
123 \%http://www.kernel.org/doc/man\-pages/.