Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci pci(9): Provide default definition of pci_get_se...



details:   https://anonhg.NetBSD.org/src/rev/6a4f648acc60
branches:  trunk
changeset: 362433:6a4f648acc60
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Feb 27 14:18:52 2022 +0000

description:
pci(9): Provide default definition of pci_get_segment, always zero.

pci_machdep.h can define __HAVE_PCI_GET_SEGMENT to provide a nonzero
definition.

diffstat:

 sys/dev/pci/pcivar.h |  10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diffs (24 lines):

diff -r 73f892bf80c5 -r 6a4f648acc60 sys/dev/pci/pcivar.h
--- a/sys/dev/pci/pcivar.h      Sun Feb 27 14:18:42 2022 +0000
+++ b/sys/dev/pci/pcivar.h      Sun Feb 27 14:18:52 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pcivar.h,v 1.116 2021/09/15 17:33:08 thorpej Exp $     */
+/*     $NetBSD: pcivar.h,v 1.117 2022/02/27 14:18:52 riastradh Exp $   */
 
 /*
  * Copyright (c) 1996, 1997 Christopher G. Demetriou.  All rights reserved.
@@ -137,6 +137,14 @@
        return pba->pba_pc;
 }
 
+#ifndef __HAVE_PCI_GET_SEGMENT
+static __inline u_int
+pci_get_segment(pci_chipset_tag_t pc)
+{
+       return 0;
+}
+#endif
+
 /*
  * PCI device attach arguments.
  */



Home | Main Index | Thread Index | Old Index