1 2006-03-21 Martin Mares <mj@ucw.cz>
3 * lspci.c (show_slot_name): Avoid the previous changes in default
4 display of domain name when in machine-readable mode. However, `-D'
5 forces domain display even there.
7 * lspci.man: Added a warning on -m being the only format, which is
8 guaranteed to be stable between lspci versions.
10 2006-03-13 Martin Mares <mj@ucw.cz>
12 * lspci.man: Documented the -D switch.
14 * lspci.c (show_slot_name, scan_device): If there are multiple PCI
15 domains or if the `-D' switch is used, show the domain number for
18 * lspci.c (show_verbose): Report cache line size in bytes.
20 * update-pciids.sh: Use curl if available. Patch by Matthew Wilcox.
22 2006-01-04 Martin Mares <mj@ucw.cz>
24 * lspci.c (show_express_link): Fixed decoding of link status register.
25 Thanks to Roland Dreier for his report.
27 2005-12-12 Martin Mares <mj@ucw.cz>
29 * lib/nbsd-libpci.c: If libpci is used by an ordinary user, allow
30 at least read-only access. Patch by Pavel Celeda <celeda@liberouter.org>.
32 * Makefile: Corrected library path on NetBSD.
34 2005-11-26 Martin Mares <mj@ucw.cz>
38 * lspci.c (show_machine): Subsystem vendors were printed incorrectly
39 in machine-readable modes. Thanks to Pavel Celeda for a bug report.
41 2005-10-11 Martin Mares <mj@ucw.cz>
43 * lspci.c (new_bus): Fixed a memory leak. Thanks to Paul Sangree for reporting it.
45 2005-09-21 Martin Mares <mj@ucw.cz>
49 * pci.ids: Updated copyright header.
51 * lib/sysfs.c (sysfs_get_resources): Removed warning about unsupported
52 64-bit addresses, they are now always supported.
54 * lspci.c (show_bases): Corrected printing of 64-bit addresses
57 * lib/configure: Enable 64-bit addresses on all Linux systems.
59 * lib/types.h: Don't pad 64-bit addresses to 16 xigits, only to 8 if they
62 2005-09-11 Martin Mares <mj@ucw.cz>
64 * Released as 2.1.99-test11.
66 * lspci.c: Removed unnecessary trailing zeros in pci_lookup_name() calls.
68 2005-09-10 Martin Mares <mj@ucw.cz>
70 * Released as 2.1.99-test10.
72 * pci.ids: Synchronized with the current database snapshot.
74 * update-pciids.sh: Changed the default URL for downloading pci.ids
75 to http://pciids.sourceforge.net/v2.2/pci.ids.
77 * lib/pci.h (PCI_LIB_VERSION): Added version identifier.
79 * lib/names.c: Rewritten the name database module almost from scratch.
80 Everything is much cleaner and there are hopefully no more memory leaks;
81 pci_lookup_name() now uses varargs in a backward compatible fashion.
82 Introduced PCI_LOOKUP_NO_NUMBERS.
84 The new code supports subsystem entries not tied to a specific device.
85 I had to extend the format of pci.ids in order to support it, so I have
86 extended the idea of the "C" (class) blocks and introduced "S" blocks
87 for subsystems. To avoid doing more incompatible changes in the future,
88 the parser skips unknown single-letter blocks without reporting errors.
90 2005-08-23 Martin Mares <mj@ucw.cz>
92 * Released as 2.1.99-test9.
94 * Makefile (OPT): Removed -fomit-frame-pointer, it's default in recent
95 gcc versions when optimizing anyway.
97 * Made the path to pci.ids customizable and independent on the SHAREDIR.
98 Just override IDSDIR in the top-level Makefile.
100 * pci.ids: Synchronized with the current database snapshot.
102 * lspci.man, setpci.man: Improved the man pages. Documented all access
103 methods and which operations are privileged.
105 * lspci.c: Another rewrite of config register caching, now also including
106 lots of internal checks. It should be now perfectly able to cope with
107 portions of the configuration space being inaccessible, for example
108 due to insufficient access rights.
110 * lspci.c (show_pcix_nobridge, show_pcix_bridge): Cleaned up dumping of PCI-X
111 capabilities. Includes partial support for PCI-X 2.0 (probably incomplete
112 as I haven't seen the spec).
114 * lspci.c: Quell warnings about unused parameters.
116 * lspci.c: Removed C++ comments.
118 * lib/header.h: Merged definitions of extended capabilities and some new
119 PCI-X capability bits from linux-2.6.11/include/pci.h.
121 * lspci.c (show_caps): Try to scan extended capabilities only if the
122 device has either PCI-X or PCI Express capability in its normal capability
125 * lib/dump.c (dump_init): Reading of dumps works again. The dump reader
126 now also remembers how much data it has read and refuses attempts to
127 access more than that.
129 * setpci.man, lspci.c, README: prefer spelling "buses" over "busses".
131 * lspci.c: If alloca() is not available, use xmalloc(), not malloc().
133 * lib/configure: Added x86_64 on Linux.
135 2005-08-22 Martin Mares <mj@ucw.cz>
137 * lib/filter.c (pci_filter_parse_slot): Fixed parsing of domain filters.
138 Thanks to Matthew Wilcox for bug report.
140 * lspci.c: Corrected spelling of "Hz" (it was "hz" at several places).
141 Thanks to Krzysztof Oledzki for pointing that out.
143 2004-08-19 Martin Mares <mj@ucw.cz>
145 * pciutils.spec (%attr): Setting attributes for /sbin/* is an anachronism,
146 because pciutils by default install to /usr/sbin. Update.
148 2004-08-13 Martin Mares <mj@ucw.cz>
150 * Released as 2.1.99-test8.
152 * lib/types.h, lib/pci.h, lib/sysdep.h: `byte' and `word' are
153 no longer exported to the outside world.
155 * README.Windows: Updated.
157 * maint/release: Substitute version number in win32/config.h.
159 * win32/config.h: Added.
161 * lib/sysdep.h (bzero, strcasecmp): are macros on Windows.
163 * compat/getopt.[ch]: Added copies of getopt.[ch] from the GNU
164 C library for use on systems where the default libraries lack
165 proper getopt. Currently used by the Windows port.
167 * lib/sysdep.h, lib/types.h: Updates of the Windows port from
170 * lib/types.h: If PCI_HAVE_Uxx_TYPES is defined, libpci doesn't define
171 its own u8, u16, u32, byte and word types and uses what the user
172 has supplied instead. With this change, all namespace clashes should
175 * Makefile, lib/Makefile: Updated dependencies.
177 * pciutils.h: Include lib/sysdep.h and move NONRET et al. there.
179 * lib/sysdep.h: No need to include <sys/types.h> on FreeBSD, because
180 it is included unconditionally in lib/types.h.
182 * Moved system-dependent stuff from lib/internal.h to lib/sysdep.h,
183 which is also used by the utilities. Also moved type declarations
184 from lib/pci.h to lib/types.h.
186 * All files: Prepend a "PCI_" prefix in front of all configuration
187 defines to avoid namespace clashes. CAVEAT: If there is any libpci
188 application using the (undocumented) defines, it has to be updated.
190 * lib/Makefile: Killed HAVE_OWN_HEADER_H, since we stopped sharing
191 headers with the kernel a couple of years ago.
193 * lib/sysfs.c (sysfs_get_resources): We have 7 resources, not 6.
195 * lspci.c (show_rom): Use the same logic for printing disabled
196 or unassigned ROM's as we do in show_bases() for the other BAR's.
198 * lib/generic.c (pci_generic_fill_info): Better reaction to
199 invalid 64-bit addresses. Also d->hdrtype should not include
200 bit 7, which caused mysterious errors on multi-function devices.
202 * lib/generic.c (pci_generic_fill_info): Fill in base addresses
203 even if the regions are known to be disabled. It is the client's
204 job to interpret them. (And it is not a trivial job if you want
205 to do it correctly, since you need to check I/O and memory enables
206 on all upstream bridges, too.) However, it could be interesting to
207 introduce functions for interpreting the addresses and even for
208 mapping the regions and doing I/O on them.
210 2004-07-30 Martin Mares <mj@ucw.cz>
212 * lspci.c: HyperTransport improvements from Maciej.
214 2004-07-11 Martin Mares <mj@ucw.cz>
216 * lib/sysfs.c (sysfs_get_resources): Arguments now correspond
217 to the format string. [Patch by Bill Nottingham]
219 2004-07-05 Martin Mares <mj@ucw.cz>
221 * Released as 2.1.99-test7.
223 * lspci.c (config_fetch): Wanted to merge Matthew's bug fix, but
224 ended up with rewriting the fetching mechanism to be fully dynamic,
225 but avoid reading config space registers not explicitly requested.
227 2004-06-29 Matthew Wilcox <willy@debian.org>
229 * lspci.c: More work on PCI Express dumping.
231 * lib/header.h: Updated PCI Express capability definitions.
233 * lib/proc.c (proc_read): Removed bogus warning.
235 * common.c (xrealloc): Introduced.
237 * lspci.man: Added -xxxx.
239 2004-06-27 Martin Mares <mj@ucw.cz>
241 * Released as 2.1.99-test6.
243 * lspci.c (show_msix), lib/header.h: Added dumping of MSI-X cap.
244 Patch by Roland Dreier <roland@topspin.com>, cleaned up by me.
246 * lspci.c (show_pcix_nobridge, show_pcix_bridge): Handle config_fetch()
249 * lib/header.h: Added PCI Express extended capabilities. Again by Matthew.
251 * lspci.c (show_express): Added dumping of PCI Express cap.
252 Patch by Matthew Wilcox.
254 * lib/header.h: Added a list of PCI 3.0 capabilities and also details
255 on PCI Express caps. Patch by Matthew Wilcox <willy@debian.org>.
257 * lspci.c (check_root): Gone. No explicit checks for root are needed,
258 report correct errors reported by the libpci instead.
260 * lspci.c: Added dumping of the extended config space on "-xxxx".
261 Better caching of config registers.
263 * setpci.c (main): Allow access to whole 4096 bytes of the config space.
265 * lib/sysfs.c, lib/proc.c: Don't print error messages on short reads,
266 just return the appropriate error code.
268 * lib: Added support for extended (4096-byte) configuration space,
269 currently implemented only in Linux proc and sysfs access methods
270 and of course in the dump reader.
272 2004-05-29 Martin Mares <mj@ucw.cz>
274 * Released as 2.1.99-test5.
276 * lib/pci.h: Windows don't have the standard u_int* types.
278 * lib/internal.h: <sys/param.h> required on Windows for endianity
281 * lib/i386-ports.c: Connected i386-io-windows.h.
283 * lspci.c (check_root): geteuid() is not available on Windows.
285 * lib/i386-io-windows.h: Added Windows port contributed by Alexander
286 Stock <stock.alexander@gmx.de>.
288 * lib/configure: Hopefully fixed SunOS port broken by various
289 changes to the configure script.
291 * Makefile, lib/configure: Cross-compilation support, patch by Maciej.
293 2004-05-28 Martin Mares <mj@ucw.cz>
295 * Released as 2.1.99-test4.
297 * lspci.c (show_verbose): Header type 1 is probably legal for all
298 types of bridges, not only for PCI-to-PCI bridges.
300 * lspci.c (format_agp_rate): Write "x16", not "x@".
301 (show_agp): rate[] could overflow.
302 Bugs reported by Jakub Bogusz <qboosh@pld-linux.org>.
304 * lspci.c (show_ht_*): Show HyperTransport capability with all its
305 details. Once again code by Maciej simplified (i.e., possibly broken)
308 * lib/header.h: Added declarations of HyperTransport capability.
309 Again thanks to Maciej.
311 * lspci.c: Decode all bits of the secondary status word in type 1 headers.
312 Thanks to Maciej W. Rozycki <macro@ds2.pg.gda.pl> for the patch.
314 2003-12-27 Martin Mares <mj@ucw.cz>
316 * Released as 2.1.99-test3.
318 * lspci.man, setpci.man: Document domains and correct spelling.
320 * lib/dump.c (dump_init): Added ability to read domain numbers.
322 * lspci.c: Devices in domains different from 0 have their slot number
323 printed as "<domain>:<bus>:<slot>.<func>". Tree view supports domains
326 * lib/filter.c: Slot filters understand domains.
328 * lib/generic.c: Mention the domain in slot numbers in all error messages.
330 * lib/internal.h: The #ifdef for Linux <asm/byteorder.h> was wrong.
332 * lib/access.c (pci_get_dev): Added support for domains.
334 * lib/sysfs.c (sysfs_scan): Read vendor and device ID from the config
335 registers (or to be precise, leave it for the generic parts of the pcilib
336 to do so) instead of reading them from the sysfs. It's faster this way.
338 * lspci.c (show_pcix): Don't touch pci_dev->hdrtype, it's an internal
339 variable. Better read it from the config registers (it's cached anyway).
341 * lib/sysfs.c (sysfs_scan), lib/proc.c (proc_scan): Don't read the hdrtype.
342 lib/generic.c (pci_generic_fill_info): If hdrtype is -1 (unset), read it.
343 Saves lots of unnecessary file accesses.
345 * lib/pci.h (PCIADDR_PORT_FMT): Use %llx instead of %Lx, because the latter
346 is not supported by all C libraries.
348 * Makefile: Always enter the lib directory (remember that we don't have
349 full dependecies for the library in the top-level Makefile; hmmm, another
350 thing to rewrite some day).
352 * lib/sysfs.c: Added Linux sysfs access method based on the patch
353 written by Matthew Wilcox <willy@fc.hp.com>.
355 * lib/proc.c: Renamed the access method name from "/proc/bus/pci" to "Linux-proc".
357 * lib/pread.h: The hacks to support pread on various versions
358 of Linux libc moved there.
360 * lib/proc.c (proc_setup): The return value of snprintf() varies
361 between glibc versions, so we need to check both for a negative
362 values and for too large values.
364 * Removed last few references to the "Linux PCI Utilities", the
365 package is pretty cross-platform now :)
367 2003-12-27 Martin Mares <mj@ucw.cz>
369 * Released as 2.1.99-test2.
371 * README, pciutils.lsm, pciutils.spec: Use @VERSION@ to make the
372 release scripts insert the current version. "make release" is gone.
374 * maint/release, maint/release.pm: Added a new system of scripts for
375 making releases including inter-version diffs etc.
377 * Makefile: Cleaned up.
379 * lib/fbsd-device.c: I patched another copy of this file by mistake,
380 this time the version checks should be right.
382 2003-12-27 Martin Mares <mj@ucw.cz>
384 * Released as 2.1.99-test1.
386 * pciutils.h, common.c, lspci.man, setpci.man, lib/internal.h:
387 Remove shadows of the syscall access method which was never
390 * update-pciids.sh: Try to preserve permissions of the old file
391 if chmod supports --reference. Should close Debian Bug #223740.
393 * lib/proc.c (proc_setup): Increased path name length limit to 1024.
394 Thanks for Redhat and Mandrake for inspiration.
396 * lib/configure: Recognize ppc and ppc64, both have 64-bit addresses.
397 Grabbed from Redhat (Fedora) patches.
399 2003-12-27 Martin Mares <mj@ucw.cz>
401 Merged bug fixes from Debian patches:
403 * lspci.c (show_verbose): "Cache Line Size" should be capitalized.
405 * lspci.c (show_pcix_nobridge): Added a missing newline.
407 * lib/proc.c (proc_scan): When reading the header type, don't
408 forget to clear the topmost bit indicating that the device has
411 2003-12-27 Martin Mares <mj@ucw.cz>
413 Updated the FreeBSD port. Thanks to Samy Al Bahra <samy@kerneled.com>
416 * lib/Makefile: Add ${FREEBSD_SYS} to the include path if it's defined.
417 * lib/fbsd-device.c: Select the right set of system includes according
418 to __FreeBSD_version.
420 2003-12-27 Martin Mares <mj@ucw.cz>
422 Merged support for Solaris on i386 by Bill Moore <billm@eng.sun.com>
425 * lib/configure: Recognize SunOS.
426 * lib/internal.h: Learn how to recognize byte order on SunOS.
427 * lib/i386-ports.c: Split OS-dependent I/O port access from i386-ports.c.
428 * lib/i386-io-linux.h: Linux specific part.
429 * lib/i386-io-hurd.h: GNU/Hurd specific part.
430 * lib/i386-io-sunos.h: SunOS specific part.
432 2003-12-26 Martin Mares <mj@ucw.cz>
434 * lib/header.h (PCI_*_MASK): Cast to pciaddr_t explicitly.
436 * lib/pci.h: Types declared in <sys/types.h> should be usable on all
437 platforms we currently support, so kill the forest of #ifdef's and
438 use them in all cases.
440 * lib/pci.h: Use ULONG_MASK to decide whether we should use long
441 or long long to represent a 64-bit address. Killed HAVE_LONG_ADDRESS.
442 Define format strings for addresses, port numbers and IRQ numbers
445 * lib/proc.c (proc_scan): Use PCIADDR_T_FMT for scanf'ing addresses.
447 2003-12-26 Marco Gerards <metgerards@student.han.nl>
449 Added support for the GNU Hurd (cleaned up by Martin Mares):
451 * lib/configure [GNU]: Use the i386 ports for configuration access.
452 * lib/i386-ports.c: Don't call iopl() on the Hurd.
453 * lib/pci.h [OS_GNU]: Include <sys/types.h> and use it for defining
456 2003-12-26 Martin Mares <mj@ucw.cz>
458 * lspci.c (show_pcix_bridge, show_pcix_nobridge): Don't forget to call
459 config_fetch() to ensure that the registers have been read. Thanks to
460 Bill Wood <bill.wood@hp.com> for the patch.
462 * lspci.c: Ensure that failure of config_fetch() is handled correctly
465 * lspci.man: There was one more explicit reference to /usr/share/pci.ids.
466 Changed to @SHAREDIR@. Patch from Maciej W. Rozycki <macro@ds2.pg.gda.pl>.
468 * setpci.c (main): Better error messages.
470 * setpci.c (ex_op): The demo mode should disable only writing, not reading.
472 * setpci.man: The documentation was inconsistent on what should -D do.
473 Document the new behaviour.
475 * pciutils.h, common.c, setpci.c: Introduced a NONRET macro encapsulating
476 the GCC specific __attribute__((noreturn)) and killed the hack with
477 redefining __attribute__ on non-GCC compilers.
479 * Makefile: Added missing dependencies. Parallel builds work now.
480 Problem reported by Andreas Haumer <andreas@xss.co.at>, but I chose
483 * Makefile (MANDIR): Use `:=' instead of `=' to avoid executing the shell
484 command every time $(MANDIR) is referenced.
486 * lspci.c (main): The error message for `lspci -s' incorrectly mentioned
487 a `-f' switch. Reported by Steve Finney <Steve.Finney@SpirentCom.COM>.
489 * lib/generic.c: Removed memory leak in pci_generic_bus_scan().
490 Reported by Gary Parnes <gary_parnes@terago.com>.
492 * Replaced obsolete syntax of __attribute__((unused)) in the middle of
493 parameter declarations (which is no longer supported by GCC 3.1) by the
494 current syntax (attribute at the end). Thanks to pixel@mandrakesoft.com
495 for reporting this problem.
497 * Removed CVS $Id$ tags from all files.
499 * Makefile: Added some more warnings.
501 * setpci.c: Cleaned up mask/value code.
503 2003-12-08 Thayne Harbaugh <tharbaugh@lnxi.com>
505 * setpci.c: Individual bits to be set can be specified as <value>:<mask>.
507 2003-11-29 Martin Mares <mj@ucw.cz>
509 * Imported the pciutils sources to my Arch repository. Good-bye, CVS.
511 2003-01-04 Martin Mares <mj@ucw.cz>
513 * Released as 2.1.11.
515 * Makefile: Changed configuration of installation directories --
516 all paths are now set at the top of the Makefile instead of being
517 scattered between the installation rules. The default installation
518 now goes always to /usr/local regardless of the OS as most distributions
519 already contain some version of pciutils and we don't want custom
520 installations to interfere with the default ones.
522 * Makefile: Removed a couple of ancient install hacks: we no longer
523 try to avoid overwriting a newer pci.ids file (users are now expected
524 to use update-ids) and we don't try to remove /etc/pci.ids (a long time
525 has passed since the last version which used it).
527 * Makefile: Paths to pci.ids in man pages automatically get the right path.
529 * Added the update-ids utility.
531 * lib: Removed partially implemented "syscall" access method which will
532 probably never be needed.
534 2002-12-27 Martin Mares <mj@ucw.cz>
536 * lib/nbsd-libpci.c: Cleaned up and hopefully made it endian safe.
538 * lib/generic.c (pci_generic_scan_bus): Added work-around for devices with
539 discontiguous numbering of functions. This is already present in the Linux
540 kernel for several years, but I forgot to update pciutils as well.
542 2002-12-26 Martin Mares <mj@ucw.cz>
544 * lib/header.h, lspci.c: Dump AGP3 flags and speeds.
546 * lib/pci.h, Makefile: Removed HAVE_OWN_HEADER_H. Always use our own header,
547 there is no reason to prefer the kernel version.
549 * lib/proc.c (proc_scan): Don't forget to initialize hdrtype.
551 * Added preliminary version of NetBSD support by Quentin Garnier
552 <netbsd@quatriemek.com>.
554 2002-04-06 Martin Mares <mj@ucw.cz>
556 * lspci.c: Mention "-xxx" in the help.
558 2002-03-30 Martin Mares <mj@ucw.cz>
560 * Released as 2.1.10.
562 * Removed pci.ids from the CVS as they are now maintained separately.
563 They are still included in the tarball, but if you are building pciutils
564 from CVS sources or you want to get a newer ID file than the one distributed,
565 just use "make update-ids" to download the most recent snapshot from
568 * Makefile, README: Updated accordingly.
570 * Makefile: Added a couple of maintenance targets.
572 * maint/*: Maintainer's utilities now reside here (present only in CVS,
575 * lib/names.c (parse_name_list): End-of-line comments are no longer
576 supported. Hashes are now perfectly valid in all names and they start
577 a comment only at the start of the line.
579 2002-03-26 Martin Mares <mj@ucw.cz>
583 * Makefile: When the currently installed pci.ids file is newer than
584 the version to be installed, don't overwrite it. Suggested by
585 Jean Delvare <khali@linux-fr.org>.
587 2002-03-24 Martin Mares <mj@ucw.cz>
589 * lspci.c (show_pcix_bridge): Added PCI-X capability display.
590 Contributed by Jeff Garzik <jgarzik@mandrakesoft.com>.
592 * lib/header.h: Added PCI-X stuff. Again by Jeff.
594 * Makefile (CFLAGS): -Werror is gone.
596 * lspci.c (format_agp_rate): Fixed AGP rate reporting.
598 * lib/filter.c (pci_filter_parse_slot): Allow bus 0xff, slot 0x1f and
601 * lib/names.c (pci_lookup_name): When printing unknown subsystem vendor
602 or device hexadecimally, don't confuse it with chip vendor/device ID.
603 First reported by Marc Boucher <marc@mbsi.ca>.
605 2001-11-04 Martin Mares <mj@ucw.cz>
609 * pci.ids: Synced with the PCI ID Repository at SourceForge
610 (http://pciids.sourceforge.net/).
612 2000-08-25 Martin Mares <mj@albireo.ucw.cz>
614 * pci.ids: Updated ID's, synced with kernel 2.4.0-test7.
616 2000-06-13 Martin Mares <mj@albireo.ucw.cz>
618 * Makefile (uninstall): Fixed.
620 * pci.ids: ID updates.
622 2000-05-20 Martin Mares <mj@albireo.ucw.cz>
626 * pci.ids: ID updates.
628 * lspci.c (show_verbose): Min/max latency is now printed in nanoseconds.
630 2000-05-04 Martin Mares <mj@albireo.ucw.cz>
632 * lspci.c (show_verbose): If the header type doesn't match device
633 class, just print a warning and still use the header type, assuming
636 2000-05-01 Martin Mares <mj@albireo.ucw.cz>
638 * lspci.c (show_pm): Updated according to PCI PM specs 1.1.
640 * pci.ids: Updated Contemporary Control ARCnet card entries.
642 * pci.ids: Synchronized class list with latest PCI SIG documents.
644 2000-04-29 Martin Mares <mj@albireo.ucw.cz>
646 * lib/names.c (pci_lookup_name): Fixed the cheat.
648 * lib/internal.h: Moved UNUSED/inline hacks above all other declarations.
650 * pci.ids: Various ID updates.
652 2000-04-21 Martin Mares <mj@albireo.ucw.cz>
656 * pciutils.spec: Added German description.
658 * lib/names.c (pci_lookup_name): Added a cheat for case that subsystem ID's
659 are the same as device ID and just output subsystem name according to
662 * lib/proc.c: Use UNUSED instead of __attribute__((unused)).
664 * lib/pci.h: Added the correct typedefs for AIX.
666 * lib/generic.c (pci_generic_scan_bus): Export.
668 * lib/configure: Detect AIX. Use "echo '...\c'" instead of
669 "echo -n" if the shell isn't bash.
671 * lspci.c: Avoid using alloca() if not compiled by GCC.
672 (insert_dev): Avoid returning a void value.
674 * Makefile: Choose which install utility to use according to
675 OS type. Also use `-o' instead of `-or' in find arguments.
676 Part of the AIX port.
678 * lib/aix-device.c: Added AIX low-level interface. Contributed
679 by Dave Johnson <ddj@brown.edu>, thanks a lot!
681 * pci.ids: Few new ID's.
683 * pciutils.h, lib/internal.h: Redefine __attribute__ and inline
684 when not compiled by GCC.
686 2000-04-17 Martin Mares <mj@albireo.ucw.cz>
690 * pci.ids: Added a large batch of ID's contributed by Gunther
691 Mayer <gunther.mayer@braunschweig.netsurf.de> and synced the
692 list with the 2.3.99pre6 kernel.
694 Thu Mar 9 13:11:39 2000 Martin Mares <mj@albireo.ucw.cz>
696 * lib/example.c: Added a simple example of how to use
699 * lspci.man, setpci.man: Revealed --version. Well spotted
702 * pci.ids: Added lots of new ID's and synced with 2.3.50.
704 Tue Feb 15 00:16:21 2000 Martin Mares <mj@albireo.ucw.cz>
708 * pciutils.spec: Updated spec file from Andreas Jaeger. Now using
709 %{_mandir} to find the right location to install manual pages to.
713 * setpci.c (main): Don't crash when `-s' or `-d' is given with
716 Mon Jan 24 20:04:11 2000 Andreas Jaeger <aj@suse.de>
718 * lib/i386-ports.c: Include <asm/io.h> only on systems without
721 Mon Jan 24 11:24:43 2000 Martin Mares <mj@albireo.ucw.cz>
723 * Makefile: Modified to work with the Linux FHS brain-damaged idea
724 of putting man pages to /usr/share/man. Now we choose either /usr/man
725 or /usr/share/man depending on which one exists.
727 Sun Jan 23 10:52:34 2000 Martin Mares <mj@albireo.ucw.cz>
729 * pci.ids: Synced with Linux 2.3.40.
731 * Released as version 2.1.4.
733 Thu Jan 20 11:08:32 2000 Martin Mares <mj@albireo.ucw.cz>
735 * lspci.c (scan_device): Fixed bug in reading of cardbus extensions.
737 * lib/proc.c: pread/pwrite fixed again, this time on libc5 :(
739 * lspci.c (format_agp_rate): Better formatting of AGP rates.
743 * lib/configure: Added configuration for ia64 (the same as for Alpha).
744 Patch from Stephane Eranian <eranian@cello.hpl.hp.com>.
746 Thu Jan 13 23:01:52 2000 Martin Mares <mj@albireo.ucw.cz>
748 * Released as version 2.1.3.
752 * lspci.c: Alpha IO_FORMAT fix by Andrea Arcangeli.
754 * lib/access.c: Corrected order of access methods -- it's wonderful how
755 long could such a bug remain unspotted. Thanks go to Andreas Schockenhoff.
757 Sat Dec 11 23:34:48 1999 Martin Mares <mj@albireo.ucw.cz>
759 * Released as version 2.1.2.
761 * lib/names.c (pci_lookup_name): Fixed printing of unknown subsystem ID's.
763 Sat Dec 4 13:11:03 1999 Martin Mares <mj@albireo.ucw.cz>
765 * Released as version 2.1.1.
767 * pci.ids: Several new ID's.
769 * setpci.c (exec_op): Don't forget to increment address after writing
770 single value, so that `30.b=12,34,56,78' works as expected. Reported
771 by Petr Soucek <petr@ryston.cz>.
773 Wed Nov 3 10:24:38 1999 Martin Mares <mj@albireo.ucw.cz>
775 * lspci.c (show_terse): If prog-if is zero, but it's present in the
778 Sat Oct 30 11:06:35 1999 Martin Mares <mj@albireo.ucw.cz>
780 * Released as version 2.1.
782 * pci.ids: Synced to devlist.h in 2.3.24 kernel. Merged in
783 lots of contributed entries.
785 Thu Oct 14 10:40:12 1999 Dave Jones <dave@powertweak.com>
787 * pci.ids: Added lots of subsystem definitions.
789 Sat Oct 9 14:32:28 1999 Martin Mares <mj@albireo.ucw.cz>
791 * setpci.man: Better example.
793 * lspci.c: Resolve prog-if names.
795 * lib/names.c: Adapted to new pci.ids syntax.
797 * pci.ids: Reorganized the pci.ids file. Subsystems are listed
798 under devices, classes can optionally contain prog-if information.
799 New ID's, as usually.
801 Wed Sep 22 09:45:24 1999 Martin Mares <mj@albireo.ucw.cz>
803 * pci.ids: New ID's. As usually.
805 * lspci.c (show_htype1, show_htype2): Don't show `closed' bridge windows
806 unless we're vvvery verbose.
808 Mon Sep 20 11:22:54 1999 Martin Mares <mj@albireo.ucw.cz>
810 * lspci.c (show_htype2): Don't forget a TAB before the "I/O window" line.
812 Tue Sep 14 09:31:01 1999 Martin Mares <mj@albireo.ucw.cz>
814 * pci.ids: New ID's. Again.
816 Thu Aug 5 17:45:42 1999 Martin Mares <mj@albireo.ucw.cz>
818 * lspci.c (show_size): Don't show size if it's zero (usually
819 due to bus-centric mode being enabled).
821 Tue Jul 20 13:25:09 1999 Martin Mares <mj@albireo.ucw.cz>
823 * lib/pci.h: Types are OS dependent.
825 * lib/internal.h: Byte order hacks are OS dependent.
827 * lib/configure: Recognize FreeBSD. Also set OS_XXX according to the OS.
829 * lib/Makefile, lib/access.c: Added fbsd-device target.
831 * pci.ids: Added an entry for PLX 9080 bridges with subsystem ID
832 incorrectly set to device ID.
834 * README: Added a note that we support FreeBSD.
836 * Makefile (PREFIX, ROOT): Set it depending on the OS.
837 (%.8): Grrr, BSD date is not able to convert date formats the same way
838 as GNU date does. Use sed instead.
839 (install): Use `-c' when calling install.
841 * lib/fbsd-device.c: Added FreeBSD /dev/pci access module contributed
842 by Jari Kirma <kirma@cs.hut.fi>.
844 * lib/proc.c: Rewrote the pread/pwrite things once again. Use pread
845 and pwrite only when we are certain it's safe (i.e., glibc 2.1
846 on all architectures or any libc on a i386 where we really know
847 how to use syscalls directly). In all other cases, emulate it
848 with lseek/read/write.
850 * pci.ids: Some more IDs.
852 Mon Jul 19 14:10:36 1999 Martin Mares <mj@albireo.ucw.cz>
854 * pci.ids: Added IDs of parallel port controller cards as sent
855 by Tim Waugh <tim@cyberelk.demon.co.uk>.
857 Wed Jul 7 00:55:48 1999 Martin Mares <mj@albireo.ucw.cz>
859 * lib/proc.c (proc_scan): HAVE_LONG_ADDRESS instead of HAVE_64BIT_ADDRESS.
861 * lspci.c: ADDR_FORMAT now depends on both HAVE_64BIT_ADDRESS and
864 * lib/configure: HAVE_64BIT_ADDRESS now doesn't imply that the addresses
865 are represented as long long. Introduced a new flag HAVE_LONG_ADDRESS
866 to indicate this. Both Sparc architectures now use both 64BIT_ADDRESS
867 and LONG_ADDRESS since they have 32-bit userland, but don't set LONG_ADDRESS
870 * lspci.c (show_msi): Added dumping of the MSI capability.
871 (show_slotid): The same for SlotID capability.
872 (show_caps): Seperated capability dumping, because it should
873 be used for both htype0 and htype1. Even PCI 2.2 doesn't mention
874 layout of htype2, so I'm a bit unsure about it wrt capabilities
875 -- they at least have to live somewhere else since address 0x34
876 is already defined differently in htype2.
878 * lib/header.h (PCI_STATUS_UDF): Marked as obsolete (PCI 2.2).
879 (PCI_BASE_ADDRESS_MEM_TYPE_1M): Ditto.
880 (PCI_CAP_ID_*): Added some new capabilities defined in PCI 2.2.
882 * lspci.c (show_htype0): Mask out lowest 2 bits from all capability pointers
883 (required by the PCI 2.2 specs).
885 Mon Jul 5 12:45:19 1999 Martin Mares <mj@albireo.ucw.cz>
887 * lspci.c (show_size): Added new function for dumping of region sizes.
888 (show_rom): Added. Now correctly dumps unassigned ROM addresses, disabled
891 * lib/pci.h (struct pci_dev): known_fields moved to the public part
894 * Added support for region sizes. Needs support in the kernel, because
895 sizes have to be scanned before drivers initialize yourself. pci_fill_info()
896 now returns a bitmask of what fields were really read.
898 Mon Jun 28 18:37:51 1999 Dave Jones <dave@powertweak.com>
901 Added `uninstall' target - removes all traces of pciutils.
903 - Lots of cleanups in the ATI, S3, Adaptec vendors.
904 - Changed Compaq QVision 1280/p definitions, as it's not possible
905 to determine the revision from the device ID.
906 - Same for the Tseng ET4000.
907 The id's said I had a rev C, when it was actually a rev B.
908 - Removed some unnecessary strings
909 `PCI'. Unless it's an AGP card, it should be obvious that it's PCI.
910 `Ethernet card'. This should be determined from config space.
911 - Lots of other new vendors & devices
912 - Other additional small cleanups.
914 Mon Jun 21 22:11:10 1999 Martin Mares <mj@albireo.ucw.cz>
916 * lib/names.c (pci_lookup_name): When device ID lookup
917 fails, return hexadecimal device ID instead of vendor ID.
918 Well spotted by Axel Bodemann <Axel.Bodemann@ruhr-uni-bochum.de>,
919 I've just extended the fix to subsystem ID's.
921 Thu Jun 17 19:48:21 1999 Martin Mares <mj@albireo.ucw.cz>
923 * lspci.c (show_agp): Bug fix from Petr Vandrovec
924 <vandrove@vc.cvut.cz>. The command register was displayed
927 Wed Jun 2 22:42:44 1999 Martin Mares <mj@albireo.ucw.cz>
929 * lib/proc.c (SYS_pread, SYS_pwrite): Use hard-coded
930 numbers if not supplied by the libc.
932 Wed May 19 13:24:39 1999 Martin Mares <mj@albireo.ucw.cz>
934 * Released the whole package as version 2.0.
936 Fri May 14 22:42:02 1999 Martin Mares <mj@albireo.ucw.cz>
938 * pci.ids: Added several new ID's contributed by people
939 on the linux-pci list.
941 Mon Apr 19 15:21:08 1999 Jakub Jelinek <jj@ultra.linux.cz>
943 * lspci.c: Display I/O addresses correctly on sparc64.
944 * lib/header.h: Ditto.
946 * lib/configure: On sparc set HAVE_64BIT* as well, we want
947 a binary which works on both 32bit and 64bit SPARCs.
949 Sun Apr 18 21:14:58 1999 Martin Mares <mj@albireo.ucw.cz>
951 * lspci.c, lib/proc.c: Alpha compilation fixes from Matthew Jacob
954 * pci.ids: A lot of updates from Adam J. Richter <adam@yggdrasil.com>.
956 Sun Feb 28 22:26:21 1999 Martin Mares <mj@albireo.ucw.cz>
958 * lspci.c (do_map_bus): Don't dump functions 1--7 if not flagged
959 as a multi-function device, because several single-function devices
960 don't decode the function bits at all.
962 Sun Feb 14 23:48:22 1999 Martin Mares <mj@albireo.ucw.cz>
964 * Makefile (install): Don't use "-o root -g root" for installation
965 since it breaks on machines where programs are not installed by root.
966 Reported by Richard Gooch <rgooch@atnf.csiro.au>
968 Tue Feb 9 15:54:39 1999 Martin Mares <mj@albireo.ucw.cz>
970 * lspci.c (show_bases): Use new address masking macros and pciaddr_t.
972 * lib/pci.h: Using pciaddr_t for bus addresses, which are 32-bit
973 or 64-bit depending on CPU.
975 * lib/pci.h (PCI_ADDR_MEM_MASK): Added macros for address masks
976 according to bus address width.
978 Thu Jan 28 20:54:16 1999 Martin Mares <mj@albireo.ucw.cz>
980 * Released as 1.99.4.
982 * lspci.c: Capability list parser now recognizes both AGP
983 registers and PCI Power Management registers (the latter
984 is mainly guesswork based on DEC/Intel 21153 bridge specs
985 since I don't have the PCI Power Management document).
987 * lspci.c: Replaced numerous occurences of (x & flag) ? '+' : '-'
990 * lspci.c: Added bridge checks to bus mapping code.
992 Wed Jan 27 14:59:16 1999 Martin Mares <mj@albireo.ucw.cz>
994 * lspci.c: Implemented bus mapping mode (-M).
996 * lspci.c (scan_devices): Split to scan_devices() and scan_device().
997 (show): Split to show() and show_device().
999 * lib/access.c (pci_init): When a->method == PCI_ACCESS_AUTO,
1000 set it to the real access method afterwards.
1002 Mon Jan 25 23:46:13 1999 Martin Mares <mj@albireo.ucw.cz>
1004 * lib/generic.c (pci_generic_fill_info): If in buscentric mode,
1005 don't check PCI_COMMAND for I/O and memory enables.
1007 Mon Jan 25 21:28:49 1999 Martin Mares <mj@albireo.ucw.cz>
1009 * Makefile: Added target `release' which substitutes new version
1010 number to .spec, .lsm and README. Also rewrote target `dist'.
1012 * Released as 1.99.3.
1014 Sun Jan 24 22:10:36 1999 Martin Mares <mj@albireo.ucw.cz>
1016 * lib/header.h: Until kernel adopts new layout of PCI
1017 includes (i.e., separate declaration of header structure,
1018 functions and device IDs), which is not going to happen
1019 before 2.3, we'll use our own definiton of the header.
1021 * lspci.c (show_verbose): Display `Cap' flag in device status.
1023 * lspci.c (show_htype0): Display capability lists whereever
1024 available. The only capability name we recognize now is `AGP'.
1025 Unfortunately, capabilities are stored in device-dependent
1026 portion of the configuration space and are thus available
1027 only to root unless you read a dump.
1029 * lspci.c (scan_devices): Use cache instead of buffering.
1031 * lib/buffer.c: Removed (obsoleted by the cache).
1033 * lib/access.c: Added general caching mechanism.
1035 Sat Jan 23 21:30:54 1999 Martin Mares <mj@albireo.ucw.cz>
1037 * pci.ids: Added few devices.
1039 Fri Jan 22 19:29:31 1999 Martin Mares <mj@albireo.ucw.cz>
1041 * Version string is now defined in top-level Makefile, exported
1042 to the configure script and also substituted to man pages.
1044 * lspci.c (show_bases): Rewrote displaying of 64-bit addresses.
1045 (show_verbose): Rewrote interrupt display logic.
1047 * lib/i386-ports.c: Include sys/io.h only on glibc systems.
1049 * lib/configure: Rewrote detection of Linux versions. Now it
1050 works on 2.0 kernels (only with direct/dump access, of course).
1052 * lib/internal.h: New bytesex macros using <asm/byteorder.h>
1055 * lib/proc.c (proc_read, proc_write): Distinguish between short
1056 read/write and real errors.
1058 * lspci.c (show_htype{0,1}): Always use d->dev->rom_base_addr since
1059 libpci respects buscentric mode automatically.
1061 * lspci.c (show_hex_dump): For CardBus bridges, print out 128
1062 bytes of header (the whole standard part).
1064 * common.c: pcilib options are now all uppercase. Also moved
1065 PCI access debugging option here.
1067 * Released as 1.99.2.
1069 Wed Jan 20 22:50:35 1999 Martin Mares <mj@albireo.ucw.cz>
1071 * Wrote configure script and rewrote Makefiles.
1073 * Removed few unused variables.
1075 Wed Jan 20 12:21:56 1999 Martin Mares <mj@albireo.ucw.cz>
1077 * common.c: Moved several functions used in both setpci and lspci
1078 here. This includes parsing of libpci-related options.
1080 * More library tweaks.
1082 * filter.c, names.c: Moved to library.
1084 * setpci: Rewritten to use the library.
1086 * Released as 1.99.1.
1088 Tue Jan 19 23:00:12 1999 Martin Mares <mj@albireo.ucw.cz>
1090 * lspci.c (scan_devices): For cardbus bridges, read first 128
1091 bytes of config space to get full standard header.
1093 * Makefile (CFLAGS): Removed "-Wno-unused".
1095 * Started the "New Generation" branch and introduced the
1098 * lspci: Rewritten to use the library.
1100 Tue Jan 19 22:24:08 1999 Martin Mares <mj@albireo.ucw.cz>
1102 * Released as version 1.10.
1104 Mon Jan 18 08:51:17 1999 Martin Mares <mj@albireo.ucw.cz>
1106 * lspci.8, setpci.8: Miscellaneous fixes as suggested by
1107 Dag Wieers <dag@digibel.be>.
1109 Sun Nov 29 20:05:56 1998 Martin Mares <mj@albireo.ucw.cz>
1111 * pciutils.spec (Name): Update from Krzysztof G. Baranowski.
1113 Sun Nov 22 10:49:56 1998 Martin Mares <mj@albireo.ucw.cz>
1115 * Makefile, pciutils.h: Moved pci.ids to /usr/share.
1117 * Released as version 1.09.
1119 Wed Nov 18 15:47:05 1998 Martin Mares <mj@albireo.ucw.cz>
1121 * lspci.c (show_htype1): Fixed displaying of prefetchable memory behind
1122 bridge. Thanks to Petr Vandrovec <vandrove@vc.cvut.cz> for bug report.
1124 Fri Oct 23 18:59:19 1998 Martin Mares <mj@albireo.ucw.cz>
1126 * setpci.c: Don't include <syscall-list.h> with glibc >= 2.1.
1128 Mon Oct 19 21:53:30 1998 Martin Mares <mj@albireo.ucw.cz>
1130 * Released as version 1.08.
1132 * setpci.c: glibc 2.1.x already defines pread() and pwrite().
1134 * lspci.8: Changed warning about lspci -xxx.
1136 * lspci.c: Require "-xxx" for full configuration space dump, so that
1137 it's impossible to crash the machine by single typo.
1139 * specs: Added (courtesy of Krzysztof G. Baranowski <kgb@knm.org.pl>).
1141 Wed Sep 9 12:03:24 1998 Martin Mares <mj@albireo.ucw.cz>
1143 * lspci.c (show_bases): Better displaying of unassigned and
1144 disabled bases. Thanks to Gabriel Paubert <paubert@iram.es>
1147 Wed Sep 2 10:58:01 1998 Martin Mares <mj@albireo.ucw.cz>
1149 * setpci.c (pread): Recognize glibc 1.99 numbered as 2.0 on the PPC.
1150 (thanks to Geert Uytterhoeven for finding this out)
1152 Fri Jul 17 10:43:30 1998 Martin Mares <mj@albireo.ucw.cz>
1154 * lspci.c (show_verbose): Print subsystem ID using the new resolver.
1155 (show_machine): Print subsystem ID.
1157 * names.c: New name resolution engine supporting subsystem IDs.
1159 * Released as version 1.07.
1161 Wed Jul 15 15:37:21 1998 Martin Mares <mj@albireo.ucw.cz>
1163 * lspci.c (show_htype2 etc.): Displaying of CardBus headers.
1164 (show_bases): Honor the `cnt' argument.
1165 (grow_tree): Parse CardBus headers in tree mode as well.
1167 * pci.h: Updated CardBus header field description. I still don't
1168 have the CardBus standard available, but OZ6832 specs contain
1169 full description of all header fields supported by the chip.
1171 Tue Jun 9 22:53:59 1998 Martin Mares <mj@albireo.ucw.cz>
1175 * names.c (parse_name_list): Killed an unused variable.
1177 * setpci.c (pread, pwrite): Define SYS_(pread|pwrite) as __NR_\1
1178 if they are not defined by glibc (needed for glibc built on older
1181 * setpci.c (exec_op): Fixed error messages. Thanks, Steve!
1183 Mon Jun 8 10:59:22 1998 Martin Mares <mj@albireo.ucw.cz>
1187 * setpci.c: Problems with pread()/pwrite() with glibc on Alpha
1188 should be gone. Again thanks to Steve for bug report.
1190 * filter.c (filter_parse_slot): Fixed ":x" type filters.
1192 * pci.ids: Killed duplicate entry. Thanks to Stephen Williams
1193 <steve@icarus.com> for reporting this.
1195 Sun Jun 7 19:27:51 1998 Martin Mares <mj@albireo.ucw.cz>
1197 * lspci.c (main), setpci.c (main): Implemented "--version".
1201 * pciutils.h (PCIUTILS_VERSION): Added version string.
1203 * filter.c, names.c: Extraneous #include <linux/pci.h> removed.
1204 Thanks to Geert Uytterhoeven <Geert.Uytterhoeven@cs.kuleuven.ac.be>
1207 Thu May 28 14:45:58 1998 Martin Mares <mj@lomikel.karlin.mff.cuni.cz>
1209 * pci.ids: More updates from Jens Maurer.
1211 Wed Apr 22 10:00:39 1998 Martin Mares <mj@albireo.ucw.cz>
1213 * pci.ids: Updates from Jens Maurer.
1215 Sun Apr 19 11:14:25 1998 Martin Mares <mj@albireo.ucw.cz>
1219 * setpci.8: Written.
1221 * setpci.c: Finished.
1223 * lspci.c: Now able to fetch expansion ROM base from kernel device list
1224 and print it if not in buscentric mode.
1226 Tue Mar 31 23:11:57 1998 Martin Mares <mj@albireo.ucw.cz>
1230 Sun Mar 22 15:39:08 1998 Martin Mares <mj@albireo.ucw.cz>
1232 * lspci.8: Updated the documentation.
1234 * lspci.c: Modified to use the new filtering mechanism (options -f and -d).
1236 * filter.c: Introduced new generic device filter.
1238 Thu Mar 19 17:03:48 1998 Martin Mares <mj@lomikel.karlin.mff.cuni.cz>
1240 * lspci.c (grow_tree, show_tree_dev, print_it): Fixed displaying
1241 of PCI-to-PCI bridges in the tree format.
1243 Sun Feb 15 10:12:25 1998 Martin Mares <mj@albireo.ucw.cz>
1245 * lspci.c (show_machine): Added non-verbose mode of machine-readable
1248 * pci.ids: Updates from Jens Maurer.
1250 * Released as version 1.02.
1252 Thu Feb 12 16:53:28 1998 Martin Mares <mj@lomikel.karlin.mff.cuni.cz>
1254 * lspci.c: Added a "-m" switch for dumping machine-readable
1255 configuration data (requested by Bjoern Kriews <bkr@cut.de>).
1257 Mon Feb 9 13:17:43 1998 Martin Mares <mj@albireo.ucw.cz>
1259 * Makefile, pciutils.h: Include local pci.h instead of <linux/pci.h>
1260 if available. This should avoid all problems with official kernel
1261 not synchronized to newer PCI code in CVS -- standard distribution
1262 of pciutils now contains pci.h from current CVS kernel, pciutils
1263 in CVS contain no pci.h and use the correct kernel include.
1265 * Makefile: Fixed installation path for man pages.
1267 Sat Feb 7 15:15:46 1998 Martin Mares <mj@albireo.ucw.cz>
1271 * lspci.8: Created a man page.
1273 * Releasing as version 1.0.
1275 Tue Feb 3 20:56:00 1998 Martin Mares <mj@albireo.ucw.cz>
1277 * Makefile: Recognize architecture by calling uname and pass it as ARCH_xxx
1278 to all the C sources. This should eliminate problems with 32-bit compilers
1281 * lspci.c (show_verbose): Recognize CardBus bridge header type.
1282 (show_htype2): Stub routine.
1283 (scan_config): Write sensible error message if the kernel denies reading of
1284 upper part of the PCI config space.