File: group__descriptor1__lib.html

package info (click to toggle)
xenomai 2.5.4-3squeeze1
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 36,140 kB
  • ctags: 35,509
  • sloc: ansic: 109,084; sh: 11,745; makefile: 2,205; xml: 1,356; asm: 613; php: 316; perl: 155
file content (355 lines) | stat: -rw-r--r-- 21,078 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Xenomai API: Descriptor API</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    <li>
      <form action="search.php" method="get">
        <table cellspacing="0" cellpadding="0" border="0">
          <tr>
            <td><label>&nbsp;<u>S</u>earch&nbsp;for&nbsp;</label></td>
            <td><input type="text" name="query" value="" size="20" accesskey="s"/></td>
          </tr>
        </table>
      </form>
    </li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>Descriptor API<br>
<small>
[<a class="el" href="group__level1__lib.html">Level 1 API</a>]</small>
</h1>
<p>
<div class="dynheader">
Collaboration diagram for Descriptor API:</div>
<div class="dynsection">
<center><table><tr><td><img src="group__descriptor1__lib.png" border="0" alt="" usemap="#group____descriptor1____lib_map">
<map name="group____descriptor1____lib_map">
<area shape="rect" href="group__level1__lib.html" title="Level 1 API" alt="" coords="5,5,96,32"></map></td></tr></table></center>
</div>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This is the API interface used to fill and use Analogy device descriptor structure 
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#g810401871fe8005ee0157c6910f94466">a4l_open</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc, const char *fname)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Open an Analogy device and basically fill the descriptor.  <a href="#g810401871fe8005ee0157c6910f94466"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#gd71964e99b5d0691a5fbe90410b80888">a4l_close</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Close the Analogy device related with the descriptor.  <a href="#gd71964e99b5d0691a5fbe90410b80888"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981">a4l_fill_desc</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Fill the descriptor with subdevices, channels and ranges data.  <a href="#g4899cdf9b31aa0cbe0d95bf3c2f2f981"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#g4200a3b0f33b20fedeadc0494491cc9c">a4l_get_subdinfo</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc, unsigned int subd, a4l_sbinfo_t **info)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get an information structure on a specified subdevice.  <a href="#g4200a3b0f33b20fedeadc0494491cc9c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#g3d8e5665d75101309eaf4690784917c7">a4l_get_chinfo</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc, unsigned int subd, unsigned int chan, a4l_chinfo_t **info)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get an information structure on a specified channel.  <a href="#g3d8e5665d75101309eaf4690784917c7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__descriptor1__lib.html#g1baacb426ed57054a99020c6b2a42baf">a4l_get_rnginfo</a> (<a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *dsc, unsigned int subd, unsigned int chan, unsigned int rng, a4l_rnginfo_t **info)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get an information structure on a specified range.  <a href="#g1baacb426ed57054a99020c6b2a42baf"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="gd71964e99b5d0691a5fbe90410b80888"></a><!-- doxytag: member="descriptor.c::a4l_close" ref="gd71964e99b5d0691a5fbe90410b80888" args="(a4l_desc_t *dsc)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_close           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Close the Analogy device related with the descriptor. 
<p>
The file descriptor is associated with a context. The context is one of the enabler of asynchronous transfers. So, by closing the file descriptor, the programer must keep in mind that the currently occuring asynchronous transfer will cancelled.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; the the dsc pointer should be checked; check also the kernel log ("dmesg") </li></ul>

<p>References <a class="el" href="sys_8c-source.html#l00073">a4l_sys_close()</a>, and <a class="el" href="descriptor_8h-source.html#l00076">a4l_descriptor::fd</a>.</p>

</div>
</div><p>
<a class="anchor" name="g4899cdf9b31aa0cbe0d95bf3c2f2f981"></a><!-- doxytag: member="descriptor.c::a4l_fill_desc" ref="g4899cdf9b31aa0cbe0d95bf3c2f2f981" args="(a4l_desc_t *dsc)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_fill_desc           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Fill the descriptor with subdevices, channels and ranges data. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor partly filled by <a class="el" href="group__descriptor1__lib.html#g810401871fe8005ee0157c6910f94466" title="Open an Analogy device and basically fill the descriptor.">a4l_open()</a>.</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; the the dsc pointer should be checked; check also the kernel log ("dmesg")</li><li>-EFAULT is returned if a user &lt;-&gt; kernel transfer went wrong</li><li>-ENODEV is returned if the descriptor is incoherent (the device may be unattached) </li></ul>

