From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, UNWANTED_LANGUAGE_BODY,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F1887C55199 for ; Mon, 27 Apr 2020 08:22:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BFB68206D4 for ; Mon, 27 Apr 2020 08:22:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726831AbgD0IWX (ORCPT ); Mon, 27 Apr 2020 04:22:23 -0400 Received: from relmlor1.renesas.com ([210.160.252.171]:20668 "EHLO relmlie5.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726003AbgD0IWX (ORCPT ); Mon, 27 Apr 2020 04:22:23 -0400 X-IronPort-AV: E=Sophos;i="5.73,323,1583161200"; d="scan'208";a="45816349" Received: from unknown (HELO relmlir6.idc.renesas.com) ([10.200.68.152]) by relmlie5.idc.renesas.com with ESMTP; 27 Apr 2020 17:22:19 +0900 Received: from renesas-VirtualBox.ree.adwin.renesas.com (unknown [172.29.51.26]) by relmlir6.idc.renesas.com (Postfix) with ESMTP id A68FD41D9F73; Mon, 27 Apr 2020 17:22:15 +0900 (JST) From: Gareth Williams To: Maarten Lankhorst , Maxime Ripard , Sean Paul , David Airlie , Daniel Vetter Cc: Gareth Williams , Phil Edworthy , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 1/3] drm/db9000: Add Digital Blocks DB9000 LCD Controller Date: Mon, 27 Apr 2020 09:21:47 +0100 Message-Id: <1587975709-2092-2-git-send-email-gareth.williams.jx@renesas.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1587975709-2092-1-git-send-email-gareth.williams.jx@renesas.com> References: <1587975709-2092-1-git-send-email-gareth.williams.jx@renesas.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add DRM support for the Digital Blocks DB9000 LCD Controller with the Renesas RZ/N1 specific changes. Signed-off-by: Gareth Williams --- drivers/gpu/drm/Kconfig | 2 + drivers/gpu/drm/Makefile | 1 + drivers/gpu/drm/digital-blocks/Kconfig | 13 + drivers/gpu/drm/digital-blocks/Makefile | 3 + drivers/gpu/drm/digital-blocks/db9000-du.c | 953 +++++++++++++++++++++++++++++ drivers/gpu/drm/digital-blocks/db9000-du.h | 192 ++++++ 6 files changed, 1164 insertions(+) create mode 100644 drivers/gpu/drm/digital-blocks/Kconfig create mode 100644 drivers/gpu/drm/digital-blocks/Makefile create mode 100644 drivers/gpu/drm/digital-blocks/db9000-du.c create mode 100644 drivers/gpu/drm/digital-blocks/db9000-du.h diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig index 3c88420..159832d 100644 --- a/drivers/gpu/drm/Kconfig +++ b/drivers/gpu/drm/Kconfig @@ -280,6 +280,8 @@ source "drivers/gpu/drm/mgag200/Kconfig" source "drivers/gpu/drm/cirrus/Kconfig" +source "drivers/gpu/drm/digital-blocks/Kconfig" + source "drivers/gpu/drm/armada/Kconfig" source "drivers/gpu/drm/atmel-hlcdc/Kconfig" diff --git a/drivers/gpu/drm/Makefile b/drivers/gpu/drm/Makefile index 9f0d2ee..f525807 100644 --- a/drivers/gpu/drm/Makefile +++ b/drivers/gpu/drm/Makefile @@ -72,6 +72,7 @@ obj-$(CONFIG_DRM_MGAG200) += mgag200/ obj-$(CONFIG_DRM_V3D) += v3d/ obj-$(CONFIG_DRM_VC4) += vc4/ obj-$(CONFIG_DRM_CIRRUS_QEMU) += cirrus/ +obj-$(CONFIG_DRM_DB9000) += digital-blocks/ obj-$(CONFIG_DRM_SIS) += sis/ obj-$(CONFIG_DRM_SAVAGE)+= savage/ obj-$(CONFIG_DRM_VMWGFX)+= vmwgfx/ diff --git a/drivers/gpu/drm/digital-blocks/Kconfig b/drivers/gpu/drm/digital-blocks/Kconfig new file mode 100644 index 0000000..436a7c0 --- /dev/null +++ b/drivers/gpu/drm/digital-blocks/Kconfig @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: GPL-2.0 +config DRM_DB9000 + bool "DRM Support for DB9000 LCD Controller" + depends on DRM && (ARCH_MULTIPLATFORM || COMPILE_TEST) + select DRM_KMS_HELPER + select DRM_GEM_CMA_HELPER + select DRM_KMS_CMA_HELPER + select DRM_PANEL_BRIDGE + select VIDEOMODE_HELPERS + select FB_PROVIDE_GET_FB_UNMAPPED_AREA if FB + + help + Enable DRM support for the DB9000 LCD controller. diff --git a/drivers/gpu/drm/digital-blocks/Makefile b/drivers/gpu/drm/digital-blocks/Makefile new file mode 100644 index 0000000..9f78492 --- /dev/null +++ b/drivers/gpu/drm/digital-blocks/Makefile @@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-$(CONFIG_DRM_DB9000) += db9000-du.o diff --git a/drivers/gpu/drm/digital-blocks/db9000-du.c b/drivers/gpu/drm/digital-blocks/db9000-du.c new file mode 100644 index 0000000..d84d446 --- /dev/null +++ b/drivers/gpu/drm/digital-blocks/db9000-du.c @@ -0,0 +1,953 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (C) 2019 Renesas Electronics Europe Ltd. + * + * Author: Gareth Williams + * + * Based on ltdc.c + * Copyright (C) STMicroelectronics SA 2017 + * + * Authors: Philippe Cornu + * Yannick Fertre + * Fabien Dessenne + * Mickael Reulier + */ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include