1 /* SPDX-License-Identifier: GPL-2.0-only */
3 * Copyright (c) 2015 MediaTek Inc.
10 #include "mtk_ddp_comp.h"
12 #define MAX_CONNECTOR 2
13 #define DDP_COMPONENT_DRM_OVL_ADAPTOR (DDP_COMPONENT_ID_MAX + 1)
14 #define DDP_COMPONENT_DRM_ID_MAX (DDP_COMPONENT_DRM_OVL_ADAPTOR + 1)
31 struct mtk_drm_route
{
32 const unsigned int crtc_id
;
33 const unsigned int route_ddp
;
36 struct mtk_mmsys_driver_data
{
37 const unsigned int *main_path
;
38 unsigned int main_len
;
39 const unsigned int *ext_path
;
41 const unsigned int *third_path
;
42 unsigned int third_len
;
43 const struct mtk_drm_route
*conn_routes
;
44 unsigned int num_conn_routes
;
47 unsigned int mmsys_id
;
48 unsigned int mmsys_dev_num
;
55 struct mtk_drm_private
{
56 struct drm_device
*drm
;
57 struct device
*dma_dev
;
61 struct device_node
*mutex_node
;
62 struct device
*mutex_dev
;
63 struct device
*mmsys_dev
;
64 struct device_node
*comp_node
[DDP_COMPONENT_DRM_ID_MAX
];
65 struct mtk_ddp_comp ddp_comp
[DDP_COMPONENT_DRM_ID_MAX
];
66 struct mtk_mmsys_driver_data
*data
;
67 struct drm_atomic_state
*suspend_state
;
68 unsigned int mbox_index
;
69 struct mtk_drm_private
**all_drm_private
;
72 extern struct platform_driver mtk_disp_aal_driver
;
73 extern struct platform_driver mtk_disp_ccorr_driver
;
74 extern struct platform_driver mtk_disp_color_driver
;
75 extern struct platform_driver mtk_disp_gamma_driver
;
76 extern struct platform_driver mtk_disp_merge_driver
;
77 extern struct platform_driver mtk_disp_ovl_adaptor_driver
;
78 extern struct platform_driver mtk_disp_ovl_driver
;
79 extern struct platform_driver mtk_disp_rdma_driver
;
80 extern struct platform_driver mtk_dpi_driver
;
81 extern struct platform_driver mtk_dsi_driver
;
82 extern struct platform_driver mtk_ethdr_driver
;
83 extern struct platform_driver mtk_mdp_rdma_driver
;
84 extern struct platform_driver mtk_padding_driver
;
85 #endif /* MTK_DRM_DRV_H */