Using Cypress EZ-Host on ML403/5
Hi First of all, I'm a beginner, so my questions may be funny .... sorry for that.
Any how your ideas are very valuable for me. I'm going to have the usb work on ML403.
I have two questions about the usb on ml403 board.
1) In EDK9.1i, we can use the wizard to build a new design with usb. But I found it's different from the reference design that xilinx provided for edk8.1i. So which design should I choose? In datasheet of opb_epc, I found that we should add the irq manually. So I added the irq and reset according to xapp925. After that, I patched my linux kernel using the patch by Peter Korsgaard. But when I pluged in the usb camera, it can't probe it. What should I do additionally?
2) I can't find where to initialize the base registers and irq in the usb driver for cy7c67300 provided by Peter Korsgaard. In the function usb_c67x00_drv_probe, I found it called platform_get_resource(pdev, IORESOURCE_MEM, 0). So I think I should add some register codes for usb like uartlite or temac in virtex.c. I added the following codes:
#ifdef XPAR_USB_0_BASEADDR
[VIRTEX_USB_0] = {
.name = "xilix_usb",
.id = 0,
.num_resource = 2,
.resource = (struct resource[]) {
{
.start = XPAR_USB_0_BASEADDR,
.end = XPAR_USB_0_HIGHADDR,
.flags = IORESOURCE_MEM,
},
{
.start = XPAR_INTC_0_USB_0_VEC_ID,
.end = XPAR_INTC_0_USB_0_VEC_ID,
.flags = IORESOURCE_IRQ,
}
}
},#endif
and define the following macro in xparameters_ml403.h.
#define XPAR_INTC_0_USB_0_VEC_ID XPAR_OPB_INTC_0_SYSTEM_USB_HPI_INT_INTR
#define XPAR_USB_0_BASEADDR XPAR_CYPRESS_USB_PRH0_BASEADDR
#define XPAR_USB_0_HIGHADDR XPAR_CYPRESS_USB_PRH0_HIGHADDR
After that, it still can't prob the usb device. So could you give me some suggestion about making usb work on ml403?
Thank you very much!
Peter Luan