xref: /openbmc/linux/include/media/mipi-csi2.h (revision 5cadbd89)
1*5cadbd89SLaurent Pinchart /* SPDX-License-Identifier: GPL-2.0-only */
2*5cadbd89SLaurent Pinchart /*
3*5cadbd89SLaurent Pinchart  * MIPI CSI-2 Data Types
4*5cadbd89SLaurent Pinchart  *
5*5cadbd89SLaurent Pinchart  * Copyright (C) 2022 Laurent Pinchart <laurent.pinchart@ideasonboard.com>
6*5cadbd89SLaurent Pinchart  */
7*5cadbd89SLaurent Pinchart 
8*5cadbd89SLaurent Pinchart #ifndef _MEDIA_MIPI_CSI2_H
9*5cadbd89SLaurent Pinchart #define _MEDIA_MIPI_CSI2_H
10*5cadbd89SLaurent Pinchart 
11*5cadbd89SLaurent Pinchart /* Short packet data types */
12*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_FS			0x00
13*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_FE			0x01
14*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_LS			0x02
15*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_LE			0x03
16*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_GENERIC_SHORT(n)	(0x08 + (n))	/* 0..7 */
17*5cadbd89SLaurent Pinchart 
18*5cadbd89SLaurent Pinchart /* Long packet data types */
19*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_NULL		0x10
20*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_BLANKING		0x11
21*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_EMBEDDED_8B	0x12
22*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV420_8B		0x18
23*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV420_10B		0x19
24*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV420_8B_LEGACY	0x1a
25*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV420_8B_CS	0x1c
26*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV420_10B_CS	0x1d
27*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV422_8B		0x1e
28*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_YUV422_10B		0x1f
29*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RGB444		0x20
30*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RGB555		0x21
31*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RGB565		0x22
32*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RGB666		0x23
33*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RGB888		0x24
34*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW24		0x27
35*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW6		0x28
36*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW7		0x29
37*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW8		0x2a
38*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW10		0x2b
39*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW12		0x2c
40*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW14		0x2d
41*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW16		0x2e
42*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_RAW20		0x2f
43*5cadbd89SLaurent Pinchart #define MIPI_CSI2_DT_USER_DEFINED(n)	(0x30 + (n))	/* 0..7 */
44*5cadbd89SLaurent Pinchart 
45*5cadbd89SLaurent Pinchart #endif /* _MEDIA_MIPI_CSI2_H */
46