rockchip: rk3288-vyasa: dts fixes/additions
Subsystems (4)
cover rockchip: rk3288-vyasa: dts fixes/additions
Series add new dts nodes like gmac, usb and fixed existing regulator, pmic stuff as per schematic.
Jagan Teki (9):
ARM: dts: rockchip: Sync rk3288-vyasa dts from Linux
ARM: dts: rockchip: rk3288-vyasa: Remove vdd_log from rk808, DCDC_REG1
ARM: dts: rockchip: rk3288-vyasa: Use vmmc-supply from PMIC
ARM: dts: rockchip: Add regulators for rk3288-vyasa
ARM: dts: rockchip: Add gmac support for rk3288-vyasa board
rockchip: rk3288-vyasa: defconfig: Enable gmac support
ARM: dts: rockchip: Add usb host for rk3288-vyasa
ARM: dts: rockchip: Add usb otg for rk3288-vyasa
rockchip: rk3288-vyasa: defconfig: Enable USB host and otg
arch/arm/dts/rk3288-vyasa-u-boot.dtsi | 65 ++++++++ arch/arm/dts/rk3288-vyasa.dts | 292 +++++++++++++++++++++++++-------- board/amarula/vyasa-rk3288/MAINTAINERS | 2 + configs/vyasa-rk3288_defconfig | 16 ++ include/dt-bindings/pinctrl/rockchip.h | 1 + 5 files changed, 305 insertions(+), 71 deletions(-) create mode 100644 arch/arm/dts/rk3288-vyasa-u-boot.dtsi
Signature · 1 line
2.7.4
PATCH 1/9 ARM: dts: rockchip: Sync rk3288-vyasa dts from Linux
Sync rk3288-vyasa board dts from Linux for proper updates and maintenance
- rk3288-vyasa.dts: Similar to Linux dts
- rk3288-vyasa-u-boot.dtsi: u-boot dts changes
Also updated MAINTAINERS for these dts files.
--- arch/arm/dts/rk3288-vyasa-u-boot.dtsi | 65 ++++++++++++++++ arch/arm/dts/rk3288-vyasa.dts | 134 ++++++++++++++++++--------------- board/amarula/vyasa-rk3288/MAINTAINERS | 2 + 3 files changed, 141 insertions(+), 60 deletions(-) create mode 100644 arch/arm/dts/rk3288-vyasa-u-boot.dtsi
arch/arm/dts/rk3288-vyasa-u-boot.dtsi new file +65 -0
@@ -0,0 +1,65 @@ +/* + * Copyright (C) 2017 Jagan Teki <[email protected]> + * + * This file is dual-licensed: you can use it either under the terms + * of the GPL or the X11 license, at your option. Note that this dual + * licensing only applies to this file, and not this project as a + * whole. + * + * a) This file is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * Or, alternatively, + * + * b) Permission is hereby granted, free of charge, to any person + * obtaining a copy of this software and associated documentation + * files (the "Software"), to deal in the Software without + * restriction, including without limitation the rights to use, + * copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following + * conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES + * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + * OTHER DEALINGS IN THE SOFTWARE. + */ + +&dmc { + rockchip,pctl-timing = <0x29a 0xc8 0x1f8 0x42 0x4e 0x4 0xea 0xa + 0x5 0x0 0xa 0x7 0x19 0x24 0xa 0x7 + 0x5 0xa 0x5 0x200 0x5 0x10 0x40 0x0 + 0x1 0x7 0x7 0x4 0xc 0x43 0x100 0x0 + 0x5 0x0>; + rockchip,phy-timing = <0x48f9aab4 0xea0910 0x1002c200 + 0xa60 0x40 0x10 0x0>; + /* Add a dummy value to cause of-platdata think this is bytes */ + rockchip,sdram-params = <0x30B25564 0x627 3 666000000 3 9 1>; +}; + +&sdmmc { + u-boot,dm-pre-reloc; +}; + +&uart2 { + u-boot,dm-pre-reloc; +}; + +&pinctrl { + u-boot,dm-pre-reloc; +};
arch/arm/dts/rk3288-vyasa.dts +74 -60
295 lines not on this page · raw message
board/amarula/vyasa-rk3288/MAINTAINERS +2 -0
@@ -4,3 +4,5 @@ S: Maintained F: board/amarula/vyasa-rk3288 F: include/configs/vyasa-rk3288.h F: configs/vyasa-rk3288_defconfig +F: arch/arm/dts/rk3288-vyasa.dts +F: arch/arm/dts/rk3288-vyasa-u-boot.dtsi
Signature · 1 line
2.7.4
PATCH 1/9 ARM: dts: rockchip: Sync rk3288-vyasa dts from Linux
Quoted 6 lines
Sync rk3288-vyasa board dts from Linux for proper updates and maintenance
-rk3288-vyasa.dts: Similar to Linux dts
-rk3288-vyasa-u-boot.dtsi: u-boot dts changesAlso updated
MAINTAINERSfor these dts files.
Quoted 8 lines
Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa-u-boot.dtsi | 65 ++++++++++++++++ arch/arm/dts/rk3288-vyasa.dts | 134 ++++++++++++++++++--------------- board/amarula/vyasa-rk3288/MAINTAINERS | 2 + 3 files changed, 141 insertions(+), 60 deletions(-) create mode 100644 arch/arm/dts/rk3288-vyasa-u-boot.dtsi
PATCH 1/9 ARM: dts: rockchip: Sync rk3288-vyasa dts from Linux
In reply to Jagan TekiQuoted 6 lines
Sync rk3288-vyasa board dts from Linux for proper updates and maintenance
-rk3288-vyasa.dts: Similar to Linux dts
-rk3288-vyasa-u-boot.dtsi: u-boot dts changesAlso updated
MAINTAINERSfor these dts files.
Quoted 8 lines
Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa-u-boot.dtsi | 65 ++++++++++++++++ arch/arm/dts/rk3288-vyasa.dts | 134 ++++++++++++++++++--------------- board/amarula/vyasa-rk3288/MAINTAINERS | 2 + 3 files changed, 141 insertions(+), 60 deletions(-) create mode 100644 arch/arm/dts/rk3288-vyasa-u-boot.dtsi
PATCH 2/9 ARM: dts: rockchip: rk3288-vyasa: Remove vdd_log from rk808, DCDC_REG1
In reply to Jagan Tekivdd_log, never used on DCDC_REG1 of rk808 from latest schematic so remove the same and update the regulator-name as 'vdd_arm' to sync with existing rk3288 board dts files.
--- arch/arm/dts/rk3288-vyasa.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm/dts/rk3288-vyasa.dts +2 -2
@@ -121,8 +121,8 @@ vcc12-supply = <&vcc_io>; regulators { - vdd_cpu: vdd_log: DCDC_REG1 { - regulator-name = "vdd_log"; + vdd_cpu: DCDC_REG1 { + regulator-name = "vdd_arm"; regulator-min-microvolt = <750000>; regulator-max-microvolt = <1350000>; regulator-always-on;
Signature · 1 line
2.7.4
PATCH 2/9 ARM: dts: rockchip: rk3288-vyasa: Remove vdd_log from rk808, DCDC_REG1
Quoted 9 lines
vdd_log, never used onDCDC_REG1of rk808 from latest schematic so remove the same and update the regulator-name as 'vdd_arm' to sync with existing rk3288 board dts files.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
PATCH 2/9 ARM: dts: rockchip: rk3288-vyasa: Remove vdd_log from rk808, DCDC_REG1
In reply to Jagan TekiQuoted 9 lines
vdd_log, never used onDCDC_REG1of rk808 from latest schematic so remove the same and update the regulator-name as 'vdd_arm' to sync with existing rk3288 board dts files.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
PATCH 3/9 ARM: dts: rockchip: rk3288-vyasa: Use vmmc-supply from PMIC
In reply to Jagan Tekirk808, SWITCH_REG1 has configured for sdmmc regulator as vcc_sd, so use the same by renaming vcc33_sd to vcc_sd(as per schematic) and drop explicit regulator definition from root.
--- arch/arm/dts/rk3288-vyasa.dts | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-)
arch/arm/dts/rk3288-vyasa.dts +2 -20
@@ -56,18 +56,6 @@ device_type = "memory"; }; - vcc_sd: sdmmc-regulator { - compatible = "regulator-fixed"; - gpio = <&gpio7 RK_PB3 GPIO_ACTIVE_LOW>; - pinctrl-names = "default"; - pinctrl-0 = <&sdmmc_pwr>; - regulator-name = "vcc_sd"; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - startup-delay-us = <100000>; - vin-supply = <&vcc_io>; - }; - vcc_sys: vsys-regulator { compatible = "regulator-fixed"; regulator-name = "vcc_sys";
@@ -260,8 +248,8 @@ }; }; - vcc33_sd: SWITCH_REG1 { - regulator-name = "vcc33_sd"; + vcc_sd: SWITCH_REG1 { + regulator-name = "vcc_sd"; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; regulator-always-on;
@@ -332,10 +320,4 @@ rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>; }; }; - - sdmmc { - sdmmc_pwr: sdmmc-pwr { - rockchip,pins = <7 11 RK_FUNC_GPIO &pcfg_pull_none>; - }; - }; };
Signature · 1 line
2.7.4
PATCH 3/9 ARM: dts: rockchip: rk3288-vyasa: Use vmmc-supply from PMIC
Quoted 9 lines
rk808,
SWITCH_REG1has configured for sdmmc regulator asvcc_sd, so use the same by renamingvcc33_sdtovcc_sd(as per schematic)and drop explicit regulator definition from root.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-)
PATCH 3/9 ARM: dts: rockchip: rk3288-vyasa: Use vmmc-supply from PMIC
In reply to Jagan TekiQuoted 9 lines
rk808,
SWITCH_REG1has configured for sdmmc regulator asvcc_sd, so use the same by renamingvcc33_sdtovcc_sd(as per schematic)and drop explicit regulator definition from root.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-)
PATCH 4/9 ARM: dts: rockchip: Add regulators for rk3288-vyasa
In reply to Jagan TekiAdd supporting regulators for rk3288-vyasa board, dc12_vbat is parent regulatorand followed regulators as are child regulators. regulator naming conversion followed as per schematic for better readability and easy for identification.
--- arch/arm/dts/rk3288-vyasa.dts | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+)
arch/arm/dts/rk3288-vyasa.dts +40 -0
@@ -56,13 +56,53 @@ device_type = "memory"; }; + dc12_vbat: dc12-vbat { + compatible = "regulator-fixed"; + regulator-name = "dc12_vbat"; + regulator-min-microvolt = <12000000>; + regulator-max-microvolt = <12000000>; + regulator-always-on; + regulator-boot-on; + }; + + vboot_3v3: vboot-3v3 { + compatible = "regulator-fixed"; + regulator-name = "vboot_3v3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&dc12_vbat>; + }; + vcc_sys: vsys-regulator { compatible = "regulator-fixed"; regulator-name = "vcc_sys"; + regulator-min-microvolt = <3700000>; + regulator-max-microvolt = <3700000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&dc12_vbat>; + }; + + vboot_5v: vboot-5v { + compatible = "regulator-fixed"; + regulator-name = "vboot_sv"; regulator-min-microvolt = <5000000>; regulator-max-microvolt = <5000000>; regulator-always-on; regulator-boot-on; + vin-supply = <&dc12_vbat>; + }; + + v3g_3v3: v3g-3v3 { + compatible = "regulator-fixed"; + regulator-name = "v3g_3v3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&dc12_vbat>; }; };
Signature · 1 line
2.7.4
PATCH 4/9 ARM: dts: rockchip: Add regulators for rk3288-vyasa
Quoted 10 lines
Add supporting regulators for rk3288-vyasa board,
dc12_vbatis parent regulatorand followed regulators as are child regulators. regulator naming conversion followed as per schematic for better readability and easy for identification.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+)
PATCH 4/9 ARM: dts: rockchip: Add regulators for rk3288-vyasa
In reply to Jagan TekiQuoted 10 lines
Add supporting regulators for rk3288-vyasa board,
dc12_vbatis parent regulatorand followed regulators as are child regulators. regulator naming conversion followed as per schematic for better readability and easy for identification.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+)
PATCH 5/9 ARM: dts: rockchip: Add gmac support for rk3288-vyasa board
In reply to Jagan Teki--- arch/arm/dts/rk3288-vyasa.dts | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+)
arch/arm/dts/rk3288-vyasa.dts +41 -0
@@ -104,12 +104,35 @@ regulator-boot-on; vin-supply = <&dc12_vbat>; }; + + ext_gmac: external-gmac-clock { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <125000000>; + clock-output-names = "ext_gmac"; + }; }; &cpu0 { cpu0-supply = <&vdd_cpu>; }; +&gmac { + assigned-clocks = <&cru SCLK_MAC>; + assigned-clock-parents = <&ext_gmac>; + clock_in_out = "input"; + pinctrl-names = "default"; + pinctrl-0 = <&rgmii_pins>, <&phy_rst>, <&phy_pmeb>, <&phy_int>; + phy-supply = <&vcc_lan>; + phy-mode = "rgmii"; + snps,reset-active-low; + snps,reset-delays-us = <0 10000 1000000>; + snps,reset-gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>; + tx_delay = <0x30>; + rx_delay = <0x10>; + status = "okay"; +}; + &gpu { mali-supply = <&vdd_gpu>; status = "okay";
@@ -355,6 +378,24 @@ }; &pinctrl { + pcfg_output_high: pcfg-output-high { + output-high; + }; + + gmac { + phy_int: phy-int { + rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; + }; + + phy_pmeb: phy-pmeb { + rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_up>; + }; + + phy_rst: phy-rst { + rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_output_high>; + }; + }; + pmic { pmic_int: pmic-int { rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>;
Signature · 1 line
2.7.4
PATCH 5/9 ARM: dts: rockchip: Add gmac support for rk3288-vyasa board
Quoted 5 lines
Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+)
PATCH 5/9 ARM: dts: rockchip: Add gmac support for rk3288-vyasa board
In reply to Jagan TekiQuoted 1 line · Jagan Teki
Signed-off-by Jagan Teki <[email protected]>
Commit message?
Quoted 70 lines
---
arch/arm/dts/rk3288-vyasa.dts| 41 +++++++++++++++++++++++++++++++++++++++++1 file changed, 41 insertions(+)arch/arm/dts/rk3288-vyasa.dts +41
-0@@ -104,12 +104,35 @@ regulator-boot-on; vin-supply = <&dc12_vbat>; }; + + ext_gmac: external-gmac-clock { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <125000000>; + clock-output-names = "ext_gmac"; + }; }; &cpu0 { cpu0-supply = <&vdd_cpu>; }; +&gmac { + assigned-clocks = <&cru SCLK_MAC>; + assigned-clock-parents = <&ext_gmac>; + clock_in_out = "input"; + pinctrl-names = "default"; + pinctrl-0 = <&rgmii_pins>, <&phy_rst>, <&phy_pmeb>, <&phy_int>; + phy-supply = <&vcc_lan>; + phy-mode = "rgmii"; + snps,reset-active-low; + snps,reset-delays-us = <0 10000 1000000>; + snps,reset-gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>; + tx_delay = <0x30>; + rx_delay = <0x10>; + status = "okay"; +}; + &gpu { mali-supply = <&vdd_gpu>; status = "okay";@@ -355,6 +378,24 @@ }; &pinctrl { + pcfg_output_high: pcfg-output-high { + output-high; + }; + + gmac { + phy_int: phy-int { + rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; + }; + + phy_pmeb: phy-pmeb { + rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_up>; + }; + + phy_rst: phy-rst { + rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_output_high>; + }; + }; + pmic { pmic_int: pmic-int { rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>;
PATCH 6/9 rockchip: rk3288-vyasa: defconfig: Enable gmac support
In reply to Jagan TekiEnable gmac support for rk3288-vyasa board.
--- configs/vyasa-rk3288_defconfig | 3 +++ 1 file changed, 3 insertions(+)
configs/vyasa-rk3288_defconfig +3 -0
@@ -42,6 +42,9 @@ CONFIG_LED=y CONFIG_LED_GPIO=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y +CONFIG_DM_ETH=y +CONFIG_ETH_DESIGNWARE=y +CONFIG_GMAC_ROCKCHIP=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y # CONFIG_SPL_PINCTRL_FULL is not set
Signature · 1 line
2.7.4
PATCH 6/9 rockchip: rk3288-vyasa: defconfig: Enable gmac support
Quoted 7 lines
Enable gmac support for rk3288-vyasa board.
Signed-off-by Jagan Teki <[email protected]>--- configs/vyasa-rk3288_defconfig | 3 +++ 1 file changed, 3 insertions(+)
PATCH 6/9 rockchip: rk3288-vyasa: defconfig: Enable gmac support
In reply to Jagan TekiQuoted 7 lines
Enable gmac support for rk3288-vyasa board.
Signed-off-by Jagan Teki <[email protected]>--- configs/vyasa-rk3288_defconfig | 3 +++ 1 file changed, 3 insertions(+)
PATCH 7/9 ARM: dts: rockchip: Add usb host for rk3288-vyasa
In reply to Jagan TekiAdd usb host support for rk3288-vyasa, board support hub power through phy_pwr_en and usb2 host power through usb2_pwr_en and naming conversion followed as per schematic.
--- arch/arm/dts/rk3288-vyasa.dts | 48 ++++++++++++++++++++++++++++++++++ include/dt-bindings/pinctrl/rockchip.h | 1 + 2 files changed, 49 insertions(+)
arch/arm/dts/rk3288-vyasa.dts +48 -0
@@ -105,6 +105,30 @@ vin-supply = <&dc12_vbat>; }; + vsus_5v: vsus-5v { + compatible = "regulator-fixed"; + regulator-name = "vsus_5v"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vcc_io>; + }; + + vusb2_5v: vusb2-5v { + compatible = "regulator-fixed"; + regulator-name = "vusb2_5v"; + enable-active-high; + gpio = <&gpio8 RK_PB1 GPIO_ACTIVE_HIGH>; /* USB2_PWR_EN */ + pinctrl-names = "default"; + pinctrl-0 = <&usb2_pwr_en>; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vsus_5v>; + }; + ext_gmac: external-gmac-clock { compatible = "fixed-clock"; #clock-cells = <0>;
@@ -357,6 +381,20 @@ status = "okay"; }; +&usbphy { + status = "okay"; +}; + +&usb_host0_ehci { + status = "okay"; +}; + +&usb_host1 { + pinctrl-names = "default"; + pinctrl-0 = <&phy_pwr_en>; + status = "okay"; +}; + &vopb { status = "okay"; };
@@ -401,4 +439,14 @@ rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>; }; }; + + usb_host { + phy_pwr_en: phy-pwr-en { + rockchip,pins = <RK_GPIO2 RK_PB1 RK_FUNC_GPIO &pcfg_output_high>; + }; + + usb2_pwr_en: usb2-pwr-en { + rockchip,pins = <RK_GPIO8 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; };
include/dt-bindings/pinctrl/rockchip.h +1 -0
@@ -16,6 +16,7 @@#define RK_GPIO3 3#define RK_GPIO4 4#define RK_GPIO6 6 +#define RK_GPIO8 8#define RK_PA0 0#define RK_PA1 1
Signature · 1 line
2.7.4
PATCH 7/9 ARM: dts: rockchip: Add usb host for rk3288-vyasa
Quoted 10 lines
Add usb host support for rk3288-vyasa, board support hub power through
phy_pwr_enand usb2 host power throughusb2_pwr_enand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 48 ++++++++++++++++++++++++++++++++++ include/dt-bindings/pinctrl/rockchip.h | 1 + 2 files changed, 49 insertions(+)
PATCH 7/9 ARM: dts: rockchip: Add usb host for rk3288-vyasa
In reply to Jagan TekiQuoted 86 lines · Jagan Teki
Add usb host support for rk3288-vyasa, board support hub power through
phy_pwr_enand usb2 host power throughusb2_pwr_enand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>---
arch/arm/dts/rk3288-vyasa.dts| 48 ++++++++++++++++++++++++++++++++++include/dt-bindings/pinctrl/rockchip.h| 1 +2 files changed, 49 insertions(+)arch/arm/dts/rk3288-vyasa.dts +48
-0@@ -105,6 +105,30 @@ vin-supply = <&dc12_vbat>; }; + vsus_5v: vsus-5v { + compatible = "regulator-fixed"; + regulator-name = "vsus_5v"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vcc_io>; + }; + + vusb2_5v: vusb2-5v { + compatible = "regulator-fixed"; + regulator-name = "vusb2_5v"; + enable-active-high; + gpio = <&gpio8 RK_PB1 GPIO_ACTIVE_HIGH>; /* USB2_PWR_EN */ + pinctrl-names = "default"; + pinctrl-0 = <&usb2_pwr_en>; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vsus_5v>; + }; + ext_gmac: external-gmac-clock { compatible = "fixed-clock"; #clock-cells = <0>;@@ -357,6 +381,20 @@ status = "okay"; }; +&usbphy { + status = "okay"; +}; + +&usb_host0_ehci { + status = "okay"; +}; + +&usb_host1 { + pinctrl-names = "default"; + pinctrl-0 = <&phy_pwr_en>; + status = "okay"; +}; + &vopb { status = "okay"; };@@ -401,4 +439,14 @@ rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>; }; }; + + usb_host { + phy_pwr_en: phy-pwr-en { + rockchip,pins = <RK_GPIO2 RK_PB1 RK_FUNC_GPIO &pcfg_output_high>; + }; + + usb2_pwr_en: usb2-pwr-en { + rockchip,pins = <RK_GPIO8 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; };include/dt-bindings/pinctrl/rockchip.h +0
-0
include/dt-bindings/pinctrl/rockchip.h line 19
Quoted 4 lines
include/dt-bindings/pinctrl/rockchip.h +1
-0@@ -16,6 +16,7 @@#define RK_GPIO3 3#define RK_GPIO4 4#define RK_GPIO6 6 +#define RK_GPIO8 8
This file is shared with Linux (and the way I understand it, the Linux side is leading): has the same already been committed on the Linux side?
Quoted 4 lines
include/dt-bindings/pinctrl/rockchip.h +0
-0#define RK_PA0 0#define RK_PA1 1
PATCH 7/9 ARM: dts: rockchip: Add usb host for rk3288-vyasa
Quoted 95 lines · Philipp Tomsich
Quoted 91 lines · Jagan Teki
Add usb host support for rk3288-vyasa, board support hub power through
phy_pwr_enand usb2 host power throughusb2_pwr_enand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>---
arch/arm/dts/rk3288-vyasa.dts| 48
++++++++++++++++++++++++++++++++++include/dt-bindings/pinctrl/rockchip.h| 1 +2 files changed, 49 insertions(+)arch/arm/dts/rk3288-vyasa.dts +42
-0@@ -105,6 +105,30 @@ vin-supply = <&dc12_vbat>; }; + vsus_5v: vsus-5v { + compatible = "regulator-fixed"; + regulator-name = "vsus_5v"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vcc_io>; + }; + + vusb2_5v: vusb2-5v { + compatible = "regulator-fixed"; + regulator-name = "vusb2_5v"; + enable-active-high; + gpio = <&gpio8 RK_PB1 GPIO_ACTIVE_HIGH>; /* USB2_PWR_EN */ + pinctrl-names = "default"; + pinctrl-0 = <&usb2_pwr_en>; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vsus_5v>; + }; + ext_gmac: external-gmac-clock { compatible = "fixed-clock"; #clock-cells = <0>;@@ -357,6 +381,20 @@ status = "okay"; }; +&usbphy { + status = "okay"; +}; + +&usb_host0_ehci { + status = "okay"; +}; + +&usb_host1 { + pinctrl-names = "default"; + pinctrl-0 = <&phy_pwr_en>; + status = "okay"; +}; + &vopb { status = "okay"; };@@ -401,4 +439,14 @@ rockchip,pins = <RK_GPIO0 4 RK_FUNC_GPIO &pcfg_pull_up>; }; }; + + usb_host { + phy_pwr_en: phy-pwr-en { + rockchip,pins = <RK_GPIO2 RK_PB1 RK_FUNC_GPIO
&pcfg_output_high>;arch/arm/dts/rk3288-vyasa.dts +4
-0+ }; + + usb2_pwr_en: usb2-pwr-en { + rockchip,pins = <RK_GPIO8 RK_PB1 RK_FUNC_GPIO
&pcfg_pull_none>;arch/arm/dts/rk3288-vyasa.dts +2
-0+ }; + };};
include/dt-bindings/pinctrl/rockchip.h +0
-0@@ -16,6 +16,7 @@
Quoted 8 lines
include/dt-bindings/pinctrl/rockchip.h line 19
Quoted 4 lines
include/dt-bindings/pinctrl/rockchip.h +1
-0#define RK_GPIO3 3#define RK_GPIO4 4#define RK_GPIO6 6 +#define RK_GPIO8 8This file is shared with Linux (and the way I understand it, the Linux side is leading): has the same already been committed on the Linux side?
Yeah, it's committed in linux-next.
thanks!
Signature · 4 lines
Jagan Teki Free Software Engineer | www.openedev.com U-Boot, Linux | Upstream Maintainer Hyderabad, India.
PATCH 7/9 ARM: dts: rockchip: Add usb host for rk3288-vyasa
In reply to Jagan TekiQuoted 11 lines
Add usb host support for rk3288-vyasa, board support hub power through
phy_pwr_enand usb2 host power throughusb2_pwr_enand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>Acked-by Philipp Tomsich <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 48 ++++++++++++++++++++++++++++++++++ include/dt-bindings/pinctrl/rockchip.h | 1 + 2 files changed, 49 insertions(+)
PATCH 8/9 ARM: dts: rockchip: Add usb otg for rk3288-vyasa
In reply to Jagan TekiAdd usb otg support for rk3288-vyasa, board support usb1 otg power through otg_vbus_drv and naming conversion followed as per schematic.
--- arch/arm/dts/rk3288-vyasa.dts | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+)
arch/arm/dts/rk3288-vyasa.dts +25 -0
@@ -115,6 +115,20 @@ vin-supply = <&vcc_io>; }; + vusb1_5v: vusb1-5v { + compatible = "regulator-fixed"; + regulator-name = "vusb1_5v"; + enable-active-high; + gpio = <&gpio0 RK_PB4 GPIO_ACTIVE_HIGH>; /* OTG_VBUS_DRV */ + pinctrl-names = "default"; + pinctrl-0 = <&otg_vbus_drv>; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vsus_5v>; + }; + vusb2_5v: vusb2-5v { compatible = "regulator-fixed"; regulator-name = "vusb2_5v";
@@ -395,6 +409,10 @@ status = "okay"; }; +&usb_otg { + status = "okay"; +}; + &vopb { status = "okay"; };
@@ -449,4 +467,11 @@ rockchip,pins = <RK_GPIO8 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; }; }; + + usb_otg { + otg_vbus_drv: otg-vbus-drv { + rockchip,pins = <RK_GPIO0 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; + + }; + }; };
Signature · 1 line
2.7.4
PATCH 8/9 ARM: dts: rockchip: Add usb otg for rk3288-vyasa
Quoted 9 lines
Add usb otg support for rk3288-vyasa, board support usb1 otg power through
otg_vbus_drvand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+)
PATCH 8/9 ARM: dts: rockchip: Add usb otg for rk3288-vyasa
In reply to Jagan TekiQuoted 9 lines
Add usb otg support for rk3288-vyasa, board support usb1 otg power through
otg_vbus_drvand naming conversion followed as per schematic.Signed-off-by Jagan Teki <[email protected]>--- arch/arm/dts/rk3288-vyasa.dts | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+)
PATCH 9/9 rockchip: rk3288-vyasa: defconfig: Enable USB host and otg
In reply to Jagan TekiEnable USB host and otg for rk3288-vyasa board.
--- configs/vyasa-rk3288_defconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+)
configs/vyasa-rk3288_defconfig +13 -0
@@ -15,6 +15,7 @@ CONFIG_SPL_STACK_R=y CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x2000 CONFIG_CMD_GPIO=y CONFIG_CMD_GPT=y +CONFIG_CMD_USB=y CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y # CONFIG_CMD_SETEXPR is not set
@@ -62,6 +63,18 @@ CONFIG_DEBUG_UART_CLOCK=24000000 CONFIG_DEBUG_UART_SHIFT=2 CONFIG_SYS_NS16550=y CONFIG_SYSRESET=y +CONFIG_USB=y +CONFIG_USB_DWC2=y +CONFIG_USB_STORAGE=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_GADGET=y +CONFIG_USB_GADGET_MANUFACTURER="Rockchip" +CONFIG_USB_GADGET_VENDOR_NUM=0x2207 +CONFIG_USB_GADGET_PRODUCT_NUM=0x320a +CONFIG_USB_GADGET_DWC2_OTG=y +CONFIG_USB_HOST_ETHER=y +CONFIG_USB_ETHER_ASIX=y +CONFIG_USB_ETHER_SMSC95XX=y CONFIG_USE_TINY_PRINTF=y CONFIG_CMD_DHRYSTONE=y CONFIG_ERRNO_STR=y
Signature · 1 line
2.7.4
PATCH 9/9 rockchip: rk3288-vyasa: defconfig: Enable USB host and otg
Quoted 7 lines
Enable USB host and otg for rk3288-vyasa board.
Signed-off-by Jagan Teki <[email protected]>--- configs/vyasa-rk3288_defconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+)
PATCH 9/9 rockchip: rk3288-vyasa: defconfig: Enable USB host and otg
In reply to Jagan TekiQuoted 7 lines
Enable USB host and otg for rk3288-vyasa board.
Signed-off-by Jagan Teki <[email protected]>--- configs/vyasa-rk3288_defconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+)