linux/arch/arm
Siarhei Siamashka 5d0c8b190a ARM: dts: sun4i: Enable USB DRC on pcDuino1/2
Enable the otg/drc usb controller on the pcDuino1/2 board. Note
that the pcDuino1 FEX file from the vendor contains the following
information in the [usbc0] section:
    usb_id_gpio = port:PH04<0><1><default><default>
    usb_det_vbus_gpio = port:PH05<0><0><default><default>
    usb_drv_vbus_gpio = port:PB09<1><0><default><0>
While the pcDuino2 FEX has:
    usb_id_gpio = port:PH04<0><1><default><default>
    usb_det_vbus_gpio = port:PH05<0><0><default><default>
    usb_drv_vbus_gpio = port:PD02<1><0><default><0>

The ID pin is indeed PH4. The PD2 pin can be used to switch power
on/off for the USB Type A receptacle on pcDuino2, but it has nothing
to do with the MicroUSB OTG receptacle. The VBUS pin of the MicroUSB
receptacle is always connected to 5V according to the schematics
(both pcDuino1 and pcDuino2) and confirmed by doing some tests on
pcDuino2. The PH5 pin is just one of the pins on the J8 expansion
header and has nothing to do with USB OTG. The PB9 pin is pulled
up and connected to the N_VBUSEN pin of AXP209 PMIC, while the
VBUS pin of AXP209 only has a capacitor between it and the
ground (this pin is not used for anything else).

To sum it up. Only the ID pin (PH4) has a real use. And 5V voltage
is always served to the MicroUSB OTG receptacle no matter what is
the state of the PB9/PD2 pins.

This patch has been tested on pcDuino2 to work fine in a host role
with a USB keyboard connected via an OTG cable. It also works fine
in a device role (cdc_ether) with a regular Micro-B cable connected
to a desktop PC.

