From: Felipe Balbi Subject: Re: finding out the attached device current requirement Date: Thu, 3 Mar 2011 11:45:12 +0200 Message-ID: <20110303094512.GI2644@legolas.emea.dhcp.ti.com> References: <4D6F56D2.4060803@codeaurora.org> Reply-To: balbi@ti.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from na3sys009aog106.obsmtp.com ([74.125.149.77]:45106 "EHLO na3sys009aog106.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750909Ab1CCJpR (ORCPT ); Thu, 3 Mar 2011 04:45:17 -0500 Content-Disposition: inline In-Reply-To: <4D6F56D2.4060803@codeaurora.org> Sender: linux-arm-msm-owner@vger.kernel.org List-Id: linux-arm-msm@vger.kernel.org To: Pavan Kondeti Cc: "linux-usb@vger.kernel.org" , "linux-arm-msm@vger.kernel.org" On Thu, Mar 03, 2011 at 02:22:34PM +0530, Pavan Kondeti wrote: > Hi > > I am adding ACA (Accessory Charger Adapter) detection support for MSM > OTG driver. Battery charging spec introduced ACA to facilitate charging > when acting as a host. The host does not have to supply power on VBUS > when ACA is connected. Host device can also draw some amount of current. > The amount of current is determined by subtracting the attached > peripheral current requirement from the charger rating current. I am > looking for a way to find out the attached peripheral's current > requirement. We already DEVICE_ADD and DEVICE_REMOVE notifications. But bMaxPower from the device descriptor ?? -- balbi