1*4882a593Smuzhiyun /*
2*4882a593Smuzhiyun * Copyright 1998 by Concurrent Computer Corporation
3*4882a593Smuzhiyun *
4*4882a593Smuzhiyun * Permission to use, copy, modify, distribute, and sell this software
5*4882a593Smuzhiyun * and its documentation for any purpose is hereby granted without fee,
6*4882a593Smuzhiyun * provided that the above copyright notice appear in all copies and that
7*4882a593Smuzhiyun * both that copyright notice and this permission notice appear in
8*4882a593Smuzhiyun * supporting documentation, and that the name of Concurrent Computer
9*4882a593Smuzhiyun * Corporation not be used in advertising or publicity pertaining to
10*4882a593Smuzhiyun * distribution of the software without specific, written prior
11*4882a593Smuzhiyun * permission. Concurrent Computer Corporation makes no representations
12*4882a593Smuzhiyun * about the suitability of this software for any purpose. It is
13*4882a593Smuzhiyun * provided "as is" without express or implied warranty.
14*4882a593Smuzhiyun *
15*4882a593Smuzhiyun * CONCURRENT COMPUTER CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD
16*4882a593Smuzhiyun * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
17*4882a593Smuzhiyun * AND FITNESS, IN NO EVENT SHALL CONCURRENT COMPUTER CORPORATION BE
18*4882a593Smuzhiyun * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
19*4882a593Smuzhiyun * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
20*4882a593Smuzhiyun * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
21*4882a593Smuzhiyun * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
22*4882a593Smuzhiyun * SOFTWARE.
23*4882a593Smuzhiyun *
24*4882a593Smuzhiyun * Copyright 1998 by Metro Link Incorporated
25*4882a593Smuzhiyun *
26*4882a593Smuzhiyun * Permission to use, copy, modify, distribute, and sell this software
27*4882a593Smuzhiyun * and its documentation for any purpose is hereby granted without fee,
28*4882a593Smuzhiyun * provided that the above copyright notice appear in all copies and that
29*4882a593Smuzhiyun * both that copyright notice and this permission notice appear in
30*4882a593Smuzhiyun * supporting documentation, and that the name of Metro Link
31*4882a593Smuzhiyun * Incorporated not be used in advertising or publicity pertaining to
32*4882a593Smuzhiyun * distribution of the software without specific, written prior
33*4882a593Smuzhiyun * permission. Metro Link Incorporated makes no representations
34*4882a593Smuzhiyun * about the suitability of this software for any purpose. It is
35*4882a593Smuzhiyun * provided "as is" without express or implied warranty.
36*4882a593Smuzhiyun *
37*4882a593Smuzhiyun * METRO LINK INCORPORATED DISCLAIMS ALL WARRANTIES WITH REGARD
38*4882a593Smuzhiyun * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
39*4882a593Smuzhiyun * AND FITNESS, IN NO EVENT SHALL METRO LINK INCORPORATED BE
40*4882a593Smuzhiyun * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
41*4882a593Smuzhiyun * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
42*4882a593Smuzhiyun * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
43*4882a593Smuzhiyun * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
44*4882a593Smuzhiyun * SOFTWARE.
45*4882a593Smuzhiyun *
46*4882a593Smuzhiyun * This software is derived from the original XFree86 PCI code
47*4882a593Smuzhiyun * which includes the following copyright notices as well:
48*4882a593Smuzhiyun *
49*4882a593Smuzhiyun * Copyright 1995 by Robin Cutshaw <robin@XFree86.Org>
50*4882a593Smuzhiyun *
51*4882a593Smuzhiyun * Permission to use, copy, modify, distribute, and sell this software and its
52*4882a593Smuzhiyun * documentation for any purpose is hereby granted without fee, provided that
53*4882a593Smuzhiyun * the above copyright notice appear in all copies and that both that
54*4882a593Smuzhiyun * copyright notice and this permission notice appear in supporting
55*4882a593Smuzhiyun * documentation, and that the names of the above listed copyright holder(s)
56*4882a593Smuzhiyun * not be used in advertising or publicity pertaining to distribution of
57*4882a593Smuzhiyun * the software without specific, written prior permission. The above listed
58*4882a593Smuzhiyun * copyright holder(s) make(s) no representations about the suitability of this
59*4882a593Smuzhiyun * software for any purpose. It is provided "as is" without express or
60*4882a593Smuzhiyun * implied warranty.
61*4882a593Smuzhiyun *
62*4882a593Smuzhiyun * THE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM(S) ALL WARRANTIES WITH REGARD
63*4882a593Smuzhiyun * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
64*4882a593Smuzhiyun * AND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE
65*4882a593Smuzhiyun * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
66*4882a593Smuzhiyun * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
67*4882a593Smuzhiyun * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
68*4882a593Smuzhiyun * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
69*4882a593Smuzhiyun *
70*4882a593Smuzhiyun * This code is also based heavily on the code in FreeBSD-current, which was
71*4882a593Smuzhiyun * written by Wolfgang Stanglmeier, and contains the following copyright:
72*4882a593Smuzhiyun *
73*4882a593Smuzhiyun * Redistribution and use in source and binary forms, with or without
74*4882a593Smuzhiyun * modification, are permitted provided that the following conditions
75*4882a593Smuzhiyun * are met:
76*4882a593Smuzhiyun * 1. Redistributions of source code must retain the above copyright
77*4882a593Smuzhiyun * notice, this list of conditions and the following disclaimer.
78*4882a593Smuzhiyun * 2. Redistributions in binary form must reproduce the above copyright
79*4882a593Smuzhiyun * notice, this list of conditions and the following disclaimer in the
80*4882a593Smuzhiyun * documentation and/or other materials provided with the distribution.
81*4882a593Smuzhiyun * 3. The name of the author may not be used to endorse or promote products
82*4882a593Smuzhiyun * derived from this software without specific prior written permission.
83*4882a593Smuzhiyun *
84*4882a593Smuzhiyun * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
85*4882a593Smuzhiyun * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
86*4882a593Smuzhiyun * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
87*4882a593Smuzhiyun * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
88*4882a593Smuzhiyun * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
89*4882a593Smuzhiyun * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
90*4882a593Smuzhiyun * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
91*4882a593Smuzhiyun * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
92*4882a593Smuzhiyun * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
93*4882a593Smuzhiyun * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
94*4882a593Smuzhiyun *
95*4882a593Smuzhiyun */
96*4882a593Smuzhiyun /*
97*4882a593Smuzhiyun * Copyright (c) 1999-2003 by The XFree86 Project, Inc.
98*4882a593Smuzhiyun *
99*4882a593Smuzhiyun * Permission is hereby granted, free of charge, to any person obtaining a
100*4882a593Smuzhiyun * copy of this software and associated documentation files (the "Software"),
101*4882a593Smuzhiyun * to deal in the Software without restriction, including without limitation
102*4882a593Smuzhiyun * the rights to use, copy, modify, merge, publish, distribute, sublicense,
103*4882a593Smuzhiyun * and/or sell copies of the Software, and to permit persons to whom the
104*4882a593Smuzhiyun * Software is furnished to do so, subject to the following conditions:
105*4882a593Smuzhiyun *
106*4882a593Smuzhiyun * The above copyright notice and this permission notice shall be included in
107*4882a593Smuzhiyun * all copies or substantial portions of the Software.
108*4882a593Smuzhiyun *
109*4882a593Smuzhiyun * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
110*4882a593Smuzhiyun * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
111*4882a593Smuzhiyun * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
112*4882a593Smuzhiyun * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
113*4882a593Smuzhiyun * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
114*4882a593Smuzhiyun * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
115*4882a593Smuzhiyun * OTHER DEALINGS IN THE SOFTWARE.
116*4882a593Smuzhiyun *
117*4882a593Smuzhiyun * Except as contained in this notice, the name of the copyright holder(s)
118*4882a593Smuzhiyun * and author(s) shall not be used in advertising or otherwise to promote
119*4882a593Smuzhiyun * the sale, use or other dealings in this Software without prior written
120*4882a593Smuzhiyun * authorization from the copyright holder(s) and author(s).
121*4882a593Smuzhiyun */
122*4882a593Smuzhiyun
123*4882a593Smuzhiyun #ifdef HAVE_XORG_CONFIG_H
124*4882a593Smuzhiyun #include <xorg-config.h>
125*4882a593Smuzhiyun #endif
126*4882a593Smuzhiyun
127*4882a593Smuzhiyun #include "Pci.h"
128*4882a593Smuzhiyun
129*4882a593Smuzhiyun Bool
xf86scanpci(void)130*4882a593Smuzhiyun xf86scanpci(void)
131*4882a593Smuzhiyun {
132*4882a593Smuzhiyun Bool success = FALSE;
133*4882a593Smuzhiyun
134*4882a593Smuzhiyun success = (pci_system_init() == 0);
135*4882a593Smuzhiyun
136*4882a593Smuzhiyun /* choose correct platform/OS specific PCI init routine */
137*4882a593Smuzhiyun osPciInit();
138*4882a593Smuzhiyun
139*4882a593Smuzhiyun return success;
140*4882a593Smuzhiyun }
141