Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp529870imm; Wed, 11 Jul 2018 06:47:45 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfGGOQSM7URpgPAvEmidSzct+v63XsRtZbpco+XOyNVDQADs0RN52GhTkz6RB1gwJtRjZL7 X-Received: by 2002:a62:138c:: with SMTP id 12-v6mr30441171pft.34.1531316865319; Wed, 11 Jul 2018 06:47:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531316865; cv=none; d=google.com; s=arc-20160816; b=sjYpoS2V5+KUKifyE+UmNRFoe5nIQdPVmHbzcF32WdCzOxoe16x0+M6ktHvUH1FZpH FunP4t0KBiPOODXBu00yZuG2bPsZcik5s00RHmJOFUeSFWPK2BtlGm6XtC8j/Pny9ugp 8WwO80hVWbxhIYfhzJ9m+igJzbZbEIeHcOlH9S7X/qC3/rJtGhhMCySo0o0JCn0SOsZT GaYp2q233+XCSprLImDveRFPSFaP7jQ2FezoiRFMkJOZuX7THSOjPjSJeY/yjv5ieZfs +SE77xN7MQpIELOhOAZuG1rZCI1z3wfeXMvqnQfEFvs96hnjX2Fgct+3yk1QK4x9zsSm aZpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=B4OGofFL+2CsbF0dM3NNA5gmAJJXwpcgl9KZeaMKBR8=; b=YcpfC9hHtzwGTjbWXSrzTsLdzp5trZ6ZWf5xn/1KA68NWbXoPmDygzxD50ZpR6rWz/ vAZIM3y3eSNd0R+zZQWfSM9zI4Yi7zkJynQt2qLFcL8qvbu2mYTO3oBRK4w95dbOO1y2 G3SBL0Jn1o139c32UiUWEgNeFy8fhZK/6lsFdMCH0QjIHpd+zftwefFbG8NxSAn2h0Rd ygoJ2Ys8sIC8iSvkGITaM++aoFBoMYT314+x04gsxCh8X1WHH8FFmr0DCjF5jpgeZlbu fYgW4FtGXKYN7cTVxfdBa4G06GjoJ33kmyoyRaB3rDZdnGqd5xCELpMa5xHE/EoH4tWQ UNig== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x1-v6si7344511pln.129.2018.07.11.06.47.29; Wed, 11 Jul 2018 06:47:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388195AbeGKNu0 (ORCPT + 99 others); Wed, 11 Jul 2018 09:50:26 -0400 Received: from hermes.aosc.io ([199.195.250.187]:39131 "EHLO hermes.aosc.io" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388020AbeGKNu0 (ORCPT ); Wed, 11 Jul 2018 09:50:26 -0400 Received: from localhost (localhost [127.0.0.1]) (Authenticated sender: icenowy@aosc.io) by hermes.aosc.io (Postfix) with ESMTPSA id A729D64A13; Wed, 11 Jul 2018 13:45:52 +0000 (UTC) From: Icenowy Zheng To: Maxime Ripard , Chen-Yu Tsai Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com, Icenowy Zheng Subject: [PATCH 2/2] ARM: sun8i: h3: add SY8113B regulator on Banana Pi M2 Zero board Date: Wed, 11 Jul 2018 21:44:50 +0800 Message-Id: <20180711134450.43148-1-icenowy@aosc.io> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Banana Pi M2 Zero board has a SY8113B regulator, which is controlled via GPIO and capable of outputing 1.1V when the PL1 GPIO is set to output 0 or 1.1V when the PL6 GPIO is set to input or output 1, and the output is the power supply of the ARM cores in H3 SoC. Add the device tree node of this regulator and set the cpu's cpu-supply property to it. Signed-off-by: Icenowy Zheng --- .../dts/sun8i-h2-plus-bananapi-m2-zero.dts | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts index eb61dcf32797..abc8dc750f4b 100644 --- a/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts +++ b/arch/arm/boot/dts/sun8i-h2-plus-bananapi-m2-zero.dts @@ -59,6 +59,23 @@ }; }; + reg_vdd_cpux: vdd-cpux-regulator { + compatible = "regulator-gpio"; + regulator-name = "vdd-cpux"; + regulator-type = "voltage"; + regulator-boot-on; + regulator-always-on; + regulator-min-microvolt = <1100000>; + regulator-max-microvolt = <1300000>; + regulator-ramp-delay = <50>; /* 4ms */ + + gpios = <&r_pio 0 1 GPIO_ACTIVE_HIGH>; /* PL1 */ + enable-active-high; + gpios-states = <0x1>; + states = <1100000 0x0 + 1300000 0x1>; + }; + wifi_pwrseq: wifi_pwrseq { compatible = "mmc-pwrseq-simple"; pinctrl-names = "default"; @@ -66,6 +83,10 @@ }; }; +&cpu0 { + cpu-supply = <®_vdd_cpux>; +}; + &de { status = "okay"; }; -- 2.17.1