From owner-freebsd-hackers@FreeBSD.ORG Tue Jan 6 22:38:43 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B350A16A4D0 for ; Tue, 6 Jan 2004 22:38:43 -0800 (PST) Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3CD8343D2D for ; Tue, 6 Jan 2004 22:38:40 -0800 (PST) (envelope-from ticso@cicely12.cicely.de) Received: from cicely5.cicely.de (cicely5.cicely.de [IPv6:3ffe:400:8d0:301:200:92ff:fe9b:20e7]) (authenticated bits=0) i076cYN1096600 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Wed, 7 Jan 2004 07:38:37 +0100 (CET) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (cicely12.cicely.de [IPv6:3ffe:400:8d0:301::12]) by cicely5.cicely.de (8.12.10/8.12.10) with ESMTP id i076cR4H002063 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 7 Jan 2004 07:38:27 +0100 (CET) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (localhost [127.0.0.1]) by cicely12.cicely.de (8.12.10/8.12.10) with ESMTP id i076cQBE046385; Wed, 7 Jan 2004 07:38:26 +0100 (CET) (envelope-from ticso@cicely12.cicely.de) Received: (from ticso@localhost) by cicely12.cicely.de (8.12.10/8.12.10/Submit) id i076cQDu046384; Wed, 7 Jan 2004 07:38:26 +0100 (CET) (envelope-from ticso) Date: Wed, 7 Jan 2004 07:38:25 +0100 From: Bernd Walter To: "Daniel O'Connor" Message-ID: <20040107063824.GF45569@cicely12.cicely.de> References: <3FFA04A8.30601@evilrealms.net> <200401071605.15740.doconnor@gsoft.com.au> <20040107060538.GE45569@cicely12.cicely.de> <200401071644.47090.doconnor@gsoft.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200401071644.47090.doconnor@gsoft.com.au> X-Operating-System: FreeBSD cicely12.cicely.de 5.2-CURRENT alpha User-Agent: Mutt/1.5.4i X-Spam-Status: No, hits=-4.9 required=3.0 tests=BAYES_00 autolearn=ham version=2.61 X-Spam-Report: * -4.9 BAYES_00 BODY: Bayesian spam probability is 0 to 1% * [score: 0.0000] X-Spam-Checker-Version: SpamAssassin 2.61 (1.212.2.1-2003-12-09-exp) on cicely5.cicely.de cc: Bernd Walter cc: freebsd-hackers@freebsd.org cc: ticso@cicely.de cc: Jay Cornwall Subject: Re: USB stack / configuration 0 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: ticso@cicely.de List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jan 2004 06:38:43 -0000 On Wed, Jan 07, 2004 at 04:44:46PM +1030, Daniel O'Connor wrote: > On Wednesday 07 January 2004 16:35, Bernd Walter wrote: > > Bad device - it would have been so easy add an single transitor to do > > this automaticaly. > > Nevertheless USB_UNCONFIG_NO can't help you here. > > What you need to do is toggling the hub port if the device is to > > stupid to detach/reattach on his own. > > I don't think it IS a dumb device, there is a USB spec called DFU which covers > it and the hosts job is to do the reenumeration. Sparing a transistor to offload the work to the host were its also way more complex to do is dump. If this is part of the Spec, then the spec is dump too. usbd_reset_port should do from the USB point of view, but this doesn't trigger Free BSD to do a reconfiguration of the device, which is required after reset. Maybe the following will do instead: usbd_clear_port_feature(dev, port, UHF_PORT_ENABLE) delay(USB_PORT_POWERUP_DELAY); usbd_set_port_feature(dev, port, UHF_PORT_ENABLE) dev and port is that from the hub. -- B.Walter BWCT http://www.bwct.de ticso@bwct.de info@bwct.de