From patchwork Thu Jun 13 18:52:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 556 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f198.google.com (mail-pg1-f198.google.com [209.85.215.198]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 81BFA3F033 for ; Thu, 13 Jun 2019 20:54:32 +0200 (CEST) Received: by mail-pg1-f198.google.com with SMTP id c4sf14441499pgm.21 for ; Thu, 13 Jun 2019 11:54:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1560452071; cv=pass; d=google.com; s=arc-20160816; b=a8QrR4DU0xFKD30xGj61EvxPwYLAOaHPiRIwEQsoGi8VbwulQcDE8twOS2/LON3HOl krgNsqF28iMphQYhv5ibnl5GLCxMujFoNzSptB8IGFWuymHCzsCQ7jiKyAU92ydOUv71 F1b6Lh/bZ0qHC0rrOzebJqvDTJZsYMWmBmDQV/nN+kS8znD1EWG30AXzxvQoBQZyRBtp QkCbJqjHjHUYpNxJzgkdOwtJpQDrxf1xj/TXiHl/iEyEEWd4Pdrkcl2VSDA48tGIR3H2 ahrVL+aUm91X65FAGJzH8Oi9spriv6ZhcnlicZxrpdi9ccObdFc7LXPNoyVEWe7BtvjW tKrg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=xWcYvCMxeR/SuOsO3kMDBQTYf775J9v7K+RYUpODVtI=; b=QoJGjf8LFo9Grg2kdR/SKOJKvas3iDUTLv7DpBRsy53MWdNOV/zCOskpkLu/qbtZTr 0/7x42enHMuC/leH5ATOrD6+0X2h2vXTnwuTuehBlNjVmILG2U7ZvV2K0vG2gEKg6hvt dlq1mAyhTql99if+S5FazXmOt6yBSn5ytbRGwlxvDbRJoG5FCMoJahzU+h1avG4twRUs uE2EJwuOjOLqkKcKoVolLObMd35PpOH90Ghct37+qT3VhU45wT4BXyXVL8GGT6cTivcn 3qDdeaP6MmmJ9pSg7869wadymmGzopDnpAMge0d4QLCVbT6XOcVh/Djk8oG3atjCXfDC Mviw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KbHFlaqM; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=xWcYvCMxeR/SuOsO3kMDBQTYf775J9v7K+RYUpODVtI=; b=qbTCqwtyYkXZEemcvKRigOZK0tpJj7M8eFWeusQwKN8WfD9qft9ZdeqtV2AumkeU6E 1ob3EG3z4BRqgvEjAJwBSJ9gljw/vmJHHeyosf0dWIlnQ7iVsxJT2NmpDkbTQb0ym4Gb 9jxojByBe/U9pHNwUtQ261VEZWQ1pG4EoGX1M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-unsubscribe; bh=xWcYvCMxeR/SuOsO3kMDBQTYf775J9v7K+RYUpODVtI=; b=s8fIHCuf+lPnHaRsg+zFxCZCOy9BNgN5k0S8xbsKslQ9Ry4aUtHs6zhynL2IdT+dy7 J2e9qnZ5lJckoKpS6SBT6EjaeYOBPZysGUDzIjoIoNExe/vDLD/5yvrMbtEPWIZXc/B3 mS1bvLEoRvtM/5KQo59BzWonGUDAFmyCOreAXq51zu+ozI4rHYbp2DzoxPcdZUqDg6D1 OwKMbsRUNjbkwBT3EdKKwAaJfY/x1yJtAhaPnOefOrX6OD2B5KhpMfzJvm09BK84e+7T PW+Yv9ul0VeLSfcjbgAP7z5Yp2xdtfCoqUAkI5a9XRX6uXSHMdzBMGocOXF3XhwWp9fn /5MQ== X-Gm-Message-State: APjAAAWO1VdcDgbgtakQgQNMVUiZyh0nrL3osr+FjYpAsKq1krtAvj9i /xaTX9/cPo9AtN5y4Mhla4NyURuH X-Google-Smtp-Source: APXvYqxppidpYwK/H2HFeW/ohfkM1lJHQbO4ToQ20kslWRe7rzb29+aNgimxDzHhzBKi87d3wu6V8Q== X-Received: by 2002:a63:26c4:: with SMTP id m187mr32133254pgm.221.1560452065164; Thu, 13 Jun 2019 11:54:25 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:aa7:8056:: with SMTP id y22ls1430632pfm.6.gmail; Thu, 13 Jun 2019 11:54:25 -0700 (PDT) X-Received: by 2002:a62:a508:: with SMTP id v8mr92348948pfm.87.1560452064879; Thu, 13 Jun 2019 11:54:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560452064; cv=none; d=google.com; s=arc-20160816; b=GeihaOkKMAaEDlYsmg5u929awolMFCrHVVH4crvef2aOnCZKCSHmyWsBc/G4XfReBs aqQoNQULft0HrlIanJBTnfien8pu+zD97V6/Y6JFm32WFB1jdAFzEzHZJ77lyX9GjXGw CNiR5Y3o8kc5rGYznPpOLpDAyC1kr0u4eddJsAo28vFp0BDN5ev2ocN8thbVU8sf4hLU S1b3rIyJTCBRSJoUMZX4RwdqZCI9ytZryqP4MYrTCSkP+aVzYPZqENuNzjVlngM1sO8D hdDgqZobKizcbSuI9CA+0IaUOUdItYJqZq5kvDijF0fL8H9Wu0movzEajLo/P22/A/5n k1pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=T/4U16vvQGase4vs4TRs7L3uRB2ytO65pgimZPKYacA=; b=iunJzcEC48TktYdvbls+QgvclFz/U01JwXwZzGoWJtFd53VSeBDDsfILvfWFnKhHvK vpUYXitD6yVd1+VXkIZHysgH6f+oSxNWHsl1G9DuIQd3QBd49AjJ4V8Sw7E4xMR/GYou uJ6n8a9jqUnwBY3+FhailCIMPmtDT0nPc5vIfh/T+K/HHXjxXc1qUlhuoBglLbRq6+FS f5O4pcyppCqEY3m553Stkrt+qNBqTMZ8dBwWznhhRyuVWPNXrOhon8crScqKe/oCW+o6 82RJY9qe0xY481K+8iDk9VreMOvl86UGGsph8IadEuiQDJ9TJCNZgANfk2cf+RNkZ2p3 n8Cw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KbHFlaqM; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id g5sor783460pgc.72.2019.06.13.11.54.24 for (Google Transport Security); Thu, 13 Jun 2019 11:54:24 -0700 (PDT) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; X-Received: by 2002:a63:4d63:: with SMTP id n35mr2616452pgl.43.1560452064500; Thu, 13 Jun 2019 11:54:24 -0700 (PDT) Received: from localhost.localdomain ([115.97.180.18]) by smtp.gmail.com with ESMTPSA id p43sm946314pjp.4.2019.06.13.11.54.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 13 Jun 2019 11:54:24 -0700 (PDT) From: Jagan Teki To: Maxime Ripard , David Airlie , Daniel Vetter , Chen-Yu Tsai , dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Jernej Skrabec Cc: Michael Trimarchi , linux-sunxi@googlegroups.com, linux-amarula@amarulasolutions.com, Jagan Teki Subject: [PATCH 8/9] ARM: dts: sun8i: r40: Add MIPI DSI pipeline Date: Fri, 14 Jun 2019 00:22:40 +0530 Message-Id: <20190613185241.22800-9-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20190613185241.22800-1-jagan@amarulasolutions.com> References: <20190613185241.22800-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KbHFlaqM; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Add MIPI DSI pipeline for Allwinner R40. Unlike conventional Display pipeline in allwinner, R40 have TCON TCOP which would interact various block like muxes, tcon lcd, tcon_tv for better pipeline fitting. For MIPI DSI pipeline, we have to configure the tcon_lcd0 block which would interact with tcon_top for upper pipeline connections and dsi block for lower pipeline connections. So, this patch created that pipeline by adding new nodes for tcon_lcd0, dsi, dphy and connet them to make proper pipeline fitting. Signed-off-by: Jagan Teki --- arch/arm/boot/dts/sun8i-r40.dtsi | 73 ++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-r40.dtsi b/arch/arm/boot/dts/sun8i-r40.dtsi index 12576536df4a..3ea2451151ff 100644 --- a/arch/arm/boot/dts/sun8i-r40.dtsi +++ b/arch/arm/boot/dts/sun8i-r40.dtsi @@ -623,6 +623,7 @@ tcon_top_mixer0_out_tcon_lcd0: endpoint@0 { reg = <0>; + remote-endpoint = <&tcon_lcd0_in_tcon_top_mixer0>; }; tcon_top_mixer0_out_tcon_lcd1: endpoint@1 { @@ -701,6 +702,45 @@ }; }; + tcon_lcd0: lcd-controller@1c71000 { + compatible = "allwinner,sun8i-r40-tcon-lcd"; + reg = <0x01c71000 0x1000>; + interrupts = ; + clocks = <&ccu CLK_BUS_TCON_LCD0>, <&tcon_top CLK_TCON_TOP_LCD0>; + clock-names = "ahb", "tcon-ch0"; + clock-output-names = "tcon-pixel-clock"; + resets = <&ccu RST_BUS_TCON_LCD0>, <&ccu RST_BUS_LVDS>; + reset-names = "lcd", "lvds"; + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + tcon_lcd0_in: port@0 { + #address-cells = <1>; + #size-cells = <0>; + reg = <0>; + + tcon_lcd0_in_tcon_top_mixer0: endpoint@0 { + reg = <0>; + remote-endpoint = <&tcon_top_mixer0_out_tcon_lcd0>; + }; + }; + + tcon_lcd0_out: port@1 { + #address-cells = <1>; + #size-cells = <0>; + reg = <1>; + + tcon_lcd0_out_dsi_out: endpoint@1 { + reg = <1>; + remote-endpoint = <&dsi_in_tcon_lcd0_out>; + }; + }; + }; + }; + tcon_tv0: lcd-controller@1c73000 { compatible = "allwinner,sun8i-r40-tcon-tv"; reg = <0x01c73000 0x1000>; @@ -798,6 +838,39 @@ interrupts = ; }; + dsi: dsi@1ca0000 { + compatible = "allwinner,sun8i-r40-mipi-dsi", + "allwinner,sun50i-a64-mipi-dsi"; + reg = <0x01ca0000 0x1000>; + interrupts = ; + clocks = <&ccu CLK_BUS_MIPI_DSI>; + clock-names = "bus"; + resets = <&ccu RST_BUS_MIPI_DSI>; + phys = <&dphy>; + phy-names = "dphy"; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + + port { + dsi_in_tcon_lcd0_out: endpoint { + remote-endpoint = <&tcon_lcd0_out_dsi_out>; + }; + }; + }; + + dphy: d-phy@1ca1000 { + compatible = "allwinner,sun8i-r40-mipi-dphy", + "allwinner,sun6i-a31-mipi-dphy"; + reg = <0x01ca1000 0x1000>; + clocks = <&ccu CLK_BUS_MIPI_DSI>, + <&ccu CLK_DSI_DPHY>; + clock-names = "bus", "mod"; + resets = <&ccu RST_BUS_MIPI_DSI>; + status = "disabled"; + #phy-cells = <0>; + }; + hdmi: hdmi@1ee0000 { compatible = "allwinner,sun8i-r40-dw-hdmi", "allwinner,sun8i-a83t-dw-hdmi";