* [PATCH v2 0/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG and LRADC keys
@ 2015-07-31 14:40 Chen-Yu Tsai
2015-07-31 14:40 ` [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC Chen-Yu Tsai
2015-07-31 14:40 ` [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller Chen-Yu Tsai
0 siblings, 2 replies; 5+ messages in thread
From: Chen-Yu Tsai @ 2015-07-31 14:40 UTC (permalink / raw)
To: linux-arm-kernel
Hi Maxime,
This series enables USB OTG and the volume buttons on the side of
the HSG-H702 tablet.
v2 uses a reference for usb0_vbus_pin_a, instead of full path.
The third patch is also dropped to avoid confusion.
Regards
ChenYu
Chen-Yu Tsai (2):
ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC
ARM: dts: sun5i: hsg-h702: Enable USB OTG controller
arch/arm/boot/dts/sun5i-a13-hsg-h702.dts | 58 ++++++++++++++++++++++++++++++++
1 file changed, 58 insertions(+)
--
2.5.0
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC
2015-07-31 14:40 [PATCH v2 0/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG and LRADC keys Chen-Yu Tsai
@ 2015-07-31 14:40 ` Chen-Yu Tsai
2015-07-31 17:00 ` Maxime Ripard
2015-07-31 14:40 ` [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller Chen-Yu Tsai
1 sibling, 1 reply; 5+ messages in thread
From: Chen-Yu Tsai @ 2015-07-31 14:40 UTC (permalink / raw)
To: linux-arm-kernel
The tablet has volume up/down buttons on the side, connected to the LRADC.
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
arch/arm/boot/dts/sun5i-a13-hsg-h702.dts | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts b/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
index 990f9d61ae4d..4b8808ab9711 100644
--- a/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
+++ b/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
@@ -45,6 +45,7 @@
#include "sunxi-common-regulators.dtsi"
#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
#include <dt-bindings/pinctrl/sun4i-a10.h>
/ {
@@ -96,6 +97,25 @@
status = "okay";
};
+&lradc {
+ vref-supply = <®_ldo2>;
+ status = "okay";
+
+ button at 200 {
+ label = "Volume Up";
+ linux,code = <KEY_VOLUMEUP>;
+ channel = <0>;
+ voltage = <200000>;
+ };
+
+ button at 400 {
+ label = "Volume Down";
+ linux,code = <KEY_VOLUMEDOWN>;
+ channel = <0>;
+ voltage = <400000>;
+ };
+};
+
&mmc0 {
pinctrl-names = "default";
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_h702>;
--
2.5.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller
2015-07-31 14:40 [PATCH v2 0/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG and LRADC keys Chen-Yu Tsai
2015-07-31 14:40 ` [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC Chen-Yu Tsai
@ 2015-07-31 14:40 ` Chen-Yu Tsai
2015-07-31 17:00 ` Maxime Ripard
1 sibling, 1 reply; 5+ messages in thread
From: Chen-Yu Tsai @ 2015-07-31 14:40 UTC (permalink / raw)
To: linux-arm-kernel
This tablet has proper USB OTG support, using 3 GPIO pins for
ID and VBUS detection, and also VBUS control.
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
arch/arm/boot/dts/sun5i-a13-hsg-h702.dts | 38 ++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
diff --git a/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts b/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
index 4b8808ab9711..3724b988064e 100644
--- a/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
+++ b/arch/arm/boot/dts/sun5i-a13-hsg-h702.dts
@@ -130,6 +130,10 @@
status = "okay";
};
+&otg_sram {
+ status = "okay";
+};
+
&pio {
mmc0_cd_pin_h702: mmc0_cd_pin at 0 {
allwinner,pins = "PG0";
@@ -137,6 +141,20 @@
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
};
+
+ usb0_id_detect_pin: usb0_id_detect_pin at 0 {
+ allwinner,pins = "PG2";
+ allwinner,function = "gpio_in";
+ allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+ allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
+ };
+
+ usb0_vbus_detect_pin: usb0_vbus_detect_pin at 0 {
+ allwinner,pins = "PG1";
+ allwinner,function = "gpio_in";
+ allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+ allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+ };
};
#include "axp209.dtsi"
@@ -172,13 +190,33 @@
regulator-name = "vcc-wifi";
};
+®_usb0_vbus {
+ pinctrl-0 = <&usb0_vbus_pin_a>;
+ gpio = <&pio 6 12 GPIO_ACTIVE_HIGH>; /* PG12 */
+ status = "okay";
+};
+
&uart1 {
pinctrl-names = "default";
pinctrl-0 = <&uart1_pins_b>;
status = "okay";
};
+&usb_otg {
+ dr_mode = "otg";
+ status = "okay";
+};
+
+&usb0_vbus_pin_a {
+ allwinner,pins = "PG12";
+};
+
&usbphy {
+ pinctrl-names = "default";
+ pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
+ usb0_id_det-gpios = <&pio 6 2 GPIO_ACTIVE_HIGH>; /* PG2 */
+ usb0_vbus_det-gpios = <&pio 6 1 GPIO_ACTIVE_HIGH>; /* PG1 */
+ usb0_vbus-supply = <®_usb0_vbus>;
usb1_vbus-supply = <®_ldo3>;
status = "okay";
};
--
2.5.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC
2015-07-31 14:40 ` [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC Chen-Yu Tsai
@ 2015-07-31 17:00 ` Maxime Ripard
0 siblings, 0 replies; 5+ messages in thread
From: Maxime Ripard @ 2015-07-31 17:00 UTC (permalink / raw)
To: linux-arm-kernel
1;3803;0c
On Fri, Jul 31, 2015 at 10:40:58PM +0800, Chen-Yu Tsai wrote:
> The tablet has volume up/down buttons on the side, connected to the LRADC.
>
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Applied, thanks!
Maxime
--
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150731/754edc0a/attachment.sig>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller
2015-07-31 14:40 ` [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller Chen-Yu Tsai
@ 2015-07-31 17:00 ` Maxime Ripard
0 siblings, 0 replies; 5+ messages in thread
From: Maxime Ripard @ 2015-07-31 17:00 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Jul 31, 2015 at 10:40:59PM +0800, Chen-Yu Tsai wrote:
> This tablet has proper USB OTG support, using 3 GPIO pins for
> ID and VBUS detection, and also VBUS control.
>
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Applied, thanks!
Maxime
--
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150731/27bc03ff/attachment.sig>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-07-31 17:00 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-31 14:40 [PATCH v2 0/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG and LRADC keys Chen-Yu Tsai
2015-07-31 14:40 ` [PATCH v2 1/2] ARM: dts: sun5i: hsg-h702: Enable side volume buttons with LRADC Chen-Yu Tsai
2015-07-31 17:00 ` Maxime Ripard
2015-07-31 14:40 ` [PATCH v2 2/2] ARM: dts: sun5i: hsg-h702: Enable USB OTG controller Chen-Yu Tsai
2015-07-31 17:00 ` Maxime Ripard
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.