Dave,

On Fri, Apr 16, 2004 at 10:47:09AM -0700, David Brownell wrote:
> >I'm working on support for a chip which handles EP0 trafic almost
> >completely in hardware (Hynix H7202). As you don't get things like Set
> >Configuration Requests the usual state machines do not work, so I fake
> >the calls from the reset interrupt. 
> 
> How do the Hynix docs say drivers should handle SET_CONFIGURATION?
> They clearly have some solution. I can think of a trivial one that
> works for single-config devices. Do they handle multi-config devices?
> How do they detect/handle SET_CONFIGURATION calls with illegal values?

Unfortunately, the Hynix docs [1] are not very, hmmm, let's say detailed
regarding the USB controller, it's not much more than a description of
the registers.

> >That means that I have to call dev->driver->setup() from within the
> >controller driver's irq routine and I have to fake the values for the
> >request, which works pretty find. The problem is that the controller
> >driver has to know which configuration to chose, and that's
> >unfortunately gadget driver dependend. 
> >
> >So far, I have no good idea how to abstract this.
> 
> You didn't give much information. One possibility would be to
> say that it's always bConfigurationValue == 1, and require the
> gadget drivers to know that "if (gadget_is_h7202())" then they
> can only use that single configuration.

The problem is that, for example with g_zero and g_ether it might be
configuration 1, with g_serial it is 2. Ok, the decision could be made
in the gadget driver, but that's surely against the idea of having
almost all controller dependend stuff in the controller driver. 

Robert
 
[1] See bottom of http://www.hynix.com/eng/products/system_ic/sp/mp02.jsp 
    Section "Fast AMBA Peripherals".
-- 
 Dipl.-Ing. Robert Schwebel | http://www.pengutronix.de
 Pengutronix - Linux Solutions for Science and Industry
   Handelsregister:  Amtsgericht Hildesheim, HRA 2686
     Hornemannstra�e 12,  31137 Hildesheim, Germany
    Phone: +49-5121-28619-0 |  Fax: +49-5121-28619-4


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to