]> git.ipfire.org Git - thirdparty/pciutils.git/blame - pciutils.h
Verbose display of CardBus bridge headers (type 2) added. Requires <linux/pci.h>
[thirdparty/pciutils.git] / pciutils.h
CommitLineData
98e39e09 1/*
96e4f295 2 * $Id: pciutils.h,v 1.7 1998/07/15 20:37:15 mj Exp $
98e39e09
MM
3 *
4 * Linux PCI Utilities -- Declarations
5 *
18928b91 6 * Copyright (c) 1997, 1998 Martin Mares <mj@atrey.karlin.mff.cuni.cz>
98e39e09
MM
7 *
8 * Can be freely distributed and used under the terms of the GNU GPL.
9 */
10
11#include <linux/types.h>
12
fb38eee8
MM
13#ifdef KERNEL_PCI_H
14#include <linux/pci.h>
15#else
16#include "pci.h"
17#endif
18
96e4f295 19#define PCIUTILS_VERSION "1.07"
4b88a6b8 20
98e39e09
MM
21#define PROC_BUS_PCI "/proc/bus/pci"
22#define ETC_PCI_IDS "/etc/pci.ids"
98e39e09
MM
23
24/* Types */
25
26typedef __u8 byte;
27typedef __u16 word;
28typedef __u32 u32;
29
30/* lspci.c */
31
32void *xmalloc(unsigned int);
33
34/* names.c */
35
36extern int show_numeric_ids;
18928b91 37extern char *pci_ids;
98e39e09
MM
38
39char *lookup_vendor(word);
40char *lookup_device(word, word);
41char *lookup_device_full(word, word);
42char *lookup_class(word);
e4842ff3
MM
43
44/* filter.c */
45
46struct pci_filter {
47 int bus, slot, func; /* -1 = ANY */
48 int vendor, device;
49};
50
51void filter_init(struct pci_filter *);
52char *filter_parse_slot(struct pci_filter *, char *);
53char *filter_parse_id(struct pci_filter *, char *);
54int filter_match(struct pci_filter *, byte bus, byte devfn, word vendid, word devid);