[USB2.0 Host] [Linaro] Support for DB820c based design


We are using the DB820c Linaro Rel #38 from http://builds.96boards.org/snapshots/dragonboard820c/linaro/debian/38/ as a baseline for our custom board based on DB820c.

We found that DB820c USB ports have been configured as:

USB3.0 as HOST

While in our design, we have implemented the USB ports as:

USB3.0 as OTG
USB2.0 as HOST

We checked the msm8996.dtsi file at arch/arm64/boot/dts/qcom, and found that there is no node for the USB2.0 i.e.


Can you please confirm if USB2.0 HOST support is added in this release ?

If the USB2.0 HOST support is present in the kernel, then it would be really great if you can help us understand on how to add this support in dtsi file.

We have already a working code (for USB2.0) on Android OS that we have taken from CAF LA.HB.1.3.2-16800-8x96.0.

Here we have done changes to the USB nodes, and they are working on the Android OS. But the above mentiond USB2.0 nodes were present in the android dtsi file.

Looking forward for your help.



Can you please let us point to any document or reference to confirm if we can do such configuration for the release # 38 ?

Awaiting your reply.


Historically some of the QC DTS files in arch/arm64 #include files from arch/arm, so I always prefer to decompile the .dtb files when checking out things like this. However, if you’ve tried that and still can’t see the USB 2.0 in the DT then I suspect here is no support for now.

As it says pretty clearly on the box: “DragonBoard 820c is not yet commercially available and is in beta testing only. Please expect limited documentation and support until further notice.”

Hi @danielt,

Thank you for the reply.

I decompiled the .dtb file and confirmed that there is no usb2.0 node. However, the “usb2-phy” is configured as host under the dwc3@6a00000 child node.

I understand that there is limited documentation and support, but if there are any minor changes in dtsi to configure the USB 2.0 port, then it would be really great.

I guess we need to wait for the Release having the Linux Kernel 4.11 then.

Thanks for your time.


The phy drivers for USB support on db820c have just landed in linux-phy/next kernel maintained by Kishon.
drivers/phy/phy-qcom-qmp.c → USB 3.0
drivers/phy/phy-qcom-qusb2.c → USB 2.0
These drivers provide the USB 2.0 and USB 3.0 phy functionality.

I am yet to post the device tree patches though. But, I have been maintaining a branch [1], that includes this support. I have rebased it on torvald’s master branch. This also include other infra that we need to enable USB support on db820c, such as Glink and rpm.
Also, note that this branch contains USB drd patches that were posted by Roger Quadros. We will need this to enable OTG support for USB controller.
Please take a look at this branch.

[1] https://github.com/vivekgautam1/linux/tree/linux-v4.11-rc5-qmp-phy-db820c

Hi @vgautam,

Really appreciate for your response and providing your branch.

Is there a intermediate release planned on Linaro that I can use for db820c ?


I am not certain about the timelines for the release

Surely. Thank you @vgautam.

Hi Sunny,

Are you able to use the required configuration?

USB3.0 as OTG
USB2.0 as HOST

I am looking to test the USB3 controller in OTG mode.
While I am able to test USB3 controller in host mode successfully on db820c, I am facing issues with the Gadget mode.

Let me know if you have some information.

Thanks @bhayanisunny

Hi @vgautam,

Since our hardware design is modified for USB 2.0 and 3.0 ports, we are pending on the DB820c release to verify the USB 3.0 OTG in mode in our design.

Are there any dates wherein we can expect the changes to be upstreamed ?


Hi @vgautam and @anon91830841,

I downloaded the Release #59 from Linaro Release 59, and saw that the usb3 node is added in the msm8996.dtsi files.

As I have mentioned in this thread that we have a custom board where we have used the USB differently than that used in DB820c.

In the Android releases, for the USB3 node in the apq8096-db820.dtsi file, there is the below code for the reset pin:

	vbus_dwc3-supply = <&usb_otg_switch>;
	qcom,ext-hub-reset-gpio =  <&tlmm 103 0>;

and we have used the pin 123 instead of 103. For this pin changes, we need to make changes in the msm8996-pinctrl.dtsi for:

usb_hub_reset_active: usb_hub_reset_active {
 			usb_hub_reset_active {
-				pins = "gpio103";
+				pins = "gpio123";


		usb_hub_reset_suspend: usb_hub_reset_suspend {
 			usb_hub_reset_suspend {
-				pins = "gpio103";
+				pins = "gpio123";

But similar thing, I am not able to find in the linaro release.

Also, I want to remove the DWC OTG functionality from USB3 node to just only the USB2 node due to the design.

Can you please give any pointers as to how to modify the USB3 node at msm8996.dtsi:

usb3: usb@6a00000

Also, I am not sure but like the above node, I am not able to find a node for USB2 in the msm8996.dtsi. In the Android Source code the node is defined in msm8996.dtsi as:

usb2s: hsusb@7600000

It would be really great if you can give some pointers and I hope I am able to convey my message to you. Kindly accept my sincere apologies if I am vague.


Hi @vgautam,

I went through your github USB branch, and in the https://github.com/vivekgautam1/linux/blob/linux-v4.11-rc5-qmp-phy-db820c/drivers/phy/phy-qcom-qusb2.c file, there is a qcom-qusb2-phy compatible node whose entry is missing in the device tree at msm8996.dtsi.

Same is the case for the https://github.com/vivekgautam1/linux/blob/linux-v4.11-rc5-qmp-phy-db820c/drivers/phy/phy-qcom-usb-hs.c file, there is a qcom,usb-hs-phy compatible node whose entry is missing in the device tree at msm8996.dtsi.

Can you please update as to when you are going to upstream the changes ?

Awaiting your reply.


Hi @bhayanisunny,

phy-qcom-qusb2.c is the phy driver for USB2 functionality on msm8996.
phy-qcom-usb-hs.c is not of interest for msm8996.

Regarding the usb device tree support in upstream kernel, we are depending on some of the regulator dt changes for msm8996 to be posted to lkml. We can post the patches after that.

Meantime, you may want to take a look at the branch that has support for both USB2 and USB3 controller.

Above branch is based on the linaro integration branch maintained for dragonboards:

Hi @vgautam,

Thanks for your reply. I am looking at your source.

I have a query: In the Android source, for the usb3 node i.e. usb3@ssusb@6a00000, the compatible string is .compatible = “qcom,dwc-usb3-msm” whose driver is dwc3-msm.c at drivers/usb/dwc3.

Is there a similar driver in works for Linaro ?

The query I am asking is because, we have changed the pin for “qcom,ext-hub-reset-gpio” (present in the dwc3-msm.c), which is resetting the external hub. And that pin is not there in your github code.

Also, in the apq8096-db820c.dtsi, there seems to be no driver for the .compatible = “linux,extcon-usb-gpio” for the usb2_id and usb3_id pins.

Awaiting your reply.


Do you have any update? I also wait for dwc3-msm driver in linaro kernel (4.11)

hey @bhayanisunny,

Usb 2.0 host mode is working in 4.14 release branch now. check it.