<p>References <a class="el" href="descriptor_8h-source.html#l00055">A4L_CPLX_DESC</a>, <a class="el" href="descriptor_8c-source.html#l00237">a4l_sys_desc()</a>, <a class="el" href="descriptor_8h-source.html#l00076">a4l_descriptor::fd</a>, and <a class="el" href="descriptor_8h-source.html#l00078">a4l_descriptor::magic</a>.</p>

</div>
</div><p>
<a class="anchor" name="g3d8e5665d75101309eaf4690784917c7"></a><!-- doxytag: member="descriptor.c::a4l_get_chinfo" ref="g3d8e5665d75101309eaf4690784917c7" args="(a4l_desc_t *dsc, unsigned int subd, unsigned int chan, a4l_chinfo_t **info)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_get_chinfo           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>subd</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>chan</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">a4l_chinfo_t **&nbsp;</td>
          <td class="paramname"> <em>info</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get an information structure on a specified channel. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor filled by <a class="el" href="group__descriptor1__lib.html#g810401871fe8005ee0157c6910f94466" title="Open an Analogy device and basically fill the descriptor.">a4l_open()</a> and <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>subd</em>&nbsp;</td><td>Subdevice index </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>chan</em>&nbsp;</td><td>Channel index </td></tr>
    <tr><td valign="top"><tt>[out]</tt>&nbsp;</td><td valign="top"><em>info</em>&nbsp;</td><td>Channel information structure</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; subd, chan and the dsc pointer should be checked; check also the kernel log ("dmesg"); WARNING: <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> should be called before using <a class="el" href="group__descriptor1__lib.html#g3d8e5665d75101309eaf4690784917c7" title="Get an information structure on a specified channel.">a4l_get_chinfo()</a> </li></ul>

<p>References <a class="el" href="descriptor_8h-source.html#l00078">a4l_descriptor::magic</a>, <a class="el" href="descriptor_8h-source.html#l00070">a4l_descriptor::nb_subd</a>, and <a class="el" href="descriptor_8h-source.html#l00082">a4l_descriptor::sbdata</a>.</p>

<p>Referenced by <a class="el" href="range_8c-source.html#l00166">a4l_find_range()</a>.</p>

</div>
</div><p>
<a class="anchor" name="g1baacb426ed57054a99020c6b2a42baf"></a><!-- doxytag: member="descriptor.c::a4l_get_rnginfo" ref="g1baacb426ed57054a99020c6b2a42baf" args="(a4l_desc_t *dsc, unsigned int subd, unsigned int chan, unsigned int rng, a4l_rnginfo_t **info)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_get_rnginfo           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>subd</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>chan</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>rng</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">a4l_rnginfo_t **&nbsp;</td>
          <td class="paramname"> <em>info</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get an information structure on a specified range. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor filled by <a class="el" href="group__descriptor1__lib.html#g810401871fe8005ee0157c6910f94466" title="Open an Analogy device and basically fill the descriptor.">a4l_open()</a> and <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>subd</em>&nbsp;</td><td>Subdevice index </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>chan</em>&nbsp;</td><td>Channel index </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>rng</em>&nbsp;</td><td>Range index </td></tr>
    <tr><td valign="top"><tt>[out]</tt>&nbsp;</td><td valign="top"><em>info</em>&nbsp;</td><td>Range information structure</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; subd, chan, rng and the dsc pointer should be checked; check also the kernel log ("dmesg"); WARNING: <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> should be called before using <a class="el" href="group__descriptor1__lib.html#g1baacb426ed57054a99020c6b2a42baf" title="Get an information structure on a specified range.">a4l_get_rnginfo()</a> </li></ul>

