lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 30 Jan 2019 16:41:55 +0800
From:   Chen-Yu Tsai <wens@...e.org>
To:     Maxime Ripard <maxime.ripard@...tlin.com>
Cc:     linux-sunxi@...glegroups.com, Icenowy Zheng <icenowy@...c.io>,
        Andre Przywara <andre.przywara@....com>,
        Emmanuel Vadot <manu@...ebsd.org>,
        Jagan Teki <jagan@...rulasolutions.com>,
        Sergey Matyukevich <geomatsi@...il.com>,
        Hauke Mehrtens <hauke@...ke-m.de>,
        Chen-Yu Tsai <wens@...e.org>,
        linux-arm-kernel@...ts.infradead.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: [PATCH 02/10] ARM: dts: bananapi-m2-plus: Add CPU supply regulator

The original Bananapi M2+ uses a fixed regulator to supply the CPU
cores. According to Bananapi, the retail v1.1 version is designed to
supply 1.3V. Actual measurements show 1.310V. Earlier engineering
samples had it at 1.4V, but this is not covered here.

Signed-off-by: Chen-Yu Tsai <wens@...e.org>
---
 .../boot/dts/sunxi-bananapi-m2-plus-v1.2.dtsi | 30 +++++++------------
 arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi | 14 +++++++++
 2 files changed, 25 insertions(+), 19 deletions(-)

diff --git a/arch/arm/boot/dts/sunxi-bananapi-m2-plus-v1.2.dtsi b/arch/arm/boot/dts/sunxi-bananapi-m2-plus-v1.2.dtsi
index a567567763f4..39834329b6ae 100644
--- a/arch/arm/boot/dts/sunxi-bananapi-m2-plus-v1.2.dtsi
+++ b/arch/arm/boot/dts/sunxi-bananapi-m2-plus-v1.2.dtsi
@@ -5,27 +5,19 @@
 
 #include "sunxi-bananapi-m2-plus.dtsi"
 
-/ {
+&reg_vdd_cpux {
 	/*
 	 * Bananapi M2+ v1.2 uses a GPIO line to change the effective
 	 * resistance on the CPU regulator's feedback pin.
 	 */
-	reg_vdd_cpux: vdd-cpux {
-		compatible = "regulator-gpio";
-		regulator-name = "vdd-cpux";
-		regulator-type = "voltage";
-		regulator-boot-on;
-		regulator-always-on;
-		regulator-min-microvolt = <1108475>;
-		regulator-max-microvolt = <1308475>;
-		regulator-ramp-delay = <50>; /* 4ms */
-		gpios = <&r_pio 0 1 GPIO_ACTIVE_HIGH>; /* PL1 */
-		gpios-states = <0x1>;
-		states = <1108475 0x0
-			  1308475 0x1>;
-	};
-};
-
-&cpu0 {
-	cpu-supply = <&reg_vdd_cpux>;
+	compatible = "regulator-gpio";
+	regulator-type = "voltage";
+	regulator-min-microvolt = <1108475>;
+	regulator-max-microvolt = <1308475>;
+	regulator-ramp-delay = <50>; /* 4ms */
+	enable-gpios =  <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
+	gpios = <&r_pio 0 1 GPIO_ACTIVE_HIGH>; /* PL1 */
+	gpios-states = <0x1>;
+	states = <1108475 0x0
+		  1308475 0x1>;
 };
diff --git a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
index 3bed375b9c03..eb90f53ae958 100644
--- a/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
+++ b/arch/arm/boot/dts/sunxi-bananapi-m2-plus.dtsi
@@ -99,6 +99,16 @@
 		      gpio = <&pio 3 6 GPIO_ACTIVE_HIGH>;
 	};
 
+	reg_vdd_cpux: vdd-cpux {
+		compatible = "regulator-fixed";
+		regulator-name = "vdd-cpux";
+		regulator-boot-on;
+		regulator-always-on;
+		regulator-min-microvolt = <1310000>;
+		regulator-max-microvolt = <1310000>;
+		gpios = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
+	};
+
 	wifi_pwrseq: wifi_pwrseq {
 		compatible = "mmc-pwrseq-simple";
 		pinctrl-names = "default";
@@ -108,6 +118,10 @@
 	};
 };
 
+&cpu0 {
+	cpu-supply = <&reg_vdd_cpux>;
+};
+
 &de {
 	status = "okay";
 };
-- 
2.20.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