+ bt_object_release_func release,
+ struct bt_graph *graph);
+
+static inline
+void bt_notification_reset(struct bt_notification *notification)
+{
+ BT_ASSERT(notification);
+
+#ifdef BT_DEV_MODE
+ notification->frozen = BT_FALSE;
+ notification->seq_num = UINT64_C(-1);
+#endif
+}
+
+static inline
+struct bt_notification *bt_notification_create_from_pool(
+ struct bt_object_pool *pool, struct bt_graph *graph)
+{
+ struct bt_notification *notif = bt_object_pool_create_object(pool);
+
+ if (unlikely(!notif)) {
+#ifdef BT_LIB_LOGE
+ BT_LIB_LOGE("Cannot allocate one notification from notification pool: "
+ "%![pool-]+o, %![graph-]+g", pool, graph);
+#endif
+ goto error;
+ }
+
+ if (likely(!notif->graph)) {
+ notif->graph = graph;
+ }
+
+ goto end;
+
+error:
+ BT_ASSERT(!notif);