Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9e02e3e8 authored by Chris Manton's avatar Chris Manton Committed by Automerger Merge Worker
Browse files

Add stack/include/btm_api_types::power_mode_status_text am: c36d4607 am:...

Add stack/include/btm_api_types::power_mode_status_text am: c36d4607 am: c72e6ae6 am: 62d979d8

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1527472

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I85cf5562b0d8aa60bfe1fcd35087291cba2d56bd
parents 866b3f08 62d979d8
Loading
Loading
Loading
Loading
+21 −0
Original line number Diff line number Diff line
@@ -973,6 +973,27 @@ enum : uint8_t {
};
typedef uint8_t tBTM_PM_STATUS;

inline std::string power_mode_status_text(tBTM_PM_STATUS status) {
  switch (status) {
    case BTM_PM_STS_ACTIVE:
      return std::string("active");
    case BTM_PM_STS_HOLD:
      return std::string("hold");
    case BTM_PM_STS_SNIFF:
      return std::string("sniff");
    case BTM_PM_STS_PARK:
      return std::string("park");
    case BTM_PM_STS_SSR:
      return std::string("sniff_subrating");
    case BTM_PM_STS_PENDING:
      return std::string("pending");
    case BTM_PM_STS_ERROR:
      return std::string("error");
    default:
      return std::string("UNKNOWN");
  }
}

/* BTM Power manager modes */
enum : uint8_t {
  BTM_PM_MD_ACTIVE = HCI_MODE_ACTIVE,  // 0x00