1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>__pci_register_driver</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="The Linux Kernel API"><link rel="up" href="ch09s05.html" title="PCI Support Library"><link rel="prev" href="API-pci-match-id.html" title="pci_match_id"><link rel="next" href="API-pci-unregister-driver.html" title="pci_unregister_driver"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">__pci_register_driver</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-pci-match-id.html">Prev</a> </td><th width="60%" align="center">PCI Support Library</th><td width="20%" align="right"> <a accesskey="n" href="API-pci-unregister-driver.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API---pci-register-driver"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>__pci_register_driver — 2 register a new pci driver 3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">int <b class="fsfunc">__pci_register_driver </b>(</code></td><td>struct pci_driver * <var class="pdparam">drv</var>, </td></tr><tr><td> </td><td>struct module * <var class="pdparam">owner</var>, </td></tr><tr><td> </td><td>const char * <var class="pdparam">mod_name</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a name="idp1126683348"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>drv</code></em></span></dt><dd><p> 4 the driver structure to register 5 </p></dd><dt><span class="term"><em class="parameter"><code>owner</code></em></span></dt><dd><p> 6 owner module of drv 7 </p></dd><dt><span class="term"><em class="parameter"><code>mod_name</code></em></span></dt><dd><p> 8 module name string 9 </p></dd></dl></div></div><div class="refsect1"><a name="idp1126687004"></a><h2>Description</h2><p> 10 Adds the driver structure to the list of registered drivers. 11 Returns a negative value on error, otherwise 0. 12 If no error occurred, the driver remains registered even if 13 no device was claimed during registration. 14</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-pci-match-id.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch09s05.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-pci-unregister-driver.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">pci_match_id</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">pci_unregister_driver</span></td></tr></table></div></body></html> 15