healthd: move Android communication code to separate source
* add ops for different "modes" of healthd operation: android vs. recovery
* recovery mode selected by runstring options -r
* binder/Android communication moved to android mode
* recovery mode ops avoiding binder service registration
* "no service manager" flag removed; now handled by android vs. other modes
Change-Id: I3d8c89bf96a18a6a00cc85306f9a07d3f408f2a0
diff --git a/healthd/BatteryMonitor.h b/healthd/BatteryMonitor.h
index 34b423d..3dd2ef0 100644
--- a/healthd/BatteryMonitor.h
+++ b/healthd/BatteryMonitor.h
@@ -23,12 +23,9 @@
#include <utils/Vector.h>
#include "healthd.h"
-#include "BatteryPropertiesRegistrar.h"
namespace android {
-class BatteryPropertiesRegistrar;
-
class BatteryMonitor {
public:
@@ -40,7 +37,7 @@
ANDROID_POWER_SUPPLY_TYPE_BATTERY
};
- void init(struct healthd_config *hc, bool nosvcmgr);
+ void init(struct healthd_config *hc);
bool update(void);
status_t getProperty(int id, struct BatteryProperty *val);
@@ -48,8 +45,6 @@
struct healthd_config *mHealthdConfig;
Vector<String8> mChargerNames;
- sp<BatteryPropertiesRegistrar> mBatteryPropertiesRegistrar;
-
int getBatteryStatus(const char* status);
int getBatteryHealth(const char* status);
int readFromFile(const String8& path, char* buf, size_t size);