diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-09-15 14:09:03 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-09-15 14:09:03 -0300 |
commit | 5c742b688922417548eae7f84f8979c6e08d9692 (patch) | |
tree | 061ccba74878c6885fe91563ae9e616b88e4a7ee /staging-specs/v4l/func-munmap.xml | |
parent | a7ec580399a117b5f3320f4e0b252d0ba87917ba (diff) | |
parent | 6c7152d8e7cab73ccc06346104d485dd0c03aa19 (diff) | |
download | mediapointer-dvb-s2-5c742b688922417548eae7f84f8979c6e08d9692.tar.gz mediapointer-dvb-s2-5c742b688922417548eae7f84f8979c6e08d9692.tar.bz2 |
merge: http://linuxtv.org/hg/~awalls/v4l-dvb
From: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'staging-specs/v4l/func-munmap.xml')
-rw-r--r-- | staging-specs/v4l/func-munmap.xml | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/staging-specs/v4l/func-munmap.xml b/staging-specs/v4l/func-munmap.xml new file mode 100644 index 000000000..502ed4932 --- /dev/null +++ b/staging-specs/v4l/func-munmap.xml @@ -0,0 +1,83 @@ +<refentry id="func-munmap"> + <refmeta> + <refentrytitle>V4L2 munmap()</refentrytitle> + &manvol; + </refmeta> + + <refnamediv> + <refname>v4l2-munmap</refname> + <refpurpose>Unmap device memory</refpurpose> + </refnamediv> + + <refsynopsisdiv> + <funcsynopsis> + <funcsynopsisinfo> +#include <unistd.h> +#include <sys/mman.h></funcsynopsisinfo> + <funcprototype> + <funcdef>int <function>munmap</function></funcdef> + <paramdef>void *<parameter>start</parameter></paramdef> + <paramdef>size_t <parameter>length</parameter></paramdef> + </funcprototype> + </funcsynopsis> + </refsynopsisdiv> + <refsect1> + <title>Arguments</title> + <variablelist> + <varlistentry> + <term><parameter>start</parameter></term> + <listitem> + <para>Address of the mapped buffer as returned by the +&func-mmap; function.</para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>length</parameter></term> + <listitem> + <para>Length of the mapped buffer. This must be the same +value as given to <function>mmap()</function> and returned by the +driver in the &v4l2-buffer; <structfield>length</structfield> +field.</para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1> + <title>Description</title> + + <para>Unmaps a previously with the &func-mmap; function mapped +buffer and frees it, if possible. <!-- ? This function (not freeing) +has no impact on I/O in progress, specifically it does not imply +&VIDIOC-STREAMOFF; to terminate I/O. Unmapped buffers can still be +enqueued, dequeued or queried, they are just not accessible by the +application.--></para> + </refsect1> + + <refsect1> + <title>Return Value</title> + + <para>On success <function>munmap()</function> returns 0, on +failure -1 and the <varname>errno</varname> variable is set +appropriately:</para> + + <variablelist> + <varlistentry> + <term><errorcode>EINVAL</errorcode></term> + <listitem> + <para>The <parameter>start</parameter> or +<parameter>length</parameter> is incorrect, or no buffers have been +mapped yet.</para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> +</refentry> + +<!-- +Local Variables: +mode: sgml +sgml-parent-document: "v4l2.sgml" +indent-tabs-mode: nil +End: +--> |