* by the caller.
*/
-struct obj;
-
-struct objd_ops {
- long (*cmd)(int objd, unsigned int cmd, unsigned long arg);
- int (*release)(int objd);
-};
-
struct obj {
union {
struct {
obj->u.s.private_data = private_data;
}
-static
const struct objd_ops *objd_ops(int id)
{
struct obj *obj = _objd_get(id);
+
if (!obj)
return NULL;
return obj->u.s.ops;
ops->release(i);
}
free(objd_table.array);
+ objd_table.freelist_head = -1;
}
/*
METADATA_CHANNEL,
};
+int lttng_abi_create_root_handle(void)
+{
+ int root_handle;
+
+ root_handle = objd_alloc(NULL, <tng_ops);
+ assert(root_handle == 0);
+ return root_handle;
+}
+
+static
int lttng_abi_create_session(void)
{
struct ltt_session *session;
return; /* not allowed to return error */
}
-static
int lttng_abi_create_channel(int session_objd,
struct lttng_ust_channel *chan_param,
enum channel_type channel_type)