From owner-freebsd-usb@FreeBSD.ORG Thu Apr 28 13:44:23 2005 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A74B016A4CE for ; Thu, 28 Apr 2005 13:44:23 +0000 (GMT) Received: from swip.net (mailfe08.swip.net [212.247.154.225]) by mx1.FreeBSD.org (Postfix) with ESMTP id D2BC843D5D for ; Thu, 28 Apr 2005 13:44:22 +0000 (GMT) (envelope-from hselasky@c2i.net) X-T2-Posting-ID: Y1QAsIk9O44SO+J/q9KNyQ== Received: from mp-216-47-180.daxnet.no ([193.216.47.180] verified) by mailfe08.swip.net (CommuniGate Pro SMTP 4.3c5) with ESMTP id 155365206; Thu, 28 Apr 2005 15:44:20 +0200 From: Hans Petter Selasky To: freebsd-usb@freebsd.org Date: Thu, 28 Apr 2005 15:44:35 +0200 User-Agent: KMail/1.7 References: <20050428062416.93478.qmail@web53609.mail.yahoo.com> In-Reply-To: <20050428062416.93478.qmail@web53609.mail.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200504281544.36394.hselasky@c2i.net> Subject: Re: Is the freebsd usb generic device driver complete? X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: hselasky@c2i.net List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Apr 2005 13:44:23 -0000 On Thursday 28 April 2005 08:24, paradox wrote: > I am using a low speed usb key in freebsd > 5.3Release,It has 2 interrupt pipe besides the control > pipe,the IN pipe is endpoint 1,its interval is 20, OUT > pipe is endpoint 2, interval is 10. I wrote a driver > for it in linux,and everything is ok.when I plug the > key in a system with freebsd 5.3release, it find the > key,make 3 nodes ugen0,ugen0.1 and ugen0.2 for it, I > can get those descriptors from ugen0,but I can't wrote > anything in the OUT pipe ugen0.2. from usb analyser I > found the system send the write packet,just like in > linux,but the return is NAK. > > I read the code in ugen.c,usbdi.c,uhci.c,usb.c and > usbdi_util.c,and don't know why it set the ival to > USB_DEFAULT_IVAL(0),I contact with Lennart Augustsson > whose name is in the head of those usb codes, he said > he has never run those code in freebsd and he didn't > write the intr write code! > > I still can't sure it is because of the non-standard > hardware or software bugs.now I try to write a driver > for the usb key in freebsd, if there has any bugs in > the ugen.c, I hope i can made a patch for it.can > anyone tell me how the intr write designs in the > ugen.c, and why it only use the USB_DEFAULT_IVAL? The OHCI/UHCI/EHCI drivers interpret the polling interval similar to this: xfer->interval = setup->interval; if(xfer->interval == 0) { // // get interval from the endpoint descriptor // xfer->interval = xfer->pipe->edesc->bInterval; } if(xfer->interval == 0) { xfer->interval = 1 /* ms */; } What USB-controller are you using? Is the device connected through an external USB HUB? Are you sure that the right configuration value has been set? Yours HPS