<p>References <a class="el" href="descriptor_8h-source.html#l00078">a4l_descriptor::magic</a>, <a class="el" href="descriptor_8h-source.html#l00070">a4l_descriptor::nb_subd</a>, and <a class="el" href="descriptor_8h-source.html#l00082">a4l_descriptor::sbdata</a>.</p>

<p>Referenced by <a class="el" href="range_8c-source.html#l00166">a4l_find_range()</a>.</p>

</div>
</div><p>
<a class="anchor" name="g4200a3b0f33b20fedeadc0494491cc9c"></a><!-- doxytag: member="descriptor.c::a4l_get_subdinfo" ref="g4200a3b0f33b20fedeadc0494491cc9c" args="(a4l_desc_t *dsc, unsigned int subd, a4l_sbinfo_t **info)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_get_subdinfo           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&nbsp;</td>
          <td class="paramname"> <em>subd</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">a4l_sbinfo_t **&nbsp;</td>
          <td class="paramname"> <em>info</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get an information structure on a specified subdevice. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor filled by <a class="el" href="group__descriptor1__lib.html#g810401871fe8005ee0157c6910f94466" title="Open an Analogy device and basically fill the descriptor.">a4l_open()</a> and <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>subd</em>&nbsp;</td><td>Subdevice index </td></tr>
    <tr><td valign="top"><tt>[out]</tt>&nbsp;</td><td valign="top"><em>info</em>&nbsp;</td><td>Subdevice information structure</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; subd and the dsc pointer should be checked; check also the kernel log ("dmesg"); WARNING: <a class="el" href="group__descriptor1__lib.html#g4899cdf9b31aa0cbe0d95bf3c2f2f981" title="Fill the descriptor with subdevices, channels and ranges data.">a4l_fill_desc()</a> should be called before using <a class="el" href="group__descriptor1__lib.html#g4200a3b0f33b20fedeadc0494491cc9c" title="Get an information structure on a specified subdevice.">a4l_get_subdinfo()</a>. </li></ul>

<p>References <a class="el" href="descriptor_8h-source.html#l00078">a4l_descriptor::magic</a>, <a class="el" href="descriptor_8h-source.html#l00070">a4l_descriptor::nb_subd</a>, and <a class="el" href="descriptor_8h-source.html#l00082">a4l_descriptor::sbdata</a>.</p>

<p>Referenced by <a class="el" href="sync_8c-source.html#l00277">a4l_sync_dio()</a>.</p>

</div>
</div><p>
<a class="anchor" name="g810401871fe8005ee0157c6910f94466"></a><!-- doxytag: member="descriptor.c::a4l_open" ref="g810401871fe8005ee0157c6910f94466" args="(a4l_desc_t *dsc, const char *fname)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int a4l_open           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structa4l__descriptor.html">a4l_desc_t</a> *&nbsp;</td>
          <td class="paramname"> <em>dsc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>fname</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Open an Analogy device and basically fill the descriptor. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"><tt>[out]</tt>&nbsp;</td><td valign="top"><em>dsc</em>&nbsp;</td><td>Device descriptor </td></tr>
    <tr><td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>fname</em>&nbsp;</td><td>Device name</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 on success. Otherwise:</dd></dl>
<ul>
<li>-EINVAL is returned if some argument is missing or wrong; the fname and the dsc pointer should be checked; check also the kernel log ("dmesg")</li><li>-EFAULT is returned if a user &lt;-&gt; kernel transfer went wrong </li></ul>

<p>References <a class="el" href="descriptor_8h-source.html#l00049">A4L_BSC_DESC</a>, <a class="el" href="sys_8c-source.html#l00073">a4l_sys_close()</a>, <a class="el" href="descriptor_8c-source.html#l00237">a4l_sys_desc()</a>, <a class="el" href="sys_8c-source.html#l00060">a4l_sys_open()</a>, and <a class="el" href="descriptor_8h-source.html#l00076">a4l_descriptor::fd</a>.</p>

</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Mon Aug 2 12:48:39 2010 for Xenomai API by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address>
</body>
</html>