From patchwork Fri Oct 26 14:43:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10657611 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BE1455A4 for ; Fri, 26 Oct 2018 15:47:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AE6272C898 for ; Fri, 26 Oct 2018 15:47:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A06402C985; Fri, 26 Oct 2018 15:47:23 +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=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id ACE9E2C898 for ; Fri, 26 Oct 2018 15:47:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ymPw40rJtKz4KYJWydJlr4mf9Y5liBHDsPuIqx/jYeU=; b=arSy0F1ks3Tm4y 0K0q71PjUQuWlxlRADdJGAo2q5s0Kt8AE8sU4u7lgJmw3KoQv9CtvLiMXFvn389khjtxoT1JUsbzC xxaKPNl1yfRH7VSr3wmULdzkkMnNTB1hsq43696gUXMPF2GOgF/kmY9KWC0rcAlf5UNn0Dtrmbriz 5BfsgFrb+oU+YQNzG7MYhI0E1uoFXSIfr/4RYjjTrqa5vzDov1GcGC71wCA8BZTAX1EGO/wMwaC3X 3q3gQV+tE+Gl61ZUTuOJIdW9caBxx6Kwkf84YZDpAolri27PAK3Etd4iQ6zhPOuootst8QBDxK5px V/cgvvQQ26A2idivM5Ig==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gG4KN-0003x9-Rq; Fri, 26 Oct 2018 15:47:11 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gG4KL-0003vT-NE for linux-arm-kernel@bombadil.infradead.org; Fri, 26 Oct 2018 15:47:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=Q6u30J53lPheTTjrrL7nM+PLAo3DbPBTmQWn02a2iHU=; b=JxblUlcTup5qsMzFmFTKBa+bqw MOyCRUiFl59WkkYuxZyjYlNDHus3BtbKakg8p1zOaknGccevO6/Bc+HtVB/yskY8iNlKAy3lChhFi EwygZ1Dd3n2jF7TRD/gvj4FH6qnGU74B5LCMTp0YdMv81EV6MgOG8sxnWI17sqou05X+vdtDWhHcb A8gnS39DVBZCFVaXp5wjrIN0Oc92gV6x6CebTAMgGIMisUInnATlioEOm5G8e9TzrXRSNWX0BMnxG faotjxaS2kXKGN+IKRO7pWcXVn4Hvt2Yb+hVIi+hrcYB7qzMdiaeUOxRzymWL+KE19L5q/Md0itmU s/trmxaA==; Received: from mail-pf1-x442.google.com ([2607:f8b0:4864:20::442]) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gG3No-0002rR-CH for linux-arm-kernel@lists.infradead.org; Fri, 26 Oct 2018 14:46:41 +0000 Received: by mail-pf1-x442.google.com with SMTP id l17-v6so680429pff.2 for ; Fri, 26 Oct 2018 07:46:30 -0700 (PDT) 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:content-transfer-encoding; bh=Q6u30J53lPheTTjrrL7nM+PLAo3DbPBTmQWn02a2iHU=; b=p/Xw8STAMTpBBLncROH5aKHWB2b0L06z/UhiqQp2F9+VrSZOIDsV0mmfx9hVuftiHz pK5lph159Au6unI7SZNuaBJx+68/tHXUO1pND1fb0FXjmgJvdR0H2V5WMMdXQFSiNYoQ Gb08ac3/q7cJqmSElroxmGb2h1MNwOkptPQ1Y= 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:content-transfer-encoding; bh=Q6u30J53lPheTTjrrL7nM+PLAo3DbPBTmQWn02a2iHU=; b=uX3xkslKX9BUeqJQ0pGPBMSY+o3WY25pJgtACTEEdyHmVTfCUeyYEIkd1i+ad+8Hc0 ugdzNs+Zd4e2KSCkdc3/vntW9CTDEZUlM9P7pHZLDJc4F5bf1xAVenGuDEgbD5+hY7ou zd27Jdn3kGpoj64pAx0hNV5PV0zyg2MPPJmIh0lm9pc2avx9NcfRHYuJoh4Q3XRlHLBb 8Qo++bsOpJejkJpC4AZ76DzfDGceENx2CriWGhujrfU6RDaKSHnBiKhGK1VcJ/NMH+y6 MZ1+wEQ7fPKBzJQchh0psJRHOd48c9tM59PhoJX92hQeCZM0JTe8aWapRtls7wUlu2Mh Q4NA== X-Gm-Message-State: AGRZ1gJxePdOB0P251ogNyegO0QMSHhFL8D8/f07LZjunBA2ZYGCmTLB WptqCOnaA8GGhStrzuEUz1VB7A== X-Google-Smtp-Source: AJdET5cgG0qlCI/VdYgL30LMx8lLSWukX6LeQQzQtqXJQ27TFAV39x3nA8JEMtCOtgWz3vmexzHz1Q== X-Received: by 2002:a63:dc54:: with SMTP id f20mr3787544pgj.410.1540565188096; Fri, 26 Oct 2018 07:46:28 -0700 (PDT) Received: from localhost.localdomain ([27.7.51.1]) by smtp.gmail.com with ESMTPSA id z22-v6sm12044467pgv.24.2018.10.26.07.46.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Oct 2018 07:46:27 -0700 (PDT) From: Jagan Teki To: Maxime Ripard , Chen-Yu Tsai , Icenowy Zheng , Jernej Skrabec , Vasily Khoruzhick , Rob Herring , Mark Rutland , Catalin Marinas , Will Deacon , David Airlie , dri-devel@lists.freedesktop.org, Michael Turquette , Stephen Boyd , linux-clk@vger.kernel.org, Michael Trimarchi , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com Subject: [PATCH v3 24/25] [DO NOT MERGE] arm64: dts: allwinner: bananapi-m64: Bananapi S070WV20-CT16 DSI panel Date: Fri, 26 Oct 2018 20:13:43 +0530 Message-Id: <20181026144344.27778-25-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20181026144344.27778-1-jagan@amarulasolutions.com> References: <20181026144344.27778-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181026_104640_468271_3807FF27 X-CRM114-Status: GOOD ( 15.89 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jagan Teki Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This patch add support for Bananapi S070WV20-CT16 DSI panel to BPI-M64 board. DSI panel connected via board DSI port with, - DC1SW as AVDD supply - DCDC1 as DVDD supply - PD6 gpio for reset pin - PD5 gpio for backlight enable pin - PD7 gpio for backlight vdd supply Signed-off-by: Jagan Teki Tested-by: Jagan Teki --- Changes for v2: - remove unit address 0 - add nodes in alphabetical order - Use backlight instead of backlight_dsi - add tested credit Changes for v2: - Use quadratic rule on pwm brightness .../dts/allwinner/sun50i-a64-bananapi-m64.dts | 42 +++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts index ef1c90401bb2..6cb010e3bbd9 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts @@ -45,6 +45,7 @@ #include "sun50i-a64.dtsi" #include +#include / { model = "BananaPi-M64"; @@ -56,6 +57,15 @@ serial1 = &uart1; }; + backlight: backlight { + compatible = "pwm-backlight"; + pwms = <&r_pwm 0 50000 PWM_POLARITY_INVERTED>; + brightness-levels = <1 2 4 8 16 32 64 128 512>; + default-brightness-level = <2>; + enable-gpios = <&pio 3 5 GPIO_ACTIVE_HIGH>; /* LCD-BL-EN: PD5 */ + power-supply = <®_vdd_backlight>; + }; + chosen { stdout-path = "serial0:115200n8"; }; @@ -91,6 +101,15 @@ }; }; + reg_vdd_backlight: vdd-backlight { + compatible = "regulator-fixed"; + regulator-name = "vdd-backlight"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + gpio = <&pio 3 7 GPIO_ACTIVE_HIGH>; /* LCD-PWR-EN: PD7 */ + enable-active-high; + }; + wifi_pwrseq: wifi_pwrseq { compatible = "mmc-pwrseq-simple"; reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 */ @@ -101,6 +120,23 @@ status = "okay"; }; +&dphy { + status = "okay"; +}; + +&dsi { + status = "okay"; + + panel@0 { + compatible = "bananapi,s070wv20-ct16-icn6211"; + reg = <0>; + avdd-supply = <®_dc1sw>; + dvdd-supply = <®_dldo1>; + reset-gpios = <&pio 3 6 GPIO_ACTIVE_HIGH>; /* LCD-RST: PD6 */ + backlight = <&backlight>; + }; +}; + &ehci0 { status = "okay"; }; @@ -193,6 +229,12 @@ status = "okay"; }; +&r_pwm { + pinctrl-names = "default"; + pinctrl-0 = <&r_pwm_pin>; + status = "okay"; +}; + &r_rsb { status = "okay";