git: 7392ea254c81 - stable/13 - linuxkpi: Add video/mipi_display.h

From: Emmanuel Vadot <manu_at_FreeBSD.org>
Date: Wed, 07 Sep 2022 15:10:40 UTC
The branch stable/13 has been updated by manu:

URL: https://cgit.FreeBSD.org/src/commit/?id=7392ea254c81069cfe9759cfeb0b57f3c4c1c916

commit 7392ea254c81069cfe9759cfeb0b57f3c4c1c916
Author:     Emmanuel Vadot <manu@FreeBSD.org>
AuthorDate: 2022-08-09 09:40:34 +0000
Commit:     Emmanuel Vadot <manu@FreeBSD.org>
CommitDate: 2022-09-07 15:09:06 +0000

    linuxkpi: Add video/mipi_display.h
    
    Needed by drm-kmod.
    
    Reviewed by:    bz
    Obtained from:  OpenBSD
    Sponsored by:   Beckhoff Automation GmbH & Co. KG
    Differential Revision:  https://reviews.freebsd.org/D36103
    
    (cherry picked from commit 73e342328b538e5936f248c03a299884dbe22047)
---
 .../linuxkpi/common/include/video/mipi_display.h   | 64 ++++++++++++++++++++++
 1 file changed, 64 insertions(+)

diff --git a/sys/compat/linuxkpi/common/include/video/mipi_display.h b/sys/compat/linuxkpi/common/include/video/mipi_display.h
new file mode 100644
index 000000000000..ea079a57d39f
--- /dev/null
+++ b/sys/compat/linuxkpi/common/include/video/mipi_display.h
@@ -0,0 +1,64 @@
+/* Public domain. */
+
+#ifndef _LINUXKPI_VIDEO_MIPI_DISPLAY_H_
+#define	_LINUXKPI_VIDEO_MIPI_DISPLAY_H_
+
+#define MIPI_DSI_V_SYNC_START			0x01
+#define MIPI_DSI_V_SYNC_END			0x11
+#define MIPI_DSI_H_SYNC_START			0x21
+#define MIPI_DSI_H_SYNC_END			0x31
+#define MIPI_DSI_COMPRESSION_MODE		0x07
+#define MIPI_DSI_END_OF_TRANSMISSION		0x08
+#define MIPI_DSI_COLOR_MODE_OFF			0x02
+#define MIPI_DSI_COLOR_MODE_ON			0x12
+#define MIPI_DSI_SHUTDOWN_PERIPHERAL		0x22
+#define MIPI_DSI_TURN_ON_PERIPHERAL		0x32
+#define MIPI_DSI_GENERIC_SHORT_WRITE_0_PARAM	0x03
+#define MIPI_DSI_GENERIC_SHORT_WRITE_1_PARAM	0x13
+#define MIPI_DSI_GENERIC_SHORT_WRITE_2_PARAM	0x23
+#define MIPI_DSI_GENERIC_READ_REQUEST_0_PARAM	0x04
+#define MIPI_DSI_GENERIC_READ_REQUEST_1_PARAM	0x14
+#define MIPI_DSI_GENERIC_READ_REQUEST_2_PARAM	0x24
+#define MIPI_DSI_DCS_SHORT_WRITE		0x05
+#define MIPI_DSI_DCS_SHORT_WRITE_PARAM		0x15
+#define MIPI_DSI_DCS_READ			0x06
+#define MIPI_DSI_EXECUTE_QUEUE			0x16
+#define MIPI_DSI_SET_MAXIMUM_RETURN_PACKET_SIZE	0x37
+#define MIPI_DSI_NULL_PACKET			0x09
+#define MIPI_DSI_BLANKING_PACKET		0x19
+#define MIPI_DSI_GENERIC_LONG_WRITE		0x29
+#define MIPI_DSI_DCS_LONG_WRITE			0x39
+#define MIPI_DSI_PICTURE_PARAMETER_SET		0x0a
+#define MIPI_DSI_COMPRESSED_PIXEL_STREAM	0x0b
+#define MIPI_DSI_LOOSELY_PACKED_PIXEL_STREAM_YCBCR20	0x0c
+#define MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR24	0x1c
+#define MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR16	0x2c
+#define MIPI_DSI_PACKED_PIXEL_STREAM_30		0x0d
+#define MIPI_DSI_PACKED_PIXEL_STREAM_36		0x1d
+#define MIPI_DSI_PACKED_PIXEL_STREAM_YCBCR12	0x3d
+#define MIPI_DSI_PACKED_PIXEL_STREAM_16		0x0e
+#define MIPI_DSI_PACKED_PIXEL_STREAM_18		0x1e
+#define MIPI_DSI_PIXEL_STREAM_3BYTE_18		0x2e
+#define MIPI_DSI_PACKED_PIXEL_STREAM_24		0x3e
+
+#define MIPI_DCS_NOP				0x00
+#define MIPI_DCS_SOFT_RESET			0x01
+#define MIPI_DCS_GET_POWER_MODE			0x0a
+#define MIPI_DCS_GET_PIXEL_FORMAT		0x0c
+#define MIPI_DCS_ENTER_SLEEP_MODE		0x10
+#define MIPI_DCS_EXIT_SLEEP_MODE		0x11
+#define MIPI_DCS_SET_DISPLAY_OFF		0x28
+#define MIPI_DCS_SET_DISPLAY_ON			0x29
+#define MIPI_DCS_SET_COLUMN_ADDRESS		0x2a
+#define MIPI_DCS_SET_PAGE_ADDRESS		0x2b
+#define MIPI_DCS_SET_TEAR_OFF			0x34
+#define MIPI_DCS_SET_TEAR_ON			0x35
+#define MIPI_DCS_SET_PIXEL_FORMAT		0x3a
+#define MIPI_DCS_SET_TEAR_SCANLINE		0x44
+#define MIPI_DCS_SET_DISPLAY_BRIGHTNESS		0x51
+#define MIPI_DCS_GET_DISPLAY_BRIGHTNESS		0x52
+#define MIPI_DCS_WRITE_CONTROL_DISPLAY		0x53
+#define MIPI_DCS_GET_CONTROL_DISPLAY		0x54
+#define MIPI_DCS_WRITE_POWER_SAVE		0x55
+
+#endif	/* _LINUXKPI_VIDEO_MIPI_DISPLAY_H_ */