RE: [PATCH 2/3] phy: renesas: rcar-gen3-usb2: Add support for R7S9210
From: Chris Brandt <Chris.Brandt@renesas.com>
Date: 2018-11-14 23:06:00
Also in:
linux-clk, linux-renesas-soc
Hi Shimoda-san,
From: Yoshihiro Shimoda Sent: Wednesday, November 14, 2018 7:24 AMquoted
quoted
quoted
config PHY_RCAR_GEN3_USB2 tristate "Renesas R-Car generation 3 USB 2.0 PHY driver" depends on ARCH_RENESAS - depends on EXTCON + depends on EXTCON || ARCH_R7S9210Does this mean that you don't want to use EXTCON if ARCH_R7S9210=y?EXTCON is not required for RZ/A2. So, I want to be able to leave EXTCON un-selected (save flash space).I got it. I added the depend on EXTCON, but R-Car Gen3 environment can build EXTCON=n. However, I realized that build error happens if EXTCON=m. So, I think we have to revise this line as following at first: "depends on EXTCON || !EXTCON # if EXTCON=m, this cannot be built-in" like drivers/phy/qualcomm/Kconfig.
OK. I will change it. (should this be a separate patch?)
quoted
Without this code, RZ/A2 will not work.I'd like to clarify this. Does this mean RZ/A2 will not work as host mode?
Correct. If I remove 'else' code, RZ/A2 host mode does not work. I just tested again now. Host works: else /* No otg, so default to host mode */ writel(0x00000000, usb2_base + USB2_COMMCTRL); Host does NOT work: //else // /* No otg, so default to host mode */ // writel(0x00000000, usb2_base + USB2_COMMCTRL);
(In other words, if we use the port as peripheral with the reset value 0x80000000, does it work?)
We have not been able to get USB peripheral working on RZ/A2 yet. For peripheral, RZ/A2 has HS-USB. After plugging into the PC, HS-USB goes to Suspended state (DVSQ = "0110"). It should go to Configured state (DVSQ = "0011") According to the RZ/A2 Hardware Manual, COMMCTRL should be 0x80000000 when using HS-USB. There are 2 channels of USB on RZ/A2 (host x 2, HS_USB x 2) Chris