Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932570AbbLBPYc (ORCPT ); Wed, 2 Dec 2015 10:24:32 -0500 Received: from mail-wm0-f49.google.com ([74.125.82.49]:35525 "EHLO mail-wm0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932425AbbLBPY1 (ORCPT ); Wed, 2 Dec 2015 10:24:27 -0500 Date: Wed, 2 Dec 2015 16:24:19 +0100 From: Daniel Vetter To: Liviu Dudau Cc: David Airlie , Catalin Marinas , Will Deacon , Rob Herring , Sudeep Holla , Jon Medhurst , Mark Rutland , Ian Campbell , Kumar Gala , Rob Herring , Russell King , devicetree , Pawel Moll , Arnd Bergmann , Greg Kroah-Hartman , Punit Agrawal , LKML , DRI devel , Andrew Morton , Robin Murphy , LAKML Subject: Re: [PATCH v3 2/4] drm: Add support for ARM's HDLCD controller. Message-ID: <20151202152419.GC17050@phenom.ffwll.local> Mail-Followup-To: Liviu Dudau , David Airlie , Catalin Marinas , Will Deacon , Rob Herring , Sudeep Holla , Jon Medhurst , Mark Rutland , Ian Campbell , Kumar Gala , Rob Herring , Russell King , devicetree , Pawel Moll , Arnd Bergmann , Greg Kroah-Hartman , Punit Agrawal , LKML , DRI devel , Andrew Morton , Robin Murphy , LAKML References: <1449058982-18595-1-git-send-email-Liviu.Dudau@arm.com> <1449058982-18595-3-git-send-email-Liviu.Dudau@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1449058982-18595-3-git-send-email-Liviu.Dudau@arm.com> X-Operating-System: Linux phenom 4.1.0-2-amd64 User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 36755 Lines: 1184 On Wed, Dec 02, 2015 at 12:23:00PM +0000, Liviu Dudau wrote: > The HDLCD controller is a display controller that supports resolutions > up to 4096x4096 pixels. It is present on various development boards > produced by ARM Ltd and emulated by the latest Fast Models from the > company. > > Cc: David Airlie > Cc: Robin Murphy > > Signed-off-by: Liviu Dudau A few small nitpicks below. > --- > drivers/gpu/drm/Kconfig | 2 + > drivers/gpu/drm/Makefile | 1 + > drivers/gpu/drm/arm/Kconfig | 29 ++ > drivers/gpu/drm/arm/Makefile | 2 + > drivers/gpu/drm/arm/hdlcd_crtc.c | 334 +++++++++++++++++++++++ > drivers/gpu/drm/arm/hdlcd_drv.c | 555 +++++++++++++++++++++++++++++++++++++++ > drivers/gpu/drm/arm/hdlcd_drv.h | 42 +++ > drivers/gpu/drm/arm/hdlcd_regs.h | 87 ++++++ > 8 files changed, 1052 insertions(+) > create mode 100644 drivers/gpu/drm/arm/Kconfig > create mode 100644 drivers/gpu/drm/arm/Makefile > create mode 100644 drivers/gpu/drm/arm/hdlcd_crtc.c > create mode 100644 drivers/gpu/drm/arm/hdlcd_drv.c > create mode 100644 drivers/gpu/drm/arm/hdlcd_drv.h > create mode 100644 drivers/gpu/drm/arm/hdlcd_regs.h > > diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig > index c4bf9a1..3fd9124 100644 > --- a/drivers/gpu/drm/Kconfig > +++ b/drivers/gpu/drm/Kconfig > @@ -106,6 +106,8 @@ config DRM_TDFX > Choose this option if you have a 3dfx Banshee or Voodoo3 (or later), > graphics card. If M is selected, the module will be called tdfx. > > +source "drivers/gpu/drm/arm/Kconfig" > + > config DRM_R128 > tristate "ATI Rage 128" > depends on DRM && PCI > diff --git a/drivers/gpu/drm/Makefile b/drivers/gpu/drm/Makefile > index 1e9ff4c..6b42d75 100644 > --- a/drivers/gpu/drm/Makefile > +++ b/drivers/gpu/drm/Makefile > @@ -35,6 +35,7 @@ CFLAGS_drm_trace_points.o := -I$(src) > > obj-$(CONFIG_DRM) += drm.o > obj-$(CONFIG_DRM_MIPI_DSI) += drm_mipi_dsi.o > +obj-$(CONFIG_DRM_ARM) += arm/ > obj-$(CONFIG_DRM_TTM) += ttm/ > obj-$(CONFIG_DRM_TDFX) += tdfx/ > obj-$(CONFIG_DRM_R128) += r128/ > diff --git a/drivers/gpu/drm/arm/Kconfig b/drivers/gpu/drm/arm/Kconfig > new file mode 100644 > index 0000000..5e8c8a8 > --- /dev/null > +++ b/drivers/gpu/drm/arm/Kconfig > @@ -0,0 +1,29 @@ > +config DRM_ARM > + bool "ARM Ltd. drivers" > + depends on DRM && OF && (ARM || ARM64) > + select DRM_KMS_HELPER > + help > + Choose this option to select drivers for ARM's devices > + > +config DRM_HDLCD > + tristate "ARM HDLCD" > + depends on DRM_ARM > + depends on COMMON_CLK > + select COMMON_CLK_SCPI > + select DMA_CMA > + select DRM_KMS_CMA_HELPER > + select DRM_GEM_CMA_HELPER > + help > + Choose this option if you have an ARM High Definition Colour LCD > + controller. > + > + If M is selected the module will be called hdlcd. > + > +config DRM_HDLCD_SHOW_UNDERRUN > + bool "Show underrun conditions" > + depends on DRM_HDLCD > + default n > + help > + Enable this option to show in red colour the pixels that the > + HDLCD device did not fetch from framebuffer due to underrun > + conditions. > diff --git a/drivers/gpu/drm/arm/Makefile b/drivers/gpu/drm/arm/Makefile > new file mode 100644 > index 0000000..89dcb7b > --- /dev/null > +++ b/drivers/gpu/drm/arm/Makefile > @@ -0,0 +1,2 @@ > +hdlcd-y := hdlcd_drv.o hdlcd_crtc.o > +obj-$(CONFIG_DRM_HDLCD) += hdlcd.o > diff --git a/drivers/gpu/drm/arm/hdlcd_crtc.c b/drivers/gpu/drm/arm/hdlcd_crtc.c > new file mode 100644 > index 0000000..350c1fe > --- /dev/null > +++ b/drivers/gpu/drm/arm/hdlcd_crtc.c > @@ -0,0 +1,334 @@ > +/* > + * Copyright (C) 2013-2015 ARM Limited > + * Author: Liviu Dudau > + * > + * This file is subject to the terms and conditions of the GNU General Public > + * License. See the file COPYING in the main directory of this archive > + * for more details. > + * > + * Implementation of a CRTC class for the HDLCD driver. > + */ > + > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include