\hypertarget{acpi__pcib_8c_source}{}\doxysection{acpi\+\_\+pcib.\+c}
\label{acpi__pcib_8c_source}\index{dev/acpica/acpi\_pcib.c@{dev/acpica/acpi\_pcib.c}}
\mbox{\hyperlink{acpi__pcib_8c}{Go to the documentation of this file.}}
\begin{DoxyCode}{0}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00001}00001 \textcolor{comment}{/*-\/}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00002}00002 \textcolor{comment}{ * Copyright (c) 2000 Michael Smith}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00003}00003 \textcolor{comment}{ * Copyright (c) 2000 BSDi}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00004}00004 \textcolor{comment}{ * All rights reserved.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00005}00005 \textcolor{comment}{ *}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00006}00006 \textcolor{comment}{ * Redistribution and use in source and binary forms, with or without}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00007}00007 \textcolor{comment}{ * modification, are permitted provided that the following conditions}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00008}00008 \textcolor{comment}{ * are met:}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00009}00009 \textcolor{comment}{ * 1. Redistributions of source code must retain the above copyright}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00010}00010 \textcolor{comment}{ *    notice, this list of conditions and the following disclaimer.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00011}00011 \textcolor{comment}{ * 2. Redistributions in binary form must reproduce the above copyright}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00012}00012 \textcolor{comment}{ *    notice, this list of conditions and the following disclaimer in the}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00013}00013 \textcolor{comment}{ *    documentation and/or other materials provided with the distribution.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00014}00014 \textcolor{comment}{ *}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00015}00015 \textcolor{comment}{ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00016}00016 \textcolor{comment}{ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00017}00017 \textcolor{comment}{ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00018}00018 \textcolor{comment}{ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00019}00019 \textcolor{comment}{ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00020}00020 \textcolor{comment}{ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00021}00021 \textcolor{comment}{ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00022}00022 \textcolor{comment}{ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00023}00023 \textcolor{comment}{ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00024}00024 \textcolor{comment}{ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00025}00025 \textcolor{comment}{ * SUCH DAMAGE.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00026}00026 \textcolor{comment}{ */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00027}00027 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00028}00028 \textcolor{preprocessor}{\#include <sys/cdefs.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00029}\mbox{\hyperlink{acpi__pcib_8c_a8c3ef283470a68cd30afe9b8a72cb60f}{00029}} \mbox{\hyperlink{acpi__pcib_8c_a8c3ef283470a68cd30afe9b8a72cb60f}{\_\_FBSDID}}(\textcolor{stringliteral}{"{}\$FreeBSD\$"{}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00030}00030 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00031}00031 \textcolor{preprocessor}{\#include "{}opt\_acpi.h"{}}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00032}00032 \textcolor{preprocessor}{\#include <sys/param.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00033}00033 \textcolor{preprocessor}{\#include <sys/bus.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00034}00034 \textcolor{preprocessor}{\#include <sys/malloc.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00035}00035 \textcolor{preprocessor}{\#include <sys/kernel.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00036}00036 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00037}00037 \textcolor{preprocessor}{\#include <contrib/dev/acpica/include/acpi.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00038}00038 \textcolor{preprocessor}{\#include <contrib/dev/acpica/include/accommon.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00039}00039 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00040}00040 \textcolor{preprocessor}{\#include <\mbox{\hyperlink{acpivar_8h}{dev/acpica/acpivar.h}}>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00041}00041 \textcolor{preprocessor}{\#include <\mbox{\hyperlink{acpi__pcibvar_8h}{dev/acpica/acpi\_pcibvar.h}}>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00042}00042 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00043}00043 \textcolor{preprocessor}{\#include <dev/pci/pcivar.h>}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00044}00044 \textcolor{preprocessor}{\#include "{}pcib\_if.h"{}}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00045}00045 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00046}00046 \textcolor{comment}{/* Hooks for the ACPI CA debugging infrastructure. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00047}\mbox{\hyperlink{acpi__pcib_8c_ac76d546e6c738c61838d855c815bfbcc}{00047}} \textcolor{preprocessor}{\#define \_COMPONENT      ACPI\_BUS}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00048}00048 ACPI\_MODULE\_NAME(\textcolor{stringliteral}{"{}PCI"{}})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00049}00049 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00050}\mbox{\hyperlink{acpi__pcib_8c_abe01e745b93b7e94be9659cded026019}{00050}} \mbox{\hyperlink{acpi__pcib_8c_abe01e745b93b7e94be9659cded026019}{ACPI\_SERIAL\_DECL}}(pcib, "{}ACPI PCI bus methods"{});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00051}00051 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00052}00052 \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00053}00053 \textcolor{comment}{ * For locking, we assume the caller is not concurrent since this is}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00054}00054 \textcolor{comment}{ * triggered by newbus methods.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00055}00055 \textcolor{comment}{ */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00056}00056 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00057}\mbox{\hyperlink{structprt__lookup__request}{00057}} struct \mbox{\hyperlink{structprt__lookup__request}{prt\_lookup\_request}} \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00058}\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{00058}}     ACPI\_PCI\_ROUTING\_TABLE *\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00059}\mbox{\hyperlink{structprt__lookup__request_ad2aca3142449a4f79d33cb87e23f6ffa}{00059}}     u\_int       \mbox{\hyperlink{structprt__lookup__request_ad2aca3142449a4f79d33cb87e23f6ffa}{pr\_pin}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00060}\mbox{\hyperlink{structprt__lookup__request_a0b3a04c5378cb823d8ff67bb266a7283}{00060}}     u\_int       \mbox{\hyperlink{structprt__lookup__request_a0b3a04c5378cb823d8ff67bb266a7283}{pr\_slot}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00061}00061 \};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00062}00062 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00063}\mbox{\hyperlink{acpi__pcib_8c_a587b1f2f07553fb0c925724061ce1277}{00063}} \textcolor{keyword}{typedef} \textcolor{keywordtype}{void} \mbox{\hyperlink{acpi__pcib_8c_a587b1f2f07553fb0c925724061ce1277}{prt\_entry\_handler}}(ACPI\_PCI\_ROUTING\_TABLE *entry, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00064}00064 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00065}00065 \textcolor{keyword}{static} \textcolor{keywordtype}{void}     \mbox{\hyperlink{acpi__pcib_8c_a3a86d21e071bb70f3e07844c3b33b168}{prt\_attach\_devices}}(ACPI\_PCI\_ROUTING\_TABLE *entry, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00066}00066 \textcolor{keyword}{static} \textcolor{keywordtype}{void}     \mbox{\hyperlink{acpi__pcib_8c_a9a2a6c8ebc03864622b162ec4882ee52}{prt\_lookup\_device}}(ACPI\_PCI\_ROUTING\_TABLE *entry, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00067}00067 \textcolor{keyword}{static} \textcolor{keywordtype}{void}     \mbox{\hyperlink{acpi__pcib_8c_a08f6fd51ae8cbb5f70e351663d09ea5a}{prt\_walk\_table}}(ACPI\_BUFFER *prt, \mbox{\hyperlink{acpi__pcib_8c_a587b1f2f07553fb0c925724061ce1277}{prt\_entry\_handler}} *handler,}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00068}00068                     \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00069}00069 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00070}00070 \textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00071}\mbox{\hyperlink{acpi__pcib_8c_a08f6fd51ae8cbb5f70e351663d09ea5a}{00071}} \mbox{\hyperlink{acpi__pcib_8c_a08f6fd51ae8cbb5f70e351663d09ea5a}{prt\_walk\_table}}(ACPI\_BUFFER *prt, \mbox{\hyperlink{acpi__pcib_8c_a587b1f2f07553fb0c925724061ce1277}{prt\_entry\_handler}} *handler, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00072}00072 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00073}00073     ACPI\_PCI\_ROUTING\_TABLE *entry;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00074}00074     \textcolor{keywordtype}{char} *prtptr;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00075}00075 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00076}00076     \textcolor{comment}{/* First check to see if there is a table to walk. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00077}00077     \textcolor{keywordflow}{if} (prt == NULL || prt-\/>Pointer == NULL)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00078}00078         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00079}00079 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00080}00080     \textcolor{comment}{/* Walk the table executing the handler function for each entry. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00081}00081     prtptr = prt-\/>Pointer;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00082}00082     entry = (ACPI\_PCI\_ROUTING\_TABLE *)prtptr;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00083}00083     \textcolor{keywordflow}{while} (entry-\/>Length != 0) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00084}00084         handler(entry, \mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00085}00085         prtptr += entry-\/>Length;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00086}00086         entry = (ACPI\_PCI\_ROUTING\_TABLE *)prtptr;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00087}00087     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00088}00088 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00089}00089 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00090}00090 \textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00091}\mbox{\hyperlink{acpi__pcib_8c_a3a86d21e071bb70f3e07844c3b33b168}{00091}} \mbox{\hyperlink{acpi__pcib_8c_a3a86d21e071bb70f3e07844c3b33b168}{prt\_attach\_devices}}(ACPI\_PCI\_ROUTING\_TABLE *entry, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00092}00092 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00093}00093     ACPI\_HANDLE handle;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00094}00094     device\_t child, pcib;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00095}00095     \textcolor{keywordtype}{int} error;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00096}00096 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00097}00097     \textcolor{comment}{/* We only care about entries that reference a link device. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00098}00098     \textcolor{keywordflow}{if} (entry-\/>Source[0] == \textcolor{charliteral}{'\(\backslash\)0'})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00099}00099         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00100}00100 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00101}00101     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00102}00102 \textcolor{comment}{     * In practice, we only see SourceIndex's of 0 out in the wild.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00103}00103 \textcolor{comment}{     * When indices != 0 have been found, they've been bugs in the ASL.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00104}00104 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00105}00105     \textcolor{keywordflow}{if} (entry-\/>SourceIndex != 0)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00106}00106         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00107}00107 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00108}00108     \textcolor{comment}{/* Lookup the associated handle and device. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00109}00109     pcib = (device\_t)\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00110}00110     \textcolor{keywordflow}{if} (ACPI\_FAILURE(AcpiGetHandle(ACPI\_ROOT\_OBJECT, entry-\/>Source, \&handle)))}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00111}00111         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00112}00112     child = \mbox{\hyperlink{acpivar_8h_a167b31c02c02b6e32b4183cdcafc5ddd}{acpi\_get\_device}}(handle);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00113}00113     \textcolor{keywordflow}{if} (child == NULL)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00114}00114         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00115}00115 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00116}00116     \textcolor{comment}{/* If the device hasn't been probed yet, force it to do so. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00117}00117     error = device\_probe\_and\_attach(child);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00118}00118     \textcolor{keywordflow}{if} (error != 0) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00119}00119         device\_printf(pcib, \textcolor{stringliteral}{"{}failed to force attach of \%s\(\backslash\)n"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00120}00120             \mbox{\hyperlink{acpi_8c_a06c3bc79994c8a4f6835c134dd3d50f2}{acpi\_name}}(handle));}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00121}00121         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00122}00122     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00123}00123 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00124}00124     \textcolor{comment}{/* Add a reference for a specific bus/device/pin tuple. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00125}00125     \mbox{\hyperlink{acpi__pci__link_8c_a540bf88b5a1c7c2380d6347534e3f48c}{acpi\_pci\_link\_add\_reference}}(child, entry-\/>SourceIndex, pcib,}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00126}00126         \mbox{\hyperlink{acpivar_8h_a69caa9a340cf0d0993de027de6f34b42}{ACPI\_ADR\_PCI\_SLOT}}(entry-\/>Address), entry-\/>Pin);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00127}00127 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00128}00128 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00129}00129 \textcolor{keywordtype}{void}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00130}\mbox{\hyperlink{acpi__pcib_8c_ac88bfc7dc98ec7f922ad8ef90fe79660}{00130}} \mbox{\hyperlink{acpi__pcib_8c_ac88bfc7dc98ec7f922ad8ef90fe79660}{acpi\_pcib\_fetch\_prt}}(device\_t \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, ACPI\_BUFFER *prt)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00131}00131 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00132}00132     ACPI\_STATUS status;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00133}00133 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00134}00134     ACPI\_FUNCTION\_TRACE((\textcolor{keywordtype}{char} *)(uintptr\_t)\_\_func\_\_);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00135}00135 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00136}00136     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00137}00137 \textcolor{comment}{     * Get the PCI interrupt routing table for this bus.  If we can't}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00138}00138 \textcolor{comment}{     * get it, this is not an error but may reduce functionality.  There}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00139}00139 \textcolor{comment}{     * are several valid bridges in the field that do not have a \_PRT, so}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00140}00140 \textcolor{comment}{     * only warn about missing tables if bootverbose is set.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00141}00141 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00142}00142     prt-\/>Length = ACPI\_ALLOCATE\_BUFFER;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00143}00143     status = AcpiGetIrqRoutingTable(acpi\_get\_handle(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), prt);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00144}00144     \textcolor{keywordflow}{if} (ACPI\_FAILURE(status) \&\& (bootverbose || status != AE\_NOT\_FOUND))}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00145}00145         device\_printf(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00146}00146             \textcolor{stringliteral}{"{}could not get PCI interrupt routing table for \%s -\/ \%s\(\backslash\)n"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00147}00147             \mbox{\hyperlink{acpi_8c_a06c3bc79994c8a4f6835c134dd3d50f2}{acpi\_name}}(acpi\_get\_handle(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}})), AcpiFormatException(status));}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00148}00148 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00149}00149     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00150}00150 \textcolor{comment}{     * Ensure all the link devices are attached.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00151}00151 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00152}00152     \mbox{\hyperlink{acpi__pcib_8c_a08f6fd51ae8cbb5f70e351663d09ea5a}{prt\_walk\_table}}(prt, \mbox{\hyperlink{acpi__pcib_8c_a3a86d21e071bb70f3e07844c3b33b168}{prt\_attach\_devices}}, \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00153}00153 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00154}00154 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00155}00155 \textcolor{keyword}{static} \textcolor{keywordtype}{void}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00156}\mbox{\hyperlink{acpi__pcib_8c_a9a2a6c8ebc03864622b162ec4882ee52}{00156}} \mbox{\hyperlink{acpi__pcib_8c_a9a2a6c8ebc03864622b162ec4882ee52}{prt\_lookup\_device}}(ACPI\_PCI\_ROUTING\_TABLE *entry, \textcolor{keywordtype}{void} *\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00157}00157 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00158}00158     \textcolor{keyword}{struct }\mbox{\hyperlink{structprt__lookup__request}{prt\_lookup\_request}} *pr;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00159}00159 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00160}00160     pr = (\textcolor{keyword}{struct }\mbox{\hyperlink{structprt__lookup__request}{prt\_lookup\_request}} *)\mbox{\hyperlink{acpi__if_8m_a9ce2ec4812a92cb6ab39f6e81e9173a9}{arg}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00161}00161     \textcolor{keywordflow}{if} (pr-\/>\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}} != NULL)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00162}00162         \textcolor{keywordflow}{return};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00163}00163 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00164}00164     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00165}00165 \textcolor{comment}{     * Compare the slot number (high word of Address) and pin number}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00166}00166 \textcolor{comment}{     * (note that ACPI uses 0 for INTA) to check for a match.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00167}00167 \textcolor{comment}{     *}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00168}00168 \textcolor{comment}{     * Note that the low word of the Address field (function number)}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00169}00169 \textcolor{comment}{     * is required by the specification to be 0xffff.  We don't risk}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00170}00170 \textcolor{comment}{     * checking it here.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00171}00171 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00172}00172     \textcolor{keywordflow}{if} (\mbox{\hyperlink{acpivar_8h_a69caa9a340cf0d0993de027de6f34b42}{ACPI\_ADR\_PCI\_SLOT}}(entry-\/>Address) == pr-\/>\mbox{\hyperlink{structprt__lookup__request_a0b3a04c5378cb823d8ff67bb266a7283}{pr\_slot}} \&\&}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00173}00173         entry-\/>Pin == pr-\/>\mbox{\hyperlink{structprt__lookup__request_ad2aca3142449a4f79d33cb87e23f6ffa}{pr\_pin}})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00174}00174             pr-\/>\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}} = entry;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00175}00175 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00176}00176 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00177}00177 \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00178}00178 \textcolor{comment}{ * Route an interrupt for a child of the bridge.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00179}00179 \textcolor{comment}{ */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00180}00180 \textcolor{keywordtype}{int}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00181}\mbox{\hyperlink{acpi__pcib_8c_a98b142f6e7f8d384c3600e73f1aa2857}{00181}} \mbox{\hyperlink{acpi__pcib_8c_a98b142f6e7f8d384c3600e73f1aa2857}{acpi\_pcib\_route\_interrupt}}(device\_t pcib, device\_t \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, \textcolor{keywordtype}{int} pin,}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00182}00182     ACPI\_BUFFER *prtbuf)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00183}00183 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00184}00184     ACPI\_PCI\_ROUTING\_TABLE *prt;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00185}00185     \textcolor{keyword}{struct }\mbox{\hyperlink{structprt__lookup__request}{prt\_lookup\_request}} pr;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00186}00186     ACPI\_HANDLE lnkdev;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00187}00187     \textcolor{keywordtype}{int} interrupt;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00188}00188 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00189}00189     ACPI\_FUNCTION\_TRACE((\textcolor{keywordtype}{char} *)(uintptr\_t)\_\_func\_\_);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00190}00190 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00191}00191     lnkdev = NULL;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00192}00192     interrupt = PCI\_INVALID\_IRQ;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00193}00193 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00194}00194     \textcolor{comment}{/* ACPI numbers pins 0-\/3, not 1-\/4 like the BIOS. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00195}00195     pin-\/-\/;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00196}00196 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00197}00197     \mbox{\hyperlink{acpivar_8h_a9e2d4d8ab6769579f7ad5fc57e58692c}{ACPI\_SERIAL\_BEGIN}}(pcib);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00198}00198 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00199}00199     \textcolor{comment}{/* Search for a matching entry in the routing table. */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00200}00200     pr.\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}} = NULL;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00201}00201     pr.\mbox{\hyperlink{structprt__lookup__request_ad2aca3142449a4f79d33cb87e23f6ffa}{pr\_pin}} = pin;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00202}00202     pr.\mbox{\hyperlink{structprt__lookup__request_a0b3a04c5378cb823d8ff67bb266a7283}{pr\_slot}} = pci\_get\_slot(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00203}00203     \mbox{\hyperlink{acpi__pcib_8c_a08f6fd51ae8cbb5f70e351663d09ea5a}{prt\_walk\_table}}(prtbuf, \mbox{\hyperlink{acpi__pcib_8c_a9a2a6c8ebc03864622b162ec4882ee52}{prt\_lookup\_device}}, \&pr);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00204}00204     \textcolor{keywordflow}{if} (pr.\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}} == NULL) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00205}00205         device\_printf(pcib, \textcolor{stringliteral}{"{}no PRT entry for \%d.\%d.INT\%c\(\backslash\)n"{}}, pci\_get\_bus(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}),}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00206}00206             pci\_get\_slot(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), \textcolor{charliteral}{'A'} + pin);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00207}00207         \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00208}00208     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00209}00209     prt = pr.\mbox{\hyperlink{structprt__lookup__request_a5829bbdef3bb5062a2af8dbfc33526cc}{pr\_entry}};}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00210}00210 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00211}00211     \textcolor{keywordflow}{if} (bootverbose) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00212}00212         device\_printf(pcib, \textcolor{stringliteral}{"{}matched entry for \%d.\%d.INT\%c"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00213}00213             pci\_get\_bus(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), pci\_get\_slot(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), \textcolor{charliteral}{'A'} + pin);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00214}00214         \textcolor{keywordflow}{if} (prt-\/>Source[0] != \textcolor{charliteral}{'\(\backslash\)0'})}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00215}00215                 printf(\textcolor{stringliteral}{"{} (src \%s:\%u)"{}}, prt-\/>Source, prt-\/>SourceIndex);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00216}00216         printf(\textcolor{stringliteral}{"{}\(\backslash\)n"{}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00217}00217     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00218}00218 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00219}00219     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00220}00220 \textcolor{comment}{     * If source is empty/NULL, the source index is a global IRQ number}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00221}00221 \textcolor{comment}{     * and it's hard-\/wired so we're done.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00222}00222 \textcolor{comment}{     *}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00223}00223 \textcolor{comment}{     * XXX: If the source index is non-\/zero, ignore the source device and}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00224}00224 \textcolor{comment}{     * assume that this is a hard-\/wired entry.}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00225}00225 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00226}00226     \textcolor{keywordflow}{if} (prt-\/>Source[0] == \textcolor{charliteral}{'\(\backslash\)0'} || prt-\/>SourceIndex != 0) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00227}00227         \textcolor{keywordflow}{if} (bootverbose)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00228}00228             device\_printf(pcib, \textcolor{stringliteral}{"{}slot \%d INT\%c hardwired to IRQ \%d\(\backslash\)n"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00229}00229                 pci\_get\_slot(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), \textcolor{charliteral}{'A'} + pin, prt-\/>SourceIndex);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00230}00230         \textcolor{keywordflow}{if} (prt-\/>SourceIndex) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00231}00231             interrupt = prt-\/>SourceIndex;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00232}00232             BUS\_CONFIG\_INTR(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, interrupt, INTR\_TRIGGER\_LEVEL,}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00233}00233                 INTR\_POLARITY\_LOW);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00234}00234         \} \textcolor{keywordflow}{else}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00235}00235             device\_printf(pcib, \textcolor{stringliteral}{"{}error: invalid hard-\/wired IRQ of 0\(\backslash\)n"{}});}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00236}00236         \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00237}00237     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00238}00238 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00239}00239     \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00240}00240 \textcolor{comment}{     * We have to find the source device (PCI interrupt link device).}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00241}00241 \textcolor{comment}{     */}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00242}00242     \textcolor{keywordflow}{if} (ACPI\_FAILURE(AcpiGetHandle(ACPI\_ROOT\_OBJECT, prt-\/>Source, \&lnkdev))) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00243}00243         device\_printf(pcib, \textcolor{stringliteral}{"{}couldn't find PCI interrupt link device \%s\(\backslash\)n"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00244}00244             prt-\/>Source);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00245}00245         \textcolor{keywordflow}{goto} out;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00246}00246     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00247}00247     interrupt = \mbox{\hyperlink{acpi__pci__link_8c_a54e211b8e3613fe08b4ec9821b709837}{acpi\_pci\_link\_route\_interrupt}}(\mbox{\hyperlink{acpivar_8h_a167b31c02c02b6e32b4183cdcafc5ddd}{acpi\_get\_device}}(lnkdev),}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00248}00248         prt-\/>SourceIndex);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00249}00249 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00250}00250     \textcolor{keywordflow}{if} (bootverbose \&\& PCI\_INTERRUPT\_VALID(interrupt))}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00251}00251         device\_printf(pcib, \textcolor{stringliteral}{"{}slot \%d INT\%c routed to irq \%d via \%s\(\backslash\)n"{}},}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00252}00252             pci\_get\_slot(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}), \textcolor{charliteral}{'A'} + pin, interrupt, \mbox{\hyperlink{acpi_8c_a06c3bc79994c8a4f6835c134dd3d50f2}{acpi\_name}}(lnkdev));}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00253}00253 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00254}00254 out:}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00255}00255     \mbox{\hyperlink{acpivar_8h_aa1f610624b7c6dde01ed069c71cb791b}{ACPI\_SERIAL\_END}}(pcib);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00256}00256 \textcolor{preprocessor}{\#ifdef INTRNG}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00257}00257     \textcolor{keywordflow}{if} (PCI\_INTERRUPT\_VALID(interrupt)) \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00258}00258         interrupt  = acpi\_map\_intr(\mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, interrupt, lnkdev);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00259}00259         KASSERT(PCI\_INTERRUPT\_VALID(interrupt), (\textcolor{stringliteral}{"{}mapping fail"{}}));}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00260}00260     \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00261}00261 \textcolor{preprocessor}{\#endif}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00262}00262     return\_VALUE(interrupt);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00263}00263 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00264}00264 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00265}00265 \textcolor{keywordtype}{int}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00266}\mbox{\hyperlink{acpi__pcib_8c_a789bb07f61ea692d4aa09bca163dab13}{00266}} \mbox{\hyperlink{acpi__pcib_8c_a789bb07f61ea692d4aa09bca163dab13}{acpi\_pcib\_power\_for\_sleep}}(device\_t pcib, device\_t \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, \textcolor{keywordtype}{int} *pstate)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00267}00267 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00268}00268     device\_t acpi\_dev;}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00269}00269 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00270}00270     acpi\_dev = devclass\_get\_device(devclass\_find(\textcolor{stringliteral}{"{}acpi"{}}), 0);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00271}00271     \mbox{\hyperlink{acpi_8c_a1c9d5c386d094284f2de3e35618c50f1}{acpi\_device\_pwr\_for\_sleep}}(acpi\_dev, \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, pstate);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00272}00272     \textcolor{keywordflow}{return} (0);}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00273}00273 \}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00274}00274 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00275}00275 \textcolor{keywordtype}{int}}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00276}\mbox{\hyperlink{acpi__pcib_8c_a6113a8e04526d98fdd882f66550465e0}{00276}} \mbox{\hyperlink{acpi__pcib_8c_a6113a8e04526d98fdd882f66550465e0}{acpi\_pcib\_get\_cpus}}(device\_t pcib, device\_t \mbox{\hyperlink{acpi__bus__if_8m_a5b84348f4a546955afe3156099e597f4}{dev}}, \textcolor{keyword}{enum} cpu\_sets op,}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00277}00277     \textcolor{keywordtype}{size\_t} setsize, cpuset\_t *cpuset)}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00278}00278 \{}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00279}00279 }
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00280}00280         \textcolor{keywordflow}{return} (bus\_get\_cpus(pcib, op, setsize, cpuset));}
\DoxyCodeLine{\Hypertarget{acpi__pcib_8c_source_l00281}00281 \}}

\end{DoxyCode}
