aboutsummaryrefslogtreecommitdiff
path: root/include/media
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2012-03-21 08:03:28 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-05-15 16:12:54 -0300
commit914f05c8118e17d65c4626ae3ed2edcf79f00031 (patch)
treeb41353c64be1394015f7c976fbafb299b61c21e8 /include/media
parentb0a461ff1b476067c24131ea0b2a40571592f761 (diff)
[media] soc-camera: Support user-configurable line stride
Add a capabilities field to the soc_camera_host structure to flag hosts that support user-configurable line strides. soc_camera_try_fmt() then passes the user-provided bytesperline and sizeimage format fields to such hosts, and expects the host to check (and fix if needed) the values. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> [g.liakhovetski@gmx.de: fix a typo in mx2_camera.c] Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include/media')
-rw-r--r--include/media/soc_camera.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/media/soc_camera.h b/include/media/soc_camera.h
index a87062c393b..d865dcf9879 100644
--- a/include/media/soc_camera.h
+++ b/include/media/soc_camera.h
@@ -56,11 +56,15 @@ struct soc_camera_device {
};
};
+/* Host supports programmable stride */
+#define SOCAM_HOST_CAP_STRIDE (1 << 0)
+
struct soc_camera_host {
struct v4l2_device v4l2_dev;
struct list_head list;
struct mutex host_lock; /* Protect during probing */
unsigned char nr; /* Host number */
+ u32 capabilities;
void *priv;
const char *drv_name;
struct soc_camera_host_ops *ops;