

In Device Drivers ->, then go to SCSI device support ->, SCSI device support In Linux/arm 3.8.7 Kernel Configuration -> Device Drivers ->, -> USB support Support for Host-side USBĬonfigure to install usb device driver in Kernel. In Linux 3.8.7 source code folder, make menuconfig. When the request is completed and the request has a callback function, the UDC driver dequeues the requests and calls its complete function. The UDC driver maintains a request queue for each of the 5 endpoints, a gadget driver puts request to the queues by calling queue(). Source code of the UDC drier for S3C2440 is linux-3.8.7/drivers/usb/gadget/s3c2410_udc.c.

The UDC of S3C2440A is integrated on the S3C2440 chip and hence is regarded as a platform device. They are defined in the file linux-3.8.7/include/linux/usb/gadget.h. A UDC driver must impelment a set of function to manipulate endpoints and gadget, as well as to register and unregister a gadget driver. Gadget drivers sit on top of the UDC dirver, and use the service it provides. The UDC driver reads/writes the registers of the UDC and reads/writes the FIFOs of the endpoints. Source code of USB host controller driver is linux-3.8.7/drivers/usb/host/ohci-s3c2410.c. Both USB host controller and UDC (USB device controller) are regarded as platform device and their drivers are registered as platform driver. S3C2440A board has two USB ports: the port with a type A connector works as a USB host the other with a Type B connector works as a USB peripheral.
