xref: /rk3399_rockchip-uboot/drivers/video/drm/drm_of.h (revision e60b026785da96e7717a915cc49de297f487d63f)
1 /* SPDX-License-Identifier: GPL-2.0+ */
2 /*
3  * (C) Copyright 2023 Rockchip Electronics Co., Ltd
4  *
5  */
6 #ifndef __DRM_OF_H__
7 #define __DRM_OF_H__
8 
9 #include <dm/ofnode.h>
10 #include <dm/of_access.h>
11 
12 /**
13  * enum drm_lvds_dual_link_pixels - Pixel order of an LVDS dual-link connection
14  * @DRM_LVDS_DUAL_LINK_EVEN_ODD_PIXELS: Even pixels are expected to be
15  *    generated from the first port, odd pixels from the second port
16  * @DRM_LVDS_DUAL_LINK_ODD_EVEN_PIXELS: Odd pixels are expected to be
17  *    generated from the first port, even pixels from the second port
18  * @DRM_LVDS_DUAL_LINK_LEFT_RIGHT_PIXELS: Left pixels are expected to be
19  *    generated from the first port, right pixels from the second port
20  * @DRM_LVDS_DUAL_LINK_RIGHT_LEFT_PIXELS: Right pixels are expected to be
21  *    generated from the first port, left pixels from the second port
22  */
23 enum drm_lvds_dual_link_pixels {
24 	DRM_LVDS_DUAL_LINK_EVEN_ODD_PIXELS = 0,
25 	DRM_LVDS_DUAL_LINK_ODD_EVEN_PIXELS = 1,
26 	DRM_LVDS_DUAL_LINK_LEFT_RIGHT_PIXELS = 2,
27 	DRM_LVDS_DUAL_LINK_RIGHT_LEFT_PIXELS = 3,
28 };
29 
30 int drm_of_lvds_get_dual_link_pixel_order(const struct device_node *port1,
31 					  const struct device_node *port2);
32 
33 #endif
34