We are working on a new design, mainly based on the EVM for the AM/DM3730, our processor is the AM3715. On the EVM the board has 2 USB devices, one for the OTG on HSUSB0 and one as HOST on HSUSB2. We have built a board with two of the host devices used on the EVM (SMSC USB3320) connected to HSUSB0 and 2. The good news is that HSUSB2 is working, I get device detected messages on the console when I plug a USB stick in. I am unclear how one would add a second instance of the ECHI driver for the HSUSB0 port.
I have removed all OTG references with the menuconfig utility and have added settings for ehci_pdata.port_mode[0] in the board initialisation file.
And I've added a switch section for port_mode[0] into the setup_echi_io_mux() to setup the pin mux. But there is no console response when I plug a USB into the HSUSB0 port. (I can see the code run through the setup_echi_io_mux() for port_mode[0]) and the
Once I'm sure the chip has been set-up I can then worry about if the chip is connected up OK - it should be as it's a copy of the HSUSB2 device. So any clues would be aprreciated, - I realise it may be more of a Linux BSP issue.
board initialisation file
/arch/arm/mach-ompa2/board-ompa3evm.c
static struct ehci_hcd_omap_platform_data ehci_pdata __initconst = {
.port_mode[0] = EHCI_HCD_OMAP_MODE_PHY,
.port_mode[1] = EHCI_HCD_OMAP_MODE_UNKNOWN,
.port_mode[2] = EHCI_HCD_OMAP_MODE_PHY,
.phy_reset = true,
/* PHY reset GPIO will be runtime programmed based on EVM version */
.reset_gpio_port[0] = -EINVAL,
.reset_gpio_port[1] = -EINVAL,
.reset_gpio_port[2] = -EINVAL,
.aux[0] = 0,
.aux[1] = 0,
.aux[2] = 0,
};
arch/arm/mach-omap2/usb-echi.c
static void setup_ehci_io_mux(enum ehci_hcd_omap_mode *port_mode)
{
switch (port_mode[0]) {
case EHCI_HCD_OMAP_MODE_PHY:
omap_mux_init_signal("hsusb0_stp", OMAP_PIN_OUTPUT);
omap_mux_init_signal("hsusb0_clk", OMAP_PIN_OUTPUT);
omap_mux_init_signal("hsusb0_dir", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_nxt", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data0", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data1", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data2", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data3", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data4", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data5", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data6", OMAP_PIN_INPUT_PULLDOWN);
omap_mux_init_signal("hsusb0_data7", OMAP_PIN_INPUT_PULLDOWN);
printk(KERN_WARNING "USB-ECHI.C : Port0 pin mux setup in PHY mode\n");
break;
case EHCI_HCD_OMAP_MODE_TLL:
printk(KERN_WARNING "USB-ECHI.C : Port0 not setup for TLL mode\n");
break;
case EHCI_HCD_OMAP_MODE_UNKNOWN:
/* FALLTHROUGH */
default:
break;
}
Some relevent bits of the boot display on the console:
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
i2c_omap i2c_omap.1: bus 1 rev4.0 at 2600 kHz
regulator: VDAC: 1800 mV normal standby
i2c_omap i2c_omap.2: bus 2 rev4.0 at 400 kHz
i2c_omap i2c_omap.3: bus 3 rev4.0 at 400 kHz
Switching to clocksource 32k_counter
musb_hdrc: version 6.0, musb-dma, host, debug=0
usbcore: registered new interface driver cdc_ether
usbcore: registered new interface driver dm9601
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
ehci-omap ehci-omap.0: OMAP-EHCI Host Controller
ehci-omap ehci-omap.0: new USB bus registered, assigned bus number 1
ehci-omap ehci-omap.0: irq 77, io mem 0x48064800
ehci-omap ehci-omap.0: USB 2.0 started, EHCI 1.00
usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
usb usb1: Product: OMAP-EHCI Host Controller
usb usb1: Manufacturer: Linux 2.6.32 ehci_hcd
usb usb1: SerialNumber: ehci-omap.0
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 3 ports detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver usbtest
Any clues appreciated.
Ben