[libcamera-devel,v2,1/7,TEMP] include: linux: Update v4l2-controls.h

Message ID 20190827095008.11405-2-jacopo@jmondi.org
State Accepted
Headers show
Series
  • libcamera: camera_sensor: Collect camera location and sizes
Related show

Commit Message

Jacopo Mondi Aug. 27, 2019, 9:50 a.m. UTC
Import a temporary version of the v4l2-controls.h with the newly added
definition of V4L2_CID_CAMERA_SENSOR_LOCATION control.

This patch should be temporary applied waiting for the newly added
control to land in the mainline kernel version.

Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
---
 include/linux/v4l2-controls.h | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Laurent Pinchart Sept. 3, 2019, 8:16 p.m. UTC | #1
Hi Jacopo,

Thank you for the patch.

On Tue, Aug 27, 2019 at 11:50:01AM +0200, Jacopo Mondi wrote:
> Import a temporary version of the v4l2-controls.h with the newly added
> definition of V4L2_CID_CAMERA_SENSOR_LOCATION control.
> 
> This patch should be temporary applied waiting for the newly added
> control to land in the mainline kernel version.
> 
> Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
>  include/linux/v4l2-controls.h | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/include/linux/v4l2-controls.h b/include/linux/v4l2-controls.h
> index 06479f2fb3ae..28061cde5303 100644
> --- a/include/linux/v4l2-controls.h
> +++ b/include/linux/v4l2-controls.h
> @@ -881,6 +881,13 @@ enum v4l2_auto_focus_range {
>  #define V4L2_CID_PAN_SPEED			(V4L2_CID_CAMERA_CLASS_BASE+32)
>  #define V4L2_CID_TILT_SPEED			(V4L2_CID_CAMERA_CLASS_BASE+33)
>  
> +#define V4L2_CID_CAMERA_SENSOR_LOCATION		(V4L2_CID_CAMERA_CLASS_BASE+34)
> +#define V4L2_LOCATION_FRONT			0
> +#define V4L2_LOCATION_BACK			1
> +#define V4L2_LOCATION_EXTERNAL			2
> +
> +#define V4L2_CID_CAMERA_SENSOR_ROTATION		(V4L2_CID_CAMERA_CLASS_BASE+35)
> +
>  /* FM Modulator class control IDs */
>  
>  #define V4L2_CID_FM_TX_CLASS_BASE		(V4L2_CTRL_CLASS_FM_TX | 0x900)

Patch

diff --git a/include/linux/v4l2-controls.h b/include/linux/v4l2-controls.h
index 06479f2fb3ae..28061cde5303 100644
--- a/include/linux/v4l2-controls.h
+++ b/include/linux/v4l2-controls.h
@@ -881,6 +881,13 @@  enum v4l2_auto_focus_range {
 #define V4L2_CID_PAN_SPEED			(V4L2_CID_CAMERA_CLASS_BASE+32)
 #define V4L2_CID_TILT_SPEED			(V4L2_CID_CAMERA_CLASS_BASE+33)
 
+#define V4L2_CID_CAMERA_SENSOR_LOCATION		(V4L2_CID_CAMERA_CLASS_BASE+34)
+#define V4L2_LOCATION_FRONT			0
+#define V4L2_LOCATION_BACK			1
+#define V4L2_LOCATION_EXTERNAL			2
+
+#define V4L2_CID_CAMERA_SENSOR_ROTATION		(V4L2_CID_CAMERA_CLASS_BASE+35)
+
 /* FM Modulator class control IDs */
 
 #define V4L2_CID_FM_TX_CLASS_BASE		(V4L2_CTRL_CLASS_FM_TX | 0x900)