summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/rcar-du/rcar_du_drv.h
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>2013-06-16 23:01:02 +0400
committerLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>2013-08-10 01:17:46 +0400
commitcb2025d2509ffab1c426509fd9de3d83e40398b9 (patch)
treef09c3a2637c1ec65774faf1af58ead1a3fda942e /drivers/gpu/drm/rcar-du/rcar_du_drv.h
parent7fe99fda5f5c52a01b2c966aa68341a0b3d8ab33 (diff)
downloadlinux-cb2025d2509ffab1c426509fd9de3d83e40398b9.tar.xz
drm/rcar-du: Introduce CRTCs groups
The R8A7779 DU is split in per-CRTC resources (scan-out engine, blending unit, timings generator, ...) and device-global resources (start/stop control, planes, ...) shared between the two CRTCs. The R8A7790 introduced a third CRTC with its own set of global resources This would be modeled as two separate DU device instances if it wasn't for a handful or resources that are shared between the three CRTCs (mostly related to input and output routing). For this reason the R8A7790 DU must be modeled as a single device with three CRTCs, two sets of "semi-global" resources, and a few device-global resources. Introduce a new rcar_du_group driver-specific object, without any real counterpart in the DU documentation, that models those semi-global resources. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Diffstat (limited to 'drivers/gpu/drm/rcar-du/rcar_du_drv.h')
-rw-r--r--drivers/gpu/drm/rcar-du/rcar_du_drv.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/gpu/drm/rcar-du/rcar_du_drv.h b/drivers/gpu/drm/rcar-du/rcar_du_drv.h
index 0305c21d71f3..5b57a2f9b52a 100644
--- a/drivers/gpu/drm/rcar-du/rcar_du_drv.h
+++ b/drivers/gpu/drm/rcar-du/rcar_du_drv.h
@@ -18,11 +18,12 @@
#include <linux/platform_data/rcar-du.h>
#include "rcar_du_crtc.h"
-#include "rcar_du_plane.h"
+#include "rcar_du_group.h"
struct clk;
struct device;
struct drm_device;
+struct rcar_du_device;
#define RCAR_DU_FEATURE_CRTC_IRQ_CLOCK (1 << 0) /* Per-CRTC IRQ and clock */
@@ -40,15 +41,13 @@ struct rcar_du_device {
const struct rcar_du_device_info *info;
void __iomem *mmio;
- unsigned int use_count;
struct drm_device *ddev;
struct rcar_du_crtc crtcs[2];
- unsigned int used_crtcs;
unsigned int num_crtcs;
- struct rcar_du_planes planes;
+ struct rcar_du_group group;
};
static inline bool rcar_du_has(struct rcar_du_device *rcdu,
@@ -57,9 +56,6 @@ static inline bool rcar_du_has(struct rcar_du_device *rcdu,
return rcdu->info->features & feature;
}
-int rcar_du_get(struct rcar_du_device *rcdu);
-void rcar_du_put(struct rcar_du_device *rcdu);
-
static inline u32 rcar_du_read(struct rcar_du_device *rcdu, u32 reg)
{
return ioread32(rcdu->mmio + reg);