thx,Alan. Now,i understand what i need to do.
At last mail,u told me don't need to change any code of file_storage.c but: 1.How about same descriptors(usb_device_descriptor, usb_config_descriptor............), and fs_bulk_out_desc,fs_bulk_in_desc? I keep it or change to my config? 2.there is not my chip in usb_ep_autoconfig function, i still need to use it? On Thu, 2006-03-23 at 10:24 -0500, Alan Stern wrote: > On Thu, 23 Mar 2006, Peter Chen wrote: > > > Thx Alan. > > > > Maybe you misunderstood my meaning. > > I did understand. > > > In my gadget module(dm320_gadget.ko which your file_storage.ko > > need to invoke usb_gadget_register_driver) > > Yes. > > > And In my dm320_gadget module,i need to know DMAADDR and DMACOUNT > > value,which will be assigned to corresponding registers. > > Yes. > > > But the bh->inreq->dma , bh->inreq->length,req->dma ,req->length > > are in ur module. > > Yes. > > > So i need some global variables to get it. > > No. > > > And using these variables in my dm320_gadget module. > > Which ur opinion of my thinking? > > If i can't use in that way,how can i get there value? > > file_storage.c calls usb_ep_queue(), which calls your dm320_gadget's > ep->ops->queue() routine, and it passes bh->inreq as the second argument. > So your module does have access to bh->inreq->dma and bh->inreq->length. > > > And can i declare usb_request to myself? > > No. It is already defined in include/linux/usb_gadget.h. You cannot > declare it again. > > Alan Stern > > > > ------------------------------------------------------- > This SF.Net email is sponsored by xPML, a groundbreaking scripting language > that extends applications into web and mobile media. Attend the live webcast > and join the prime developer group breaking into this new coding territory! > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 > _______________________________________________ > linux-usb-devel@lists.sourceforge.net > To unsubscribe, use the last form field at: > https://lists.sourceforge.net/lists/listinfo/linux-usb-devel > ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel