battery_logger.h 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. /*
  2. * battery_logger.h
  3. * Samsung Mobile Charger Header
  4. *
  5. * Copyright (C) 2021 Samsung Electronics, Inc.
  6. *
  7. *
  8. * This software is licensed under the terms of the GNU General Public
  9. * License version 2, as published by the Free Software Foundation, and
  10. * may be copied, distributed, and modified under those terms.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. */
  18. #ifndef __BATTERY_LOGGER_H
  19. #define __BATTERY_LOGGER_H __FILE__
  20. #if defined(CONFIG_BATTERY_LOGGING)
  21. extern void store_battery_log(const char *fmt, ...);
  22. extern int register_batterylog_proc(void);
  23. extern void unregister_batterylog_proc(void);
  24. #else
  25. static inline void store_battery_log(const char *fmt, ...) {}
  26. static inline int register_batterylog_proc(void)
  27. { return 0; }
  28. static inline void unregister_batterylog_proc(void) {}
  29. #endif
  30. #endif /* __BATTERY_LOGGER_H */