forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/gpu/drm/rcar-du/rcar_du_vsp.h
....@@ -1,24 +1,21 @@
1
+/* SPDX-License-Identifier: GPL-2.0+ */
12 /*
23 * rcar_du_vsp.h -- R-Car Display Unit VSP-Based Compositor
34 *
45 * Copyright (C) 2015 Renesas Electronics Corporation
56 *
67 * Contact: Laurent Pinchart (laurent.pinchart@ideasonboard.com)
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the terms of the GNU General Public License as published by
10
- * the Free Software Foundation; either version 2 of the License, or
11
- * (at your option) any later version.
128 */
139
1410 #ifndef __RCAR_DU_VSP_H__
1511 #define __RCAR_DU_VSP_H__
1612
17
-#include <drm/drmP.h>
18
-#include <drm/drm_crtc.h>
13
+#include <drm/drm_plane.h>
1914
15
+struct drm_framebuffer;
2016 struct rcar_du_format_info;
2117 struct rcar_du_vsp;
18
+struct sg_table;
2219
2320 struct rcar_du_vsp_plane {
2421 struct drm_plane plane;
....@@ -65,6 +62,10 @@
6562 void rcar_du_vsp_disable(struct rcar_du_crtc *crtc);
6663 void rcar_du_vsp_atomic_begin(struct rcar_du_crtc *crtc);
6764 void rcar_du_vsp_atomic_flush(struct rcar_du_crtc *crtc);
65
+int rcar_du_vsp_map_fb(struct rcar_du_vsp *vsp, struct drm_framebuffer *fb,
66
+ struct sg_table sg_tables[3]);
67
+void rcar_du_vsp_unmap_fb(struct rcar_du_vsp *vsp, struct drm_framebuffer *fb,
68
+ struct sg_table sg_tables[3]);
6869 #else
6970 static inline int rcar_du_vsp_init(struct rcar_du_vsp *vsp,
7071 struct device_node *np,
....@@ -76,6 +77,17 @@
7677 static inline void rcar_du_vsp_disable(struct rcar_du_crtc *crtc) { };
7778 static inline void rcar_du_vsp_atomic_begin(struct rcar_du_crtc *crtc) { };
7879 static inline void rcar_du_vsp_atomic_flush(struct rcar_du_crtc *crtc) { };
80
+static inline int rcar_du_vsp_map_fb(struct rcar_du_vsp *vsp,
81
+ struct drm_framebuffer *fb,
82
+ struct sg_table sg_tables[3])
83
+{
84
+ return -ENXIO;
85
+}
86
+static inline void rcar_du_vsp_unmap_fb(struct rcar_du_vsp *vsp,
87
+ struct drm_framebuffer *fb,
88
+ struct sg_table sg_tables[3])
89
+{
90
+}
7991 #endif
8092
8193 #endif /* __RCAR_DU_VSP_H__ */