Diff between 73aa8b84117b7de6eeb3dc01d80db650d38bf0bc and 39437cd5d1f537db1a4209be1503a1b7dfe8ca4d

Changed Files

File Additions Deletions Status
android/hal-health.c +11 -0 modified

Full Patch

diff --git a/android/hal-health.c b/android/hal-health.c
index ae327b8..e7326d7 100644
--- a/android/hal-health.c
+++ b/android/hal-health.c
@@ -33,11 +33,22 @@ static bool interface_ready(void)
 	return cbacks != NULL;
 }
 
+static void handle_app_registration_state(void *buf, uint16_t len)
+{
+	struct hal_ev_health_app_reg_state *ev = buf;
+
+	if (cbacks->app_reg_state_cb)
+		cbacks->app_reg_state_cb(ev->id, ev->state);
+}
+
 /*
  * handlers will be called from notification thread context,
  * index in table equals to 'opcode - HAL_MINIMUM_EVENT'
  */
 static const struct hal_ipc_handler ev_handlers[] = {
+	/* HAL_EV_HEALTH_APP_REG_STATE */
+	{ handle_app_registration_state, false,
+				sizeof(struct hal_ev_health_app_reg_state) },
 };
 
 static bt_status_t register_application(bthl_reg_param_t *reg, int *app_id)