1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>snd_ac97_pcm_assign</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="The ALSA Driver API"><link rel="up" href="ch03s02.html" title="AC97 Codec API"><link rel="prev" href="API-snd-ac97-set-rate.html" title="snd_ac97_set_rate"><link rel="next" href="API-snd-ac97-pcm-open.html" title="snd_ac97_pcm_open"></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">snd_ac97_pcm_assign</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-snd-ac97-set-rate.html">Prev</a> </td><th width="60%" align="center">AC97 Codec API</th><td width="20%" align="right"> <a accesskey="n" href="API-snd-ac97-pcm-open.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-snd-ac97-pcm-assign"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>snd_ac97_pcm_assign — 2 assign AC97 slots to given PCM streams 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">snd_ac97_pcm_assign </b>(</code></td><td>struct snd_ac97_bus * <var class="pdparam">bus</var>, </td></tr><tr><td> </td><td>unsigned short <var class="pdparam">pcms_count</var>, </td></tr><tr><td> </td><td>const struct ac97_pcm * <var class="pdparam">pcms</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a name="idp1094777956"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>bus</code></em></span></dt><dd><p> 4 the ac97 bus instance 5 </p></dd><dt><span class="term"><em class="parameter"><code>pcms_count</code></em></span></dt><dd><p> 6 count of PCMs to be assigned 7 </p></dd><dt><span class="term"><em class="parameter"><code>pcms</code></em></span></dt><dd><p> 8 PCMs to be assigned 9 </p></dd></dl></div></div><div class="refsect1"><a name="idp1094781612"></a><h2>Description</h2><p> 10 It assigns available AC97 slots for given PCMs. If none or only 11 some slots are available, pcm->xxx.slots and pcm->xxx.rslots[] members 12 are reduced and might be zero. 13</p></div><div class="refsect1"><a name="idp1094782420"></a><h2>Return</h2><p> 14 Zero if successful, or a negative error code on failure. 15</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-snd-ac97-set-rate.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch03s02.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-snd-ac97-pcm-open.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">snd_ac97_set_rate</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">snd_ac97_pcm_open</span></td></tr></table></div></body></html> 16