From owner-freebsd-usb@FreeBSD.ORG Fri Aug 17 20:08:11 2007 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 7146316A469 for ; Fri, 17 Aug 2007 20:08:11 +0000 (UTC) (envelope-from cb@severious.net) Received: from ion.gank.org (ion.gank.org [69.55.238.164]) by mx1.freebsd.org (Postfix) with ESMTP id 52E0B13C4B0 for ; Fri, 17 Aug 2007 20:08:11 +0000 (UTC) (envelope-from cb@severious.net) Received: by ion.gank.org (Postfix, from userid 1001) id C24ED115B4; Fri, 17 Aug 2007 14:51:50 -0500 (CDT) Date: Fri, 17 Aug 2007 14:51:50 -0500 From: Craig Boston To: Kirk Davis Message-ID: <20070817195150.GA62666@nowhere> References: <20070809200142.GB80751@nowhere> <20070809212655.GD80751@nowhere> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.2i Cc: freebsd-usb@freebsd.org Subject: Re: (Please test) New blackberry (uberry) driver. 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: Fri, 17 Aug 2007 20:08:11 -0000 On Fri, Aug 17, 2007 at 10:57:49AM -0600, Kirk Davis wrote: > I have tested it with an 8830, 8100, and an 8703e but nit with the > 8700 so far. I'll have to look around work and I'm sure I can dig up > an 8700 to test with. Mine is an 8700c, but I'm pretty sure the 'c' just indicates vendor branding. > Are you sure that it is charging at 500mA rate without the do_charge > routing in there? You can check this with the 'usbdevs -v' command. > It should show 500mA power rate. Aha, it seems that the command that was sent to the blackberry by your version of the driver stays in effect for a while even after the cable is disconnected. When I first reverted back to the OpenBSD driver, it used 100mA with config 0 and 500mA with config 1. Now that I've power cycled the blackberry, it uses 100mA on both configs. > Then the device disconnects and reconnects to the buss with the higher > charge rate enabled. That might be why you are seeing it detach and > reattach. Yes, I suspect that the 8700 unconditionally detaches after receiving the command to enable 500mA charging, so I was getting into a loop when it reattached and the command was sent again. I think what needs to be done is detect the power setting on the bus and avoid sending the command again if it's already 500mA. Craig