Signed-off-by: Siarhei Siamashka <siarhei.siamashka@gmail.com>
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
2015-10-11 19:06:22 +02:00
..
boot ARM: dts: sun4i: Enable USB DRC on pcDuino1/2 2015-10-11 19:06:22 +02:00
common Merge branch 'for-linus' of git://ftp.arm.linux.org.uk/~rmk/linux-arm 2015-09-03 16:27:01 -07:00
configs ARM: SoC: late fixes and dependencies 2015-09-10 17:59:04 -07:00
crypto
firmware
include Merge branch 'akpm' (patches from Andrew) 2015-09-10 18:19:42 -07:00
kernel Merge branch 'nmi' of git://ftp.arm.linux.org.uk/~rmk/linux-arm 2015-09-08 12:28:10 -07:00
kvm arm: KVM: keep arm vfp/simd exit handling consistent with arm64 2015-08-19 22:27:58 +01:00
lib Merge branches 'cleanup', 'fixes', 'misc', 'omap-barrier' and 'uaccess' into for-linus 2015-09-03 15:28:37 +01:00
mach-alpine
mach-asm9260
mach-at91 genalloc: add name arg to gen_pool_get() and devm_gen_pool_create() 2015-09-04 16:54:41 -07:00
mach-axxia
mach-bcm ARM: SoC platform updates for v4.3 2015-09-01 12:18:40 -07:00
mach-berlin
mach-clps711x libnvdimm for 4.3: 2015-09-08 14:35:59 -07:00
mach-cns3xxx ARM: appropriate __init annotation for const data 2015-07-28 13:55:27 +02:00
mach-davinci ARM: SoC platform updates for v4.3 2015-09-01 12:18:40 -07:00
mach-digicolor ARM: appropriate __init annotation for const data 2015-07-28 13:55:27 +02:00
mach-dove Merge branch 'queue/irq/arm' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into next/cleanup 2015-08-05 17:24:11 +02:00
mach-ebsa110 ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-efm32
mach-ep93xx ARM/fb: ep93xx: switch framebuffer to use modedb only 2015-08-13 12:25:44 +02:00
mach-exynos ARM: SoC: late fixes and dependencies 2015-09-10 17:59:04 -07:00
mach-footbridge ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-gemini ARM: gemini: Setup timer3 as free running timer 2015-08-13 11:41:52 +02:00
mach-highbank ARM: migrate to common PSCI client code 2015-08-03 15:38:39 +01:00
mach-hisi
mach-imx genalloc: add name arg to gen_pool_get() and devm_gen_pool_create() 2015-09-04 16:54:41 -07:00
mach-integrator
mach-iop13xx ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-iop32x ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-iop33x ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-ixp4xx ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-keystone
mach-ks8695 ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-lpc18xx
mach-lpc32xx Merge branch 'queue/irq/arm' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into next/cleanup 2015-08-05 17:24:11 +02:00
mach-mediatek
mach-meson
mach-mmp ARM: mmp: remove unused RTC register definitions 2015-09-05 19:37:17 +02:00
mach-moxart
mach-mv78xx0
mach-mvebu ARM: SoC driver updates for v4.3 2015-09-01 13:00:04 -07:00
mach-mxs ARM: appropriate __init annotation for const data 2015-07-28 13:55:27 +02:00
mach-netx ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-nomadik ARM: nomadik: move l2x0 setup to device tree 2015-08-11 15:29:59 +02:00
mach-nspire
mach-omap1 ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-omap2 Merge branch 'for-linus' of git://ftp.arm.linux.org.uk/~rmk/linux-arm 2015-09-03 16:27:01 -07:00
mach-orion5x ARM: DT updates for v4.3 2015-09-01 13:09:20 -07:00
mach-picoxcell
mach-prima2 Merge branches 'cleanup', 'fixes', 'misc', 'omap-barrier' and 'uaccess' into for-linus 2015-09-03 15:28:37 +01:00
mach-pxa ARM: pxa: add memory resource to SA1100 RTC device 2015-09-05 19:37:16 +02:00
mach-qcom
mach-realview ARM: appropriate __init annotation for const data 2015-07-28 13:55:27 +02:00
mach-rockchip ARM: rockchip: pm: Fix PTR_ERR() argument 2015-08-24 12:39:14 +02:00
mach-rpc ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-s3c24xx Samsung cleanup for v4.3 2015-08-11 14:59:02 +02:00
mach-s3c64xx ARM: SoC cleanups for v4.3 2015-09-01 12:10:20 -07:00
mach-s5pv210
mach-sa1100 ARM: sa1100: remove unused RTC register definitions 2015-09-05 19:37:17 +02:00
mach-shmobile libnvdimm for 4.3: 2015-09-08 14:35:59 -07:00
mach-socfpga genalloc: add name arg to gen_pool_get() and devm_gen_pool_create() 2015-09-04 16:54:41 -07:00
mach-spear ARM: SoC cleanups for v4.3 2015-09-01 12:10:20 -07:00
mach-sti ARM: SoC platform updates for v4.3 2015-09-01 12:18:40 -07:00
mach-stm32
mach-sunxi
mach-tegra ARM: SoC driver updates for v4.3 2015-09-01 13:00:04 -07:00
mach-u300
mach-uniphier ARM: uniphier: drop v7_invalidate_l1 call at secondary entry 2015-08-13 12:12:10 +02:00
mach-ux500 Merge branch 'for-linus' of git://ftp.arm.linux.org.uk/~rmk/linux-arm 2015-09-03 16:27:01 -07:00
mach-versatile
mach-vexpress irqchip/gic: Ensure gic_cpu_if_up/down() programs correct GIC instance 2015-08-04 14:14:06 +02:00
mach-vt8500
mach-w90x900 ARM: kill off set_irq_flags usage 2015-07-28 13:58:13 +02:00
mach-zx ARM: SoC platform updates for v4.3 2015-09-01 12:18:40 -07:00
mach-zynq Merge branch 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2015-09-01 14:33:35 -07:00
mm dma-mapping: consolidate dma_{alloc,free}_{attrs,coherent} 2015-09-10 13:29:01 -07:00
net ARM: net: add support for BPF_ANC | SKF_AD_HATYPE in ARM JIT. 2015-07-27 14:57:41 -07:00
nwfpe
oprofile
plat-iop
plat-omap
plat-orion Merge branch 'queue/irq/arm' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into next/cleanup 2015-08-05 17:24:11 +02:00
plat-pxa
plat-samsung ARM: SAMSUNG: remove keypad-core header in plat-samsung 2015-07-30 02:02:06 +09:00
plat-versatile
probes
tools
vdso ARM: 8405/1: VDSO: fix regression with toolchains lacking ld.bfd executable 2015-07-31 18:54:45 +01:00
vfp
xen xen/privcmd: Further s/MFN/GFN/ clean-up 2015-09-08 18:03:54 +01:00
Kconfig kexec: split kexec_load syscall from kexec core code 2015-09-10 13:29:01 -07:00
Kconfig-nommu
Kconfig.debug The i.MX SoC changes for 4.3: 2015-08-18 13:10:05 -07:00
Makefile ARM: 8418/1: add boot image dependencies to not generate invalid images 2015-08-18 13:59:59 +01:00