summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorChandler Zhang <chazhang@nvidia.com>2012-07-02 14:41:01 +0800
committerVarun Colbert <vcolbert@nvidia.com>2012-07-09 15:38:54 -0700
commit9bcf005a7494bb9890fd2bde02889e2ef168c289 (patch)
tree4a542c98602290c96387aca4943bc24fdd24b7bf /include
parent4a0100a4232cf466ad5e34d26b77be68608bcba3 (diff)
power: smb349: remove otg callback
The callback in otg driver is not a standard way of controlling USB VBUS. Remove the callback and use regulator to control. Bug 997805 Change-Id: I6d7fd01f9346e037515901ac6fe6d349a140d13e Signed-off-by: Chander Zhang <chazhang@nvidia.com> Reviewed-on: http://git-master/r/112896 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Syed Rafiuddin <srafiuddin@nvidia.com> Reviewed-by: Sachin Nikam <snikam@nvidia.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/smb349-charger.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/include/linux/smb349-charger.h b/include/linux/smb349-charger.h
index 089f3976dbbe..228069e347a7 100644
--- a/include/linux/smb349-charger.h
+++ b/include/linux/smb349-charger.h
@@ -3,7 +3,7 @@
*
* Battery charger driver interface for Summit SMB349
*
- * Copyright (C) 2012 NVIDIA Corporation
+ * Copyright (c) 2012, NVIDIA CORPORATION. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -35,6 +35,9 @@ struct smb349_charger_platform_data {
int charging_term_current_mA;
int num_consumer_supplies;
struct regulator_consumer_supply *consumer_supplies;
+ int otg_regulator_id;
+ int num_otg_consumer_supplies;
+ struct regulator_consumer_supply *otg_consumer_supplies;
};
enum charging_states {
@@ -61,20 +64,21 @@ struct smb349_charger {
enum charger_type chrg_type;
charging_callback_t charger_cb;
+ int is_otg_enabled;
struct regulator_dev *rdev;
struct regulator_desc reg_desc;
struct regulator_init_data reg_init_data;
+ struct regulator_dev *otg_rdev;
+ struct regulator_desc otg_reg_desc;
+ struct regulator_init_data otg_reg_init_data;
};
int smb349_battery_online(void);
-typedef void (*callback_t)(enum usb_otg_state to,
- enum usb_otg_state from, void *args);
/*
* Register callback function for the client.
* Used by fuel-gauge driver to get battery charging properties.
*/
extern int register_callback(charging_callback_t cb, void *args);
-extern int register_otg_callback(callback_t cb, void *args);
extern int update_charger_status(void);
#endif /*__LINUX_SMB349_CHARGER_H */