Hack changes for implementing battery optimization