O nás     Inzerce     KontaktSpolehlivé informace o IT již od roku 2011
Hledat
Nepřehlédněte: Top z IT: Pozoruhodné IT produkty pro rok 2025
Správa dokumentů
Digitální transformace
Informační systémy
Hlavní rubriky: Informační systémy, Mobilní technologie, Datová centra, Sítě, IT bezpečnost, Software, Hardware, Zkušenosti a názory, Speciály

Pozoruhodné IT produkty 2025
E-knihy o IT zdarma
Manuál Linux
[Linux manuál]

pciconfig_read, pciconfig_write, pciconfig_iobase: zpracování informací o zařízení pci

Originální popis anglicky: pciconfig_read, pciconfig_write, pciconfig_iobase - pci device information handling

Návod, kniha: Linux Programmer's Manual

STRUČNĚ

#include <pci.h>
 
int pciconfig_read(unsigned long bus, unsigned long dfn, unsigned long off, unsigned long len, void *buf); int pciconfig_write(unsigned long bus, unsigned long dfn, unsigned long off, unsigned long len, void *buf); int pciconfig_iobase(long which, unsigned long bus, unsigned long devfn);

POPIS / INSTRUKCE

Most of the interaction with PCI devices is already handled by the kernel PCI layer, and thus these calls should not normally need to be accessed from userspace.
pciconfig_read
Reads to buf from device dev at offset off value.
pciconfig_write
Writes from buf to device dev at offset off value.
pciconfig_iobase
You pass it a bus/devfn pair and get a physical address for either the memory offset (for things like prep, this is 0xc0000000), the IO base for PIO cycles, or the ISA holes if any.

NÁVRATOVÁ HODNOTA

pciconfig_read
On success zero is returned. On error, -1 is returned and errno is set appropriately.
pciconfig_write
On success zero is returned. On error, -1 is returned and errno is set appropriately.
pciconfig_iobase
Returns information on locations of various I/O regions in physical memory according to the which value. Values for which are: IOBASE_BRIDGE_NUMBER, IOBASE_MEMORY, IOBASE_IO, IOBASE_ISA_IO, IOBASE_ISA_MEM.

CHYBY / ERRORY

EINVAL
len value is invalid. This does not apply to pci_iobase.
EIO
I/O error.
ENODEV
For pci_iobase, hose value is NULL? For the other calls, could not find a slot.
ENOSYS
The system has not implemented these calls (CONFIG_PCI not defined).
EOPNOTSUPP
This return value is only valid for pci_iobase. It is returned if the value for which is invalid.
EPERM
User does not have the CAP_SYS_ADMIN capability. This does not apply to pci_iobase.

ODPOVÍDAJÍCÍ

These calls are Linux specific, available since Linux 2.0.26/2.1.11.

SOUVISEJÍCÍ

capabilities(7)
2003-07-14 Linux 2.4.19
©2011-2024 BusinessIT.cz, ISSN 1805-0522 | Názvy použité v textech mohou být ochrannými známkami příslušných vlastníků.
Provozovatel: Bispiral, s.r.o., kontakt: BusinessIT(at)Bispiral.com | Inzerce: Best Online Media, s.r.o., zuzana@online-media.cz
O vydavateli | Pravidla webu BusinessIT.cz a ochrana soukromí | Používáme účetní program Money S3 | pg(9501)