From owner-freebsd-usb@FreeBSD.ORG Mon Mar 10 07:43:06 2008 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5D6C6106566C for ; Mon, 10 Mar 2008 07:43:06 +0000 (UTC) (envelope-from vladimir.terziev@gbservices.biz) Received: from cat-btc.gbservices.biz (cat-btc.gbservices.biz [83.228.119.50]) by mx1.freebsd.org (Postfix) with ESMTP id 2AFAC8FC1C for ; Mon, 10 Mar 2008 07:43:05 +0000 (UTC) (envelope-from vladimir.terziev@gbservices.biz) Received: from cat-btc.gbservices.biz (localhost [127.0.0.1]) by localhost (Postfix) with ESMTP id B24FE1FA037; Mon, 10 Mar 2008 08:43:03 +0100 (CET) Received: from fs.gbs.gbdom.com (fs.gbs.gbdom.com [192.168.2.244]) by cat.gbs.gbdom.com (Postfix) with ESMTP id 939D21FA032; Mon, 10 Mar 2008 08:43:03 +0100 (CET) Received: from localhost (localhost.gbs.gbdom.com [127.0.0.1]) by localhost (Postfix) with ESMTP id 30DC728592; Mon, 10 Mar 2008 08:43:03 +0100 (CET) Received: from daemon.gbs.gbdom.com (daemon.gbs.gbdom.com [192.168.2.104]) by fs.gbs.gbdom.com (Postfix) with SMTP id B3B9D28590; Mon, 10 Mar 2008 08:43:02 +0100 (CET) Date: Mon, 10 Mar 2008 09:43:02 +0200 From: Vladimir Terziev To: Hans Petter Selasky Message-Id: <20080310094302.dce54954.vlady@gbservices.biz> In-Reply-To: <200803071855.47520.hselasky@c2i.net> References: <20080306183641.c941b83a.vlady@gbservices.biz> <200803061807.46113.hselasky@c2i.net> <20080307103546.799d3e0d.vlady@gbservices.biz> <200803071855.47520.hselasky@c2i.net> Organization: GB Services Ltd. X-Mailer: Sylpheed 2.4.7 (GTK+ 2.6.4; i386-unknown-freebsd5.4) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV GBS-F X-Virus-Scanned: ClamAV GBS-C Cc: freebsd-usb@freebsd.org Subject: Re: USB Smart card reader/writer problem X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Mar 2008 07:43:06 -0000 Hi, thanks, but i thought there is some userland-based solution ... If i remove the "clear stall" command from the kernel, how will this affect the other USB devices ? Is there a guarantee they will continue to function as normal ? Vladimir On Fri, 7 Mar 2008 18:55:46 +0100 Hans Petter Selasky wrote: > Hi, > > You could search in /sys/dev/usb for xxx_pipe_open() or something like that, > and remove the clear stall command from that function and the recompile your > kernel and modules. > > --HPS > > > On Friday 07 March 2008, Vladimir Terziev wrote: > > On Thu, 6 Mar 2008 18:07:44 +0100 > > > > Hans Petter Selasky wrote: > > > On Thursday 06 March 2008, Vladimir Terziev wrote: > > > > Hi, > > > > > > > > i have ACS ACR38T Smart card reader/write device (idVendor=0x072f, > > > > idProduct=0x90cc), which is an USB stick. I try to make it to work > > > > under FreeBSD (trys have been done on 5.4, 5.5 and 6.2). > > > > > > > > The device has 3 endpoints -- interrupt-in, configured as /dev/ugenX.1 > > > > and bulk-in/bulk-out, configured as /dev/ugenX.2. > > > > > > > > Neither the driver from openct-0.6.14 port nor the driver from > > > > ccid-1.3.5 port work for the device. > > > > > > > > The communication with the device gets stuck on BULK-OUT operations. > > > > write(2) calls to /dev/ugenX.2 hang forever despite the timeout set > > > > with USB_SET_TIMEOUT. > > > > > > > > The device has been tested to work under Windoze, so as general, it's > > > > not broken, but just irresponsive. > > > > > > > > Could someone give me some clues about the nature of the problem ? > > > > > > > > Thanks in advance! > > > > > > > > Vladimir > > > > > > Hi, > > > > > > Some USB devices have problems with Clear Stall. FreeBSD usually clears > > > the stall on the endpoints before starting to use them. Some devices > > > empty the fifo when receiving this clear stall, and does not requeue the > > > data. That is why your device most likely does not work. > > > > > > --HPS > > > > Is there something i could do in order to workaround such a behaviour ? > > > > Vladimir