From patchwork Mon Apr 23 20:45:49 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 10358115 X-Patchwork-Delegate: horms@verge.net.au 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 DFF2960225 for ; Mon, 23 Apr 2018 20:46:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CB75028BB7 for ; Mon, 23 Apr 2018 20:46:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BFD3328C5A; Mon, 23 Apr 2018 20:46:01 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1243D28BB7 for ; Mon, 23 Apr 2018 20:46:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755165AbeDWUqA (ORCPT ); Mon, 23 Apr 2018 16:46:00 -0400 Received: from mail-lf0-f66.google.com ([209.85.215.66]:43455 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755184AbeDWUp7 (ORCPT ); Mon, 23 Apr 2018 16:45:59 -0400 Received: by mail-lf0-f66.google.com with SMTP id g12-v6so894358lfb.10 for ; Mon, 23 Apr 2018 13:45:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cogentembedded-com.20150623.gappssmtp.com; s=20150623; h=from:subject:to:cc:references:organization:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=nEa9RMR/G/LAOz+AsDw1c6QO/i5RzyJpl7f8pHLAssw=; b=nGFWBFvwiRLK0AjjY7ajKzORgTDPRQ2y/EmH5Wx8LpzHvAVNJn3TEWDJ9wjNfsvVjQ DJiGe0xYCZHZC0AMuo+4f2+etIye438965bzhhiZMWX9CVEU7+jwYqLiKcnXOdQWXw/J VGt/9iqDo2dbhQIDAF7bGSDoOZrmpjhUtw5fIUZnRpE1sF66Pcqhe6i/1bPAaWvl7kkU giXX+fNMox0TMgmEBglLEvB5Xx7McEBAZ1hEfPFobsgmY0gjdgJl5QIs927/MIcRUEeJ IY/iVan+7/fjmAKqS9xuKQVvdetTVNM/h2F5awNzOt/QtC73w1i0AnqMpbxEZ77W5YBe B1sw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:to:cc:references:organization :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=nEa9RMR/G/LAOz+AsDw1c6QO/i5RzyJpl7f8pHLAssw=; b=GUzJZK+3VBLReoa4gtGHQpzM2TVYJBWAwoj8qIbnHvrThNpqd5s8LgLl59wV2QU5RG ZpFQ1uZea6steVhX+djXgEKw0taxMCGOrgtMhwqyPrDmebXvGNP5rcm9CkaUwS9nJpkB wEtPJDXIJkS8J58T6IbOR4x+rYyOs5Xu6rS4y8dDeOBeg65IqpzjySc/OsAj+6RqqZyp L2QF63sjtSaEzdbtKIjlwy52tih6QhIyJ048fHP8Jd76Y0BSTeMUrJ0CnHWPodewWO0D N6RnAu/MrTE+CrH5nPZzEcroGT7vxpqdDkbNj9LN/28C/AmkM37GhlUMa/+NPozX9uZn 8A7g== X-Gm-Message-State: ALQs6tBjhsV3xAdpWzrcKukX087nPpSewKU7t8aREqui3na09Hm/3KpH rp/w4IajyuVQkijOWvFGjkwqyQ== X-Google-Smtp-Source: AB8JxZpthdDL/p08qkmKQtjis825foBLyILHUi8X5KgaxX7xTyAi97LMy/sd5vAx3HqFG0Np2LMpsQ== X-Received: by 2002:a19:8387:: with SMTP id f129-v6mr9600948lfd.110.1524516356052; Mon, 23 Apr 2018 13:45:56 -0700 (PDT) Received: from wasted.cogentembedded.com ([31.173.86.113]) by smtp.gmail.com with ESMTPSA id t6sm1912964ljj.36.2018.04.23.13.45.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Apr 2018 13:45:55 -0700 (PDT) From: Sergei Shtylyov Subject: [PATCH v3] arm64: dts: renesas: v3msk: add DU/LVDS/HDMI support To: Simon Horman , Rob Herring , Catalin Marinas , Will Deacon , linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org Cc: Magnus Damm , Mark Rutland , "linux-arm-kernel@lists.infradead.org" References: <23a6ac28-134b-b5dd-69a7-910774c4b8c1@cogentembedded.com> Organization: Cogent Embedded Message-ID: Date: Mon, 23 Apr 2018 23:45:49 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <23a6ac28-134b-b5dd-69a7-910774c4b8c1@cogentembedded.com> Content-Language: en-MW Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Define the V3M Starter Kit board dependent part of the DU and LVDS device nodes. Also add the device nodes for Thine THC63LVD1024 LVDS decoder and Analog Devices ADV7511W HDMI transmitter... Based on the original (and large) patch by Vladimir Barinov. Signed-off-by: Vladimir Barinov Signed-off-by: Sergei Shtylyov --- This patch is against the 'renesas-devel-20180423-v4.17-rc2' tag of Simon Horman's 'renesas.git' repo. It requires the Thine THC63LVD1024 driver in order to work (the same as the Eagle HDMI patch by Jacopo/Niklas). Changes in version 3: - added Thine THC63LVD1024 device node, updating the respected endpoints; - merged the I2C pins subnode to the main PFC device node; - renamed the regulators; arch/arm64/boot/dts/renesas/r8a77970-v3msk.dts | 129 +++++++++++++++++++++++++ 1 file changed, 129 insertions(+) Index: renesas/arch/arm64/boot/dts/renesas/r8a77970-v3msk.dts =================================================================== --- renesas.orig/arch/arm64/boot/dts/renesas/r8a77970-v3msk.dts +++ renesas/arch/arm64/boot/dts/renesas/r8a77970-v3msk.dts @@ -29,6 +29,65 @@ /* first 128MB is reserved for secure area. */ reg = <0x0 0x48000000 0x0 0x38000000>; }; + + osc5_clk: osc5-clock { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <148500000>; + }; + + vcc_d1_8v: regulator-0 { + compatible = "regulator-fixed"; + regulator-name = "VCC_D1.8V"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-boot-on; + regulator-always-on; + }; + + vcc_d3_3v: regulator-1 { + compatible = "regulator-fixed"; + regulator-name = "VCC_D3.3V"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; + regulator-always-on; + }; + + lvds-decoder { + compatible = "thine,thc63lvd1024"; + vcc-supply = <&vcc_d3_3v>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + thc63lvd1024_in: endpoint { + remote-endpoint = <&lvds0_out>; + }; + }; + + port@2 { + reg = <2>; + thc63lvd1024_out: endpoint { + remote-endpoint = <&adv7511_in>; + }; + }; + }; + }; + + hdmi-out { + compatible = "hdmi-connector"; + type = "a"; + + port { + hdmi_con: endpoint { + remote-endpoint = <&adv7511_out>; + }; + }; + }; }; &avb { @@ -46,6 +105,13 @@ }; }; +&du { + clocks = <&cpg CPG_MOD 724>, + <&osc5_clk>; + clock-names = "du.0", "dclkin.0"; + status = "okay"; +}; + &extal_clk { clock-frequency = <16666666>; }; @@ -60,12 +126,75 @@ function = "avb0"; }; + i2c0_pins: i2c0 { + groups = "i2c0"; + function = "i2c0"; + }; + scif0_pins: scif0 { groups = "scif0_data"; function = "scif0"; }; }; +&i2c0 { + pinctrl-0 = <&i2c0_pins>; + pinctrl-names = "default"; + + status = "okay"; + clock-frequency = <400000>; + + hdmi@39{ + compatible = "adi,adv7511w"; + #sound-dai-cells = <0>; + reg = <0x39>; + interrupt-parent = <&gpio1>; + interrupts = <20 IRQ_TYPE_LEVEL_LOW>; + avdd-supply = <&vcc_d1_8v>; + dvdd-supply = <&vcc_d1_8v>; + pvdd-supply = <&vcc_d1_8v>; + bgvdd-supply = <&vcc_d1_8v>; + dvdd-3v-supply = <&vcc_d3_3v>; + + adi,input-depth = <8>; + adi,input-colorspace = "rgb"; + adi,input-clock = "1x"; + adi,input-style = <1>; + adi,input-justification = "evenly"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + adv7511_in: endpoint { + remote-endpoint = <&thc63lvd1024_out>; + }; + }; + + port@1 { + reg = <1>; + adv7511_out: endpoint { + remote-endpoint = <&hdmi_con>; + }; + }; + }; + }; +}; + +&lvds0 { + status = "okay"; + + ports { + port@1 { + lvds0_out: endpoint { + remote-endpoint = <&thc63lvd1024_in>; + }; + }; + }; +}; + &scif0 { pinctrl-0 = <&scif0_pins>; pinctrl-names = "default";