From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxime Ripard Subject: Re: [PATCH v2 4/8] drm/sun4i: add support for sun8i DE2 mixers and display engines Date: Mon, 20 Mar 2017 11:26:26 +0100 Message-ID: <20170320102626.24awzyrq32gomntt@lukather> References: <20170316204748.8596-1-icenowy@aosc.xyz> <20170316204748.8596-5-icenowy@aosc.xyz> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1712408329==" Return-path: In-Reply-To: <20170316204748.8596-5-icenowy@aosc.xyz> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Icenowy Zheng Cc: devicetree@vger.kernel.org, Jernej Skrabec , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Chen-Yu Tsai , Rob Herring , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org List-Id: devicetree@vger.kernel.org --===============1712408329== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ngju2ghew5huzmaq" Content-Disposition: inline --ngju2ghew5huzmaq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, On Fri, Mar 17, 2017 at 04:47:44AM +0800, Icenowy Zheng wrote: > Allwinner have a new "Display Engine 2.0" in there new SoCs, which comes > in a new "Display Engine" (mixers instead of old backends and > frontends). >=20 > Add support for the mixer on Allwinner V3s SoC; it's the simplest one. >=20 > Currently a lot of functions are still missing -- more investigations > are needed to gain enough infomation for them. >=20 > Signed-off-by: Icenowy Zheng > --- > Changes in v2: > - Rebase on current linux-next (with Chen-Yu's some refactors) > - Removed currently broken overlay plane. >=20 > drivers/gpu/drm/sun4i/Kconfig | 9 + > drivers/gpu/drm/sun4i/Makefile | 3 +- > drivers/gpu/drm/sun4i/sun4i_crtc.c | 14 +- > drivers/gpu/drm/sun4i/sun4i_crtc.h | 2 + > drivers/gpu/drm/sun4i/sun4i_drv.c | 1 + > drivers/gpu/drm/sun4i/sun4i_drv.h | 1 + > drivers/gpu/drm/sun4i/sun4i_layer.c | 94 +++++++-- > drivers/gpu/drm/sun4i/sun4i_layer.h | 3 + > drivers/gpu/drm/sun4i/sun4i_tcon.c | 2 +- > drivers/gpu/drm/sun4i/sun8i_mixer.c | 385 ++++++++++++++++++++++++++++++= ++++++ > drivers/gpu/drm/sun4i/sun8i_mixer.h | 166 ++++++++++++++++ > 11 files changed, 658 insertions(+), 22 deletions(-) > create mode 100644 drivers/gpu/drm/sun4i/sun8i_mixer.c > create mode 100644 drivers/gpu/drm/sun4i/sun8i_mixer.h >=20 > diff --git a/drivers/gpu/drm/sun4i/Kconfig b/drivers/gpu/drm/sun4i/Kconfig > index a4b357db8856..0fa989f955e7 100644 > --- a/drivers/gpu/drm/sun4i/Kconfig > +++ b/drivers/gpu/drm/sun4i/Kconfig > @@ -12,3 +12,12 @@ config DRM_SUN4I > Choose this option if you have an Allwinner SoC with a > Display Engine. If M is selected the module will be called > sun4i-drm. > + > +config DRM_SUN4I_DE2 > + bool "Support Display Engine 2.0" > + depends on DRM_SUN4I > + default MACH_SUN8I > + select SUN8I_DE2_CCU > + help > + Choose this option if you have an Allwinner SoC with a > + "Display Engine 2.0". > diff --git a/drivers/gpu/drm/sun4i/Makefile b/drivers/gpu/drm/sun4i/Makef= ile > index 59b757350a1f..3e7e2b2eb386 100644 > --- a/drivers/gpu/drm/sun4i/Makefile > +++ b/drivers/gpu/drm/sun4i/Makefile > @@ -1,5 +1,7 @@ > sun4i-drm-y +=3D sun4i_drv.o > sun4i-drm-y +=3D sun4i_framebuffer.o > +sun4i-drm-y +=3D sun4i_backend.o > +sun4i-drm-$(CONFIG_DRM_SUN4I_DE2) +=3D sun8i_mixer.o > =20 > sun4i-tcon-y +=3D sun4i_tcon.o > sun4i-tcon-y +=3D sun4i_rgb.o > @@ -8,6 +10,5 @@ sun4i-tcon-y +=3D sun4i_crtc.o > sun4i-tcon-y +=3D sun4i_layer.o > =20 > obj-$(CONFIG_DRM_SUN4I) +=3D sun4i-drm.o sun4i-tcon.o > -obj-$(CONFIG_DRM_SUN4I) +=3D sun4i_backend.o > obj-$(CONFIG_DRM_SUN4I) +=3D sun6i_drc.o > obj-$(CONFIG_DRM_SUN4I) +=3D sun4i_tv.o > diff --git a/drivers/gpu/drm/sun4i/sun4i_crtc.c b/drivers/gpu/drm/sun4i/s= un4i_crtc.c > index 3c876c3a356a..bf2aa0ffd35c 100644 > --- a/drivers/gpu/drm/sun4i/sun4i_crtc.c > +++ b/drivers/gpu/drm/sun4i/sun4i_crtc.c > @@ -26,8 +26,8 @@ > #include