From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavan Kondeti Subject: finding out the attached device current requirement Date: Thu, 03 Mar 2011 14:22:34 +0530 Message-ID: <4D6F56D2.4060803@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: Received: from wolverine02.qualcomm.com ([199.106.114.251]:7324 "EHLO wolverine02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751239Ab1CCIwj (ORCPT ); Thu, 3 Mar 2011 03:52:39 -0500 Sender: linux-arm-msm-owner@vger.kernel.org List-Id: linux-arm-msm@vger.kernel.org To: "linux-usb@vger.kernel.org" Cc: "linux-arm-msm@vger.kernel.org" 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 we can not assume that device will be configured by the time DEVICE_ADD notification is sent. And also there is a possibility that configuration change request from use. Is it a good idea to add DEVICE_CONFIG_CHANGE notification to solve this problem? Thanks, Pavan -- Sent by a consultant of the Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.