From patchwork Thu Jan 18 21:05:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 10174617 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5B98B6055D for ; Fri, 19 Jan 2018 06:24:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 48D3B2856D for ; Fri, 19 Jan 2018 06:24:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3C3CA285CE; Fri, 19 Jan 2018 06:24:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9B8EE2856D for ; Fri, 19 Jan 2018 06:24:08 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 147966E82D; Fri, 19 Jan 2018 06:22:30 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lf0-x244.google.com (mail-lf0-x244.google.com [IPv6:2a00:1450:4010:c07::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id 15EF66E00E for ; Thu, 18 Jan 2018 21:10:31 +0000 (UTC) Received: by mail-lf0-x244.google.com with SMTP id t139so13654049lff.0 for ; Thu, 18 Jan 2018 13:10:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cogentembedded-com.20150623.gappssmtp.com; s=20150623; h=from:message-id:user-agent:date:to:to:to:to:cc:subject:mime-version :content-disposition; bh=UbaOZXgIgTYQEf4sNdU38Z20pOw9WVpXuRdf62QGZyw=; b=gpX3qScw2W4ekzn2gDO2wqw5sZOvW43+En+wp+M5gdTmdCbCQXLmAk79ssJ1Kx3ypt WTy85lOacqGcxwv4YRsuAn0oJn7hiGyCxW9kb1QGK7TQs5lZhCI92/ryapUyefjiRlzA WFNgYp7y2CaZuWhimAl7n0qCWgvPuXKnAYPkQtF4iEGEzChF9xVxc13Plgb26a+NMmcw vKxNZPlp87jmv/3gtSUsg8+PGa3Q0cvRMjPchfuRrXqKOxcCB+O9uflkDmsfJWEKJLwh oPjXAvvLR5oZLzSvKa50HqD1PCIIQclV0+unY+HgTC9t6a5mqY0UV3nH/0/wXTa6T/ZP Ioeg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:message-id:user-agent:date:to:to:to:to:cc :subject:mime-version:content-disposition; bh=UbaOZXgIgTYQEf4sNdU38Z20pOw9WVpXuRdf62QGZyw=; b=Fx6vpXdQXPCTY7A9/IIziynqBg7mJQ9ybtF0Se0TAmkuZxk8JNLh+9NwNyM9SO2nJp TSRMCoXi2jo3KTK0UODUuIcmJHrOhNrwRuhOkCTyn47n74i/45RVIWYbDgXZeer6uX8J Atpjr6I4pMbk2iqYGq+84Xxoj6HENemm/U9CfOsyyMOueFVtzPm7MJkP5Xxaj0zU2J0u yKbNUdXSRzoO9/2slmQ0+/ZHDcBfDcxCTHBy9MyBfhj6tbxX6PX5sJuxS0wtueaQi6RK ivOoVBMuAURY2QJ2+EOUL1SwW2vm73eyL4YLTOVcy8drq1ma0AEItUimtQQQQ++YkpRU G+jg== X-Gm-Message-State: AKwxyte05Rw+pzjqgsMrgzDdQeLegk4utRM2cXpCgFbkodmWjfOENyBO /ss1ME9DEdowg7PZbqKSxSjpgA== X-Google-Smtp-Source: ACJfBotge+grqIv5fzgm9dybCSaTgDLDmumInijJ5q77s5peF2A4fKEWqvoTir/9hrhK1SCK5q7/Pw== X-Received: by 10.46.106.10 with SMTP id f10mr5677188ljc.68.1516309830427; Thu, 18 Jan 2018 13:10:30 -0800 (PST) Received: from wasted.cogentembedded.com ([31.173.84.211]) by smtp.gmail.com with ESMTPSA id f4sm1449072lje.84.2018.01.18.13.10.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Jan 2018 13:10:29 -0800 (PST) From: Sergei Shtylyov X-Google-Original-From: "Sergei Shtylyov" Received: by wasted.cogentembedded.com (sSMTP sendmail emulation); Fri, 19 Jan 2018 00:10:27 +0300 Message-Id: <20180118211027.375081728@cogentembedded.com> User-Agent: quilt/0.64 Date: Fri, 19 Jan 2018 00:05:59 +0300 To: Laurent Pinchart , David Airlie , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org To: Rob Herring To: Mark Rutland To: devicetree@vger.kernel.org Subject: [PATCH v2 2/2] drm: rcar-du: add R8A77970 support MIME-Version: 1.0 Content-Disposition: inline; filename=drm-rcar-du-add-R8A77970-support-v2.patch Cc: Sergei Shtylyov X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Add support for the R-Car V3M (R8A77970) SoC to the R-Car DU driver. Signed-off-by: Sergei Shtylyov Reviewed-by: Laurent Pinchart --- Changes in version 2: - removed the 'model' and 'dpll_ch' field initializers; - fixed up the DU port numbers; - split the DU bindings and the LVDS driver updates into a separate patches; - removed the check before the DPTSR write (to be done in a separate patch). drivers/gpu/drm/rcar-du/rcar_du_drv.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) Index: linux/drivers/gpu/drm/rcar-du/rcar_du_drv.c =================================================================== --- linux.orig/drivers/gpu/drm/rcar-du/rcar_du_drv.c +++ linux/drivers/gpu/drm/rcar-du/rcar_du_drv.c @@ -249,6 +249,26 @@ static const struct rcar_du_device_info .dpll_ch = BIT(1), }; +static const struct rcar_du_device_info rcar_du_r8a77970_info = { + .gen = 3, + .features = RCAR_DU_FEATURE_CRTC_IRQ_CLOCK + | RCAR_DU_FEATURE_EXT_CTRL_REGS + | RCAR_DU_FEATURE_VSP1_SOURCE, + .num_crtcs = 1, + .routes = { + /* R8A77970 has one RGB output and one LVDS output. */ + [RCAR_DU_OUTPUT_DPAD0] = { + .possible_crtcs = BIT(0), + .port = 0, + }, + [RCAR_DU_OUTPUT_LVDS0] = { + .possible_crtcs = BIT(0), + .port = 1, + }, + }, + .num_lvds = 1, +}; + static const struct of_device_id rcar_du_of_table[] = { { .compatible = "renesas,du-r8a7743", .data = &rzg1_du_r8a7743_info }, { .compatible = "renesas,du-r8a7745", .data = &rzg1_du_r8a7745_info }, @@ -260,6 +280,7 @@ static const struct of_device_id rcar_du { .compatible = "renesas,du-r8a7794", .data = &rcar_du_r8a7794_info }, { .compatible = "renesas,du-r8a7795", .data = &rcar_du_r8a7795_info }, { .compatible = "renesas,du-r8a7796", .data = &rcar_du_r8a7796_info }, + { .compatible = "renesas,du-r8a77970", .data = &rcar_du_r8a77970_info }, { } };