From: John Wei <john.wei@xxxxxxxxxxxx> Add enable, hsize, vsize, user_data_desc to frame descriptors This patch is derived from following patches https://patchwork.kernel.org/patch/10875875/ https://patchwork.kernel.org/patch/10875869/ Signed-off-by: John Wei <john.wei@xxxxxxxxxxxx> --- include/media/v4l2-subdev.h | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/include/media/v4l2-subdev.h b/include/media/v4l2-subdev.h index 30ec011..f603831 100644 --- a/include/media/v4l2-subdev.h +++ b/include/media/v4l2-subdev.h @@ -308,15 +308,38 @@ struct v4l2_subdev_audio_ops { int (*s_stream)(struct v4l2_subdev *sd, int enable); }; +enum v4l2_mbus_csi2_user_defined_data_desc { + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_NONE, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_Y_HIST, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_AE_HIST, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_FLICKER, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_GYRO, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_PDAF_PIXEL, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_PDAF_DIFF, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_HDR_LE, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_HDR_ME, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_HDR_SE, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_HDR_SSE, + V4L2_MBUS_CSI2_USER_DEFINED_DATA_DESC_HDR_SSSE, +}; + /** * struct v4l2_mbus_frame_desc_entry_csi2 * * @channel: CSI-2 virtual channel * @data_type: CSI-2 data type ID + * @enable: enable this data identifier + * @hsize: horizontal size + * @vsize: vertical size + * @user_data_desc: the description of user defined data */ struct v4l2_mbus_frame_desc_entry_csi2 { u8 channel; u8 data_type; + u8 enable; + u16 hsize; + u16 vsize; + enum v4l2_mbus_csi2_user_defined_data_desc user_data_desc; }; /** @@ -354,7 +377,7 @@ struct v4l2_mbus_frame_desc_entry { } bus; }; -#define V4L2_FRAME_DESC_ENTRY_MAX 4 +#define V4L2_FRAME_DESC_ENTRY_MAX 8 enum v4l2_mbus_frame_desc_type { V4L2_MBUS_FRAME_DESC_TYPE_PLATFORM, -- 1.7.9.5