Home
last modified time | relevance | path

Searched refs:ctxdata (Results 1 – 4 of 4) sorted by relevance

/linux/drivers/tee/amdtee/
H A Dcore.c39 struct amdtee_context_data *ctxdata; in amdtee_open() local
41 ctxdata = kzalloc(sizeof(*ctxdata), GFP_KERNEL); in amdtee_open()
42 if (!ctxdata) in amdtee_open()
45 INIT_LIST_HEAD(&ctxdata->sess_list); in amdtee_open()
46 INIT_LIST_HEAD(&ctxdata->shm_list); in amdtee_open()
47 mutex_init(&ctxdata->shm_mutex); in amdtee_open()
49 ctx->data = ctxdata; in amdtee_open()
72 struct amdtee_context_data *ctxdata = ctx->data; in amdtee_release() local
74 if (!ctxdata) in amdtee_release()
80 sess = list_first_entry_or_null(&ctxdata->sess_list, in amdtee_release()
[all …]
/linux/drivers/tee/qcomtee/
H A Dcall.c16 struct qcomtee_context_data *ctxdata) in find_qtee_object() argument
22 *object = idr_find(&ctxdata->qtee_objects_idr, id); in find_qtee_object()
30 struct qcomtee_context_data *ctxdata) in del_qtee_object() argument
34 scoped_guard(mutex, &ctxdata->qtee_lock) in del_qtee_object()
35 object = idr_remove(&ctxdata->qtee_objects_idr, id); in del_qtee_object()
56 struct qcomtee_context_data *ctxdata = ctx->data; in qcomtee_context_add_qtee_object() local
58 scoped_guard(mutex, &ctxdata->qtee_lock) in qcomtee_context_add_qtee_object()
59 ret = idr_alloc(&ctxdata->qtee_objects_idr, object, 0, 0, in qcomtee_context_add_qtee_object()
76 struct qcomtee_context_data *ctxdata = ctx->data; in qcomtee_context_find_qtee_object() local
78 return find_qtee_object(object, param->u.objref.id, ctxdata); in qcomtee_context_find_qtee_object()
[all …]
/linux/drivers/tee/tstee/
H A Dcore.c60 struct ts_context_data *ctxdata; in tstee_open() local
62 ctxdata = kzalloc(sizeof(*ctxdata), GFP_KERNEL); in tstee_open()
63 if (!ctxdata) in tstee_open()
66 xa_init_flags(&ctxdata->sess_list, XA_FLAGS_ALLOC); in tstee_open()
68 ctx->data = ctxdata; in tstee_open()
75 struct ts_context_data *ctxdata = ctx->data; in tstee_release() local
79 if (!ctxdata) in tstee_release()
82 xa_for_each(&ctxdata->sess_list, idx, sess) { in tstee_release()
83 xa_erase(&ctxdata->sess_list, idx); in tstee_release()
87 xa_destroy(&ctxdata->sess_list); in tstee_release()
[all …]
/linux/drivers/tee/optee/
H A Dcall.c205 static struct optee_session *find_session(struct optee_context_data *ctxdata, in find_session() argument
210 list_for_each_entry(sess, &ctxdata->sess_list, list_node) in find_session()
367 struct optee_context_data *ctxdata = ctx->data; in optee_open_session() local
422 mutex_lock(&ctxdata->mutex); in optee_open_session()
423 list_add(&sess->list_node, &ctxdata->sess_list); in optee_open_session()
424 mutex_unlock(&ctxdata->mutex); in optee_open_session()
449 struct optee_context_data *ctxdata = ctx->data; in optee_system_session() local
453 mutex_lock(&ctxdata->mutex); in optee_system_session()
455 sess = find_session(ctxdata, session); in optee_system_session()
462 mutex_unlock(&ctxdata->mutex); in optee_system_session()
[all …]