Viola Plus, USB X6 bottom not working, when JP2 is closed

Problem: USB X6 bottom connector is not working when powering Viola Plus 1.2 through micro usb X4 connector with jumper JP2 closed.

I am powering using ‘tampered’ micro usb cable - i know, that micro usb X4 and USB X6 bottom are connected together through R56, R55. I have cut D+ and D- signals (white and green cables) in my usb cable, so only power would be connected to viola via micro usb.

When powering using X3 connector with JP2 open, then the USB X6 bottom connector is working and OS is properly enumerating USB device.

The kernel does not register a second EHCI host controller, when JP2 is closed. When JP2 is open, the kernel is registering two USB buses:

# lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

I think, jumper JP2 is switching USB0 mode from host to client. I suspect, jumper JP2 is somehow connected to pin on the Colibri VF61 - connector X1 pin number 137 / ‘USB Client Cable Detect’ / USB0_VBUS_DETECT / PTC29. The ‘USB0_VBUS_DETECT’ signal probably switches USB0 from ‘host mode’ to ‘client mode’. I think. Anyway - Is there any software way i can force the USB0 to be in ‘host mode’?

Sry my bad English. : )

Your analysis is almost correct, in fact VCC_USB_C (the power pin of the USB micro connector is directly connected to USB_C_DET (through R17, which should be populated on Viola Plus). Note that you can download the schematics of the board from our website.

Without having tested it, I think it should be possible by adjusting dr_mode in the device tree. The mode is defined to be OTG by default in arch/arm/boot/dts/vf-colibri.dtsi, however it is best if you overwrite the property in your carrier board device tree (e.g. arch/arm/boot/dts/vf-colibri-eval-v3.dtsi). Since you don’t care about automatic switch, you can also remove the extcon property in the same node:

&usbdev0 {
    dr_mode = "host";

See also our article about Device Tree Customization.