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]
Message-Id: <1415074039-16590-7-git-send-email-wens@csie.org>
Date:	Tue,  4 Nov 2014 12:07:19 +0800
From:	Chen-Yu Tsai <wens@...e.org>
To:	Maxime Ripard <maxime.ripard@...e-electrons.com>,
	Kishon Vijay Abraham I <kishon@...com>,
	Mike Turquette <mturquette@...aro.org>,
	Grant Likely <grant.likely@...aro.org>,
	Rob Herring <robh+dt@...nel.org>
Cc:	Chen-Yu Tsai <wens@...e.org>, Hans de Goede <hdegoede@...hat.com>,
	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	linux-sunxi@...glegroups.com
Subject: [PATCH 6/6] ARM: dts: sun9i: Enable USB support on A80 Optimus board

Signed-off-by: Chen-Yu Tsai <wens@...e.org>
---
This patch does not use sunxi-common-regulators.dtsi, but adds the
regulators directly. To use the common regulators file, we would
need to use phandles and switch to preprocessor includes to support
that.

---
 arch/arm/boot/dts/sun9i-a80-optimus.dts | 72 +++++++++++++++++++++++++++++++++
 1 file changed, 72 insertions(+)

diff --git a/arch/arm/boot/dts/sun9i-a80-optimus.dts b/arch/arm/boot/dts/sun9i-a80-optimus.dts
index 506948f..31010c1 100644
--- a/arch/arm/boot/dts/sun9i-a80-optimus.dts
+++ b/arch/arm/boot/dts/sun9i-a80-optimus.dts
@@ -59,6 +59,40 @@
 	};
 
 	soc {
+		ehci0: usb@...00000 {
+			status = "okay";
+		};
+
+		ohci0: usb@...00400 {
+			status = "okay";
+		};
+
+		usbphy0: phy@...00800 {
+			vbus-supply = <&reg_usb0_vbus>;
+			status = "okay";
+		};
+
+		ehci1: usb@...01000 {
+			status = "okay";
+		};
+
+		usbphy1: phy@...01800 {
+			status = "okay";
+		};
+
+		ehci2: usb@...02000 {
+			status = "okay";
+		};
+
+		ohci2: usb@...02400 {
+			status = "okay";
+		};
+
+		usbphy2: phy@...02800 {
+			vbus-supply = <&reg_usb2_vbus>;
+			status = "okay";
+		};
+
 		pio: pinctrl@...00800 {
 			i2c3_pins_a: i2c3@0 {
 				/* Enable internal pull-up */
@@ -76,6 +110,20 @@
 				/* Enable internal pull-up */
 				allwinner,pull = <1>;
 			};
+
+			usb0_vbus_pin_optimus: usb0_vbus_pin@1 {
+				allwinner,pins = "PH4";
+				allwinner,function = "gpio_out";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+
+			usb2_vbus_pin_optimus: usb2_vbus_pin@1 {
+				allwinner,pins = "PH5";
+				allwinner,function = "gpio_out";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
 		};
 
 		uart0: serial@...00000 {
@@ -116,4 +164,28 @@
 			gpios = <&pio 7 0 0>;
 		};
 	};
+
+	reg_usb0_vbus: usb0-vbus {
+		compatible = "regulator-fixed";
+		pinctrl-names = "default";
+		pinctrl-0 = <&usb0_vbus_pin_optimus>;
+		regulator-name = "usb0-vbus";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		enable-active-high;
+		gpio = <&pio 7 4 0>; /* PH4 */
+		status = "okay";
+	};
+
+	reg_usb2_vbus: usb2-vbus {
+		compatible = "regulator-fixed";
+		pinctrl-names = "default";
+		pinctrl-0 = <&usb2_vbus_pin_optimus>;
+		regulator-name = "usb2-vbus";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		enable-active-high;
+		gpio = <&pio 7 5 0>; /* PH5 */
+		status = "okay";
+	};
 };
-- 
2.1.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