From: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Maxime Ripard
<maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
devicetree <devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org,
Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Subject: [PATCH 01/19] ARM: sunxi: dt: Add sunxi-common-regulators include file
Date: Sat, 1 Mar 2014 20:26:20 +0100 [thread overview]
Message-ID: <1393701998-3553-2-git-send-email-hdegoede@redhat.com> (raw)
In-Reply-To: <1393701998-3553-1-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Most sunxi boards with a sata connector also have a gpio controlled connector
for sata target power and almost all sunxi boards have a gpio controlled vbus
for usb1 and usb2.
This commit adds an include file for the regulators representing these
supplies, avoiding the need to copy and paste the regulator code to allmost
all sunxi board dts files.
Signed-off-by: Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
arch/arm/boot/dts/sunxi-common-regulators.dtsi | 75 ++++++++++++++++++++++++++
1 file changed, 75 insertions(+)
create mode 100644 arch/arm/boot/dts/sunxi-common-regulators.dtsi
diff --git a/arch/arm/boot/dts/sunxi-common-regulators.dtsi b/arch/arm/boot/dts/sunxi-common-regulators.dtsi
new file mode 100644
index 0000000..18eeac0
--- /dev/null
+++ b/arch/arm/boot/dts/sunxi-common-regulators.dtsi
@@ -0,0 +1,75 @@
+/*
+ * sunxi boards common regulator (ahci target power supply, usb-vbus) code
+ *
+ * Copyright 2014 - Hans de Goede <hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
+ *
+ * The code contained herein is licensed under the GNU General Public
+ * License. You may obtain a copy of the GNU General Public License
+ * Version 2 or later at the following locations:
+ *
+ * http://www.opensource.org/licenses/gpl-license.html
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/ {
+ soc@01c00000 {
+ pio: pinctrl@01c20800 {
+ ahci_pwr_pin_a: ahci_pwr_pin@0 {
+ allwinner,pins = "PB8";
+ allwinner,function = "gpio_out";
+ allwinner,drive = <0>;
+ allwinner,pull = <0>;
+ };
+
+ usb1_vbus_pin_a: usb1_vbus_pin@0 {
+ allwinner,pins = "PH6";
+ allwinner,function = "gpio_out";
+ allwinner,drive = <0>;
+ allwinner,pull = <0>;
+ };
+
+ usb2_vbus_pin_a: usb2_vbus_pin@0 {
+ allwinner,pins = "PH3";
+ allwinner,function = "gpio_out";
+ allwinner,drive = <0>;
+ allwinner,pull = <0>;
+ };
+ };
+ };
+
+ reg_ahci_5v: ahci-5v {
+ compatible = "regulator-fixed";
+ pinctrl-names = "default";
+ pinctrl-0 = <&ahci_pwr_pin_a>;
+ regulator-name = "ahci-5v";
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ enable-active-high;
+ gpio = <&pio 1 8 0>;
+ status = "disabled";
+ };
+
+ reg_usb1_vbus: usb1-vbus {
+ compatible = "regulator-fixed";
+ pinctrl-names = "default";
+ pinctrl-0 = <&usb1_vbus_pin_a>;
+ regulator-name = "usb1-vbus";
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ enable-active-high;
+ gpio = <&pio 7 6 0>;
+ status = "disabled";
+ };
+
+ reg_usb2_vbus: usb2-vbus {
+ compatible = "regulator-fixed";
+ pinctrl-names = "default";
+ pinctrl-0 = <&usb2_vbus_pin_a>;
+ regulator-name = "usb2-vbus";
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ enable-active-high;
+ gpio = <&pio 7 3 0>;
+ status = "disabled";
+ };
+};
--
1.9.0
next prev parent reply other threads:[~2014-03-01 19:26 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-01 19:26 [PATCH 00/19] ARM: sunxi: dt: ahci, ehci and ohci support Hans de Goede
[not found] ` <1393701998-3553-1-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-03-01 19:26 ` Hans de Goede [this message]
2014-03-01 19:26 ` [PATCH 02/19] ARM: sun4i: dt: Add ahci / sata support Hans de Goede
2014-03-01 19:26 ` [PATCH 03/19] ARM: sun7i: " Hans de Goede
2014-03-01 19:26 ` [PATCH 04/19] ARM: sun4i: dt: Add USB host bindings Hans de Goede
2014-03-01 19:26 ` [PATCH 05/19] ARM: sun5i: " Hans de Goede
2014-03-01 19:26 ` [PATCH 06/19] ARM: sun7i: " Hans de Goede
2014-03-01 19:26 ` [PATCH 07/19] ARM: sun4i: dt: Add USB host nodes to Mele A1000 dts Hans de Goede
2014-03-01 19:26 ` [PATCH 08/19] ARM: sun4i: dt: Add USB host nodes to cubieboard dts Hans de Goede
2014-03-01 19:26 ` [PATCH 09/19] ARM: sun4i: dt: Add USB host nodes to hackberry dts Hans de Goede
2014-03-01 19:26 ` [PATCH 10/19] ARM: sun4i: dt: Add USB host nodes to mini-xplus dts Hans de Goede
2014-03-01 19:26 ` [PATCH 11/19] ARM: sun4i: dt: Add USB host nodes to pcduino.dts Hans de Goede
2014-03-01 19:26 ` [PATCH 12/19] ARM: sun5i: dt: Add USB host nodes to A13-Olinuxino Hans de Goede
2014-03-01 19:26 ` [PATCH 13/19] ARM: sun5i: dt: Add USB host nodes to a10s-olinuxino-micro Hans de Goede
2014-03-01 19:26 ` [PATCH 14/19] ARM: sun5i: dt: Add USB host nodes to a13-olinuxino-micro Hans de Goede
2014-03-01 19:26 ` [PATCH 15/19] ARM: sun7i: dt: Add USB host nodes to cubietruck dts Hans de Goede
2014-03-01 19:26 ` [PATCH 16/19] ARM: sun7i: dt: Add USB host nodes to cubieboard2 dts Hans de Goede
2014-03-01 19:26 ` [PATCH 17/19] ARM: sun7i: dt: Add USB host nodes to a20-olinuxino-micro dts Hans de Goede
2014-03-01 19:26 ` [PATCH 18/19] ARM: sun4i: dt: Add support for the A10-OLinuXino-LIME board Hans de Goede
2014-03-01 19:26 ` [PATCH 19/19] ARM: sun4i: dt: Add support for the INet-97F_Rev_02 board Hans de Goede
2014-03-04 16:48 ` [PATCH 00/19] ARM: sunxi: dt: ahci, ehci and ohci support Maxime Ripard
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1393701998-3553-2-git-send-email-hdegoede@redhat.com \
--to=hdegoede-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
--cc=maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).