summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2009-02-20 09:55:39 +0100
committerHans Verkuil <hverkuil@xs4all.nl>2009-02-20 09:55:39 +0100
commitd9920c08abb43a90d2d28c424ed1bafddd00cefe (patch)
tree3868d2ccb74ee15a774bb2f32d20e79c125017dd
parentb2e7077468076b3bfb3f6ad572808dab4a8795ae (diff)
downloadmediapointer-dvb-s2-d9920c08abb43a90d2d28c424ed1bafddd00cefe.tar.gz
mediapointer-dvb-s2-d9920c08abb43a90d2d28c424ed1bafddd00cefe.tar.bz2
v4l2: add V4L2_CTRL_FLAG_WRITE_ONLY flag.
From: Hans Verkuil <hverkuil@xs4all.nl> Priority: normal Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
-rw-r--r--linux/include/linux/videodev2.h1
-rw-r--r--v4l2-spec/compat.sgml3
-rw-r--r--v4l2-spec/vidioc-queryctrl.sgml15
3 files changed, 19 insertions, 0 deletions
diff --git a/linux/include/linux/videodev2.h b/linux/include/linux/videodev2.h
index 6969c3086..4167a0b44 100644
--- a/linux/include/linux/videodev2.h
+++ b/linux/include/linux/videodev2.h
@@ -830,6 +830,7 @@ struct v4l2_querymenu {
#define V4L2_CTRL_FLAG_UPDATE 0x0008
#define V4L2_CTRL_FLAG_INACTIVE 0x0010
#define V4L2_CTRL_FLAG_SLIDER 0x0020
+#define V4L2_CTRL_FLAG_WRITE_ONLY 0x0040
/* Query flag, to be ORed with the control ID */
#define V4L2_CTRL_FLAG_NEXT_CTRL 0x80000000
diff --git a/v4l2-spec/compat.sgml b/v4l2-spec/compat.sgml
index 1ee7c4a82..94713023d 100644
--- a/v4l2-spec/compat.sgml
+++ b/v4l2-spec/compat.sgml
@@ -2287,6 +2287,9 @@ was renamed to <structname id=v4l2-chip-ident-old>v4l2_chip_ident_old</structnam
<title>V4L2 in Linux 2.6.30</title>
<orderedlist>
<listitem>
+ <para>New control flag <constant>V4L2_CTRL_FLAG_WRITE_ONLY</constant> was added.</para>
+ </listitem>
+ <listitem>
<para>New control <constant>V4L2_CID_COLORFX</constant> was added.</para>
</listitem>
</orderedlist>
diff --git a/v4l2-spec/vidioc-queryctrl.sgml b/v4l2-spec/vidioc-queryctrl.sgml
index 20c4147eb..9908a964d 100644
--- a/v4l2-spec/vidioc-queryctrl.sgml
+++ b/v4l2-spec/vidioc-queryctrl.sgml
@@ -361,6 +361,15 @@ control.</entry>
<entry>A hint that this control is best represented as a
slider-like element in a user interface.</entry>
</row>
+ <row>
+ <entry><constant>V4L2_CTRL_FLAG_WRITE_ONLY</constant></entry>
+ <entry>0x0040</entry>
+ <entry>This control is permanently writable only. Any
+attempt to read the control will result in an &EACCES; error code. This
+flag is typically present for relative controls or action controls where
+writing a value will cause the device to carry out a given action
+(&eg; motor control) but no meaningful value can be returned.</entry>
+ </row>
</tbody>
</tgroup>
</table>
@@ -378,6 +387,12 @@ is invalid. The &v4l2-querymenu; <structfield>id</structfield> or
<structfield>index</structfield> is invalid.</para>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><errorcode>EACCES</errorcode></term>
+ <listitem>
+ <para>An attempt was made to read a write-only control.</para>
+ </listitem>
+ </varlistentry>
</variablelist>
</refsect1>
</refentry>