From patchwork Tue Dec 31 13:05:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 993 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f199.google.com (mail-pg1-f199.google.com [209.85.215.199]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 88A393F077 for ; Tue, 31 Dec 2019 14:06:24 +0100 (CET) Received: by mail-pg1-f199.google.com with SMTP id u14sf20106038pgq.16 for ; Tue, 31 Dec 2019 05:06:24 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1577797583; cv=pass; d=google.com; s=arc-20160816; b=rlVpftGDN/3w385comSoHAunF5fM1cwSSrgetu9d2ytwcdu1Z4bZhq2hUfOYog/4dD O1oIHd7r7iHVLeshIVJ+sPHXyxulDNORoqgyk+dkdW+PxrDrcrqGSnYhTAYFWxNjUogU ayPzQZe6x2uZa2iZG9pA4wXEE1vTiiAva+T2OjzOqAT0/OrsnJmxIGWPqQ9PxMl7yejO B/H6XEW10R1Fzh+z9jT4rOt3a5l/6gwCV2enAvcuyqmoAULOCNm4orto3wWxy7I6m8Lp shYNy9z5q/MlYSLhH3VhhBSnrZD+wh/MZkhZKH/XDzf3Omhf/lXJlXIQ4cx3AL83/nQ4 Y+jg== 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=VPP/bUR0OO9jlsWWGP4AJu//IO6vkOGL9sifyL5zeL4=; b=BF4jcpeVmhjrbK3LUalcPLafw+YrJFDQr5VeJ9LcMJncrKPf0VFPfbf8SQupkrTMUn w5eDmF3hF+LSMxSpaZ8sPFMZEntxlO0t1uB97fjJ03htOMJoXaefVuVU5KaHz2k5MNBL aJUfWNCpjzk6jvjksuFnCc+ByKM6ENC7y7kfBNN6VizH9HfRIN99QkLFuXEkA7eXf+hP ZQa1w047indUJ1XVgipKblp8Rl0rGPM12KqaGT7CcX+MnRL642EObHFu6w3mSqdx6cVw CY88rvOuCGU0P80YGjcFYZWb1KhxpWfHRtOhZmNkjGYeQHAsr6AFicYSoH4APkjY/1hp l0RQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=Xf+YTt7D; 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=VPP/bUR0OO9jlsWWGP4AJu//IO6vkOGL9sifyL5zeL4=; b=pm8tKtGo7xykZQpegn/6xuMBR8fJgd7uLvs44UX2KA9/Ei7r2eTYJiSSfrsfVhOVa3 ezrylY2Z8J7s5mLe3XeYYdBiKE5udnqim68LizJEgefrzZiTsgjlV8RooWXVB1pWafqA GdKdN4+y752LcbSnJeTJhm9UKe2lcnNA4MrnI= 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=VPP/bUR0OO9jlsWWGP4AJu//IO6vkOGL9sifyL5zeL4=; b=ms9BnCud7t32nO0+ek/TX0kzM9W0Yeit3OTOv5cN91KT25b4kfggGTabDqiOJvJ2y9 mMdbLrTppfahKDCEeyGOPPTguOnKJwrhpGbUs24vwOicmRUtvbdcG+rhLLiiai0HRmUB 8lR4F135yocSKX9rx+yYn9rVo5i8ZC4/9AtW69a2q+f4+6+kM5s4iJhTbvAfBZ5pZWQg 0vCvEOygG54VDypy6GqGsqtMb/Ndx6vzmbQF5exclUfRYeLoKSKq6Z8MVg/o2HAeKw77 7MblO6sO1/5xU+xzBeW8xBczEBanDb2JAW99V82kf3pi31rphhlduQTYZeBJFYa88u5b swWw== X-Gm-Message-State: APjAAAXZ+X8bI7e0GoEnlQWHlso21cI13O2hgR1DQHWFwjvbOuPzLYUC PF62wJ1CTk+c/xGrcxVZ0C6hInlZ X-Google-Smtp-Source: APXvYqxhIj5nTMYbAIWxbnr8dPXRA5ddGCiSxcJ7FH/p+WHY/Vujb9Jfg3cEAM8qOfTqx5Uvi4rp5g== X-Received: by 2002:a63:2355:: with SMTP id u21mr76259741pgm.179.1577797582995; Tue, 31 Dec 2019 05:06:22 -0800 (PST) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a17:90a:3ae2:: with SMTP id b89ls1439420pjc.2.canary-gmail; Tue, 31 Dec 2019 05:06:22 -0800 (PST) X-Received: by 2002:a17:902:9043:: with SMTP id w3mr73572957plz.8.1577797582428; Tue, 31 Dec 2019 05:06:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1577797582; cv=none; d=google.com; s=arc-20160816; b=WfFAAMwzkJTD7BXgItE78rC621icuuDnw1+ZrlNyWGEXgIkDb+4a+vQ/HU1g8hNgs7 kFNMy3oX2kcV+AufVMA3q1IaXC/VGpljYaA9m4oz1J70x1UbhoymOBG5kKUKziNwfW3O 3ZoI+qKxi/Xrtq/XbHvHTA3DiHEO5xN3nPR8KHrJzP4OLGg530K1ngTkBvssuI28wAxg 5ht0wzfbxsKDzZN3NdpWPfZI6y5J2Ixlnl1Jt9MvrsagbwyR6UjCsxWpWRFn4XQ+i2is U2I8DXgQQ65FyU6GlhsE39eJzXQV2w6WFjiU7fE0F5BQ1OEeWZi+tRQXqq7HeIZp94yG kkGQ== 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=WXe17pB2YX4+a+B1E8N8lDCTkuNeVa3zzzOGyzeuSys=; b=vOMEihI+V1RKIh4VsiFKTDVrYgiyYlF0r82yKLnS2bU0+RvfvgvDYJvSqHXUUuXTMU 0WAABZIF6VSq/Ijp3Jc+LNJubT25wwdT6LJczaHZt1SgLEuyU1vpzn0+9+/x/VGuGyFO Z8DXwpMWoNCNBkiaNGmu66IM8O97i02oLuoMrwYSrtj/eU/Fl4RGswS9Trd7irHLfXbv JDgbMAY3u2FUmiehfV/RXcQcOQWEh8Rss+OSh2mex0S1FDkDXi+Q/3KJEO2XYl+sFT0M 1KKtKOhf+z5TEwRDeI4J7FQxGn1rX1Mmds/pvJqRW5c+LH6XY/meDGRNoILYwaLSMcVC PA1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=Xf+YTt7D; 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 s12sor3015260pji.21.2019.12.31.05.06.22 for (Google Transport Security); Tue, 31 Dec 2019 05:06:22 -0800 (PST) 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:a17:90a:e657:: with SMTP id ep23mr5986713pjb.105.1577797582087; Tue, 31 Dec 2019 05:06:22 -0800 (PST) Received: from localhost.localdomain ([49.206.202.115]) by smtp.gmail.com with ESMTPSA id i3sm55204089pfg.94.2019.12.31.05.06.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Dec 2019 05:06:21 -0800 (PST) From: Jagan Teki To: Maxime Ripard , Chen-Yu Tsai , Jernej Skrabec , Rob Herring Cc: David Airlie , Daniel Vetter , Mark Rutland , dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-sunxi , linux-amarula@amarulasolutions.com, Jagan Teki Subject: [PATCH v3 8/9] ARM: dts: sun8i: r40: Add MIPI DSI pipeline Date: Tue, 31 Dec 2019 18:35:27 +0530 Message-Id: <20191231130528.20669-9-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20191231130528.20669-1-jagan@amarulasolutions.com> References: <20191231130528.20669-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=Xf+YTt7D; 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 --- Changes for v3: - drop clock-names in dsi node arch/arm/boot/dts/sun8i-r40.dtsi | 72 ++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-r40.dtsi b/arch/arm/boot/dts/sun8i-r40.dtsi index 3faa35d43afa..4c61e93d9a0b 100644 --- a/arch/arm/boot/dts/sun8i-r40.dtsi +++ b/arch/arm/boot/dts/sun8i-r40.dtsi @@ -628,6 +628,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 { @@ -706,6 +707,45 @@ }; }; + tcon_lcd0: lcd-controller@1c71000 { + compatible = "allwinner,sun8i-r40-tcon-lcd"; + reg = <0x01c71000 0x1000>; + interrupts = ; + clocks = <&ccu CLK_BUS_TCON_LCD0>, <&ccu CLK_TCON_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>; @@ -803,6 +843,38 @@ 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>; + 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>, + <&tcon_top CLK_TCON_TOP_DSI>; + 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";