1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>dma_buf_export</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="Linux Device Drivers"><link rel="up" href="ch02s03.html" title="Device Drivers DMA Management"><link rel="prev" href="ch02s03.html" title="Device Drivers DMA Management"><link rel="next" href="API-dma-buf-fd.html" title="dma_buf_fd"></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">dma_buf_export</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch02s03.html">Prev</a>&#160;</td><th width="60%" align="center">Device Drivers DMA Management</th><td width="20%" align="right">&#160;<a accesskey="n" href="API-dma-buf-fd.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-dma-buf-export"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>dma_buf_export &#8212; 
2  Creates a new dma_buf, and associates an anon file with this buffer, so it can be exported. Also connect the allocator specific data and ops to the buffer. Additionally, provide a name string for exporter; useful in debugging.
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">struct dma_buf * <b class="fsfunc">dma_buf_export </b>(</code></td><td>const struct dma_buf_export_info * <var class="pdparam">exp_info</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div></div><div class="refsect1"><a name="idp1110142348"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>exp_info</code></em></span></dt><dd><p>
4     [in]	holds all the export related information provided
5     by the exporter. see struct dma_buf_export_info
6     for further details.
7    </p></dd></dl></div></div><div class="refsect1"><a name="idp1110144076"></a><h2>Description</h2><p>
8   Returns, on success, a newly created dma_buf object, which wraps the
9   supplied private data and operations for dma_buf_ops. On either missing
10   ops, or error in allocating struct dma_buf, will return negative error.
11</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch02s03.html">Prev</a>&#160;</td><td width="20%" align="center"><a accesskey="u" href="ch02s03.html">Up</a></td><td width="40%" align="right">&#160;<a accesskey="n" href="API-dma-buf-fd.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Device Drivers DMA Management&#160;</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">&#160;<span class="phrase">dma_buf_fd</span></td></tr></table></div></body></html>
12