| /optee_os/core/tee/ |
| H A D | tee_svc_storage.c | 76 static void remove_corrupt_obj(struct user_ta_ctx *utc, struct tee_obj *o) in remove_corrupt_obj() argument 78 o->pobj->fops->remove(o->pobj); in remove_corrupt_obj() 80 tee_obj_close(utc, o); in remove_corrupt_obj() 83 static TEE_Result tee_svc_storage_read_head(struct tee_obj *o) in tee_svc_storage_read_head() argument 88 const struct tee_file_operations *fops = o->pobj->fops; in tee_svc_storage_read_head() 93 assert(!o->fh); in tee_svc_storage_read_head() 94 res = fops->open(o->pobj, &size, &o->fh); in tee_svc_storage_read_head() 100 res = fops->read(o->fh, 0, &head, NULL, &bytes); in tee_svc_storage_read_head() 121 res = tee_obj_set_type(o, head.objectType, head.maxObjectSize); in tee_svc_storage_read_head() 125 o->ds_pos = tmp; in tee_svc_storage_read_head() [all …]
|
| H A D | tee_obj.c | 15 void tee_obj_add(struct user_ta_ctx *utc, struct tee_obj *o) in tee_obj_add() argument 17 TAILQ_INSERT_TAIL(&utc->objects, o, link); in tee_obj_add() 23 struct tee_obj *o; in tee_obj_get() local 25 TAILQ_FOREACH(o, &utc->objects, link) { in tee_obj_get() 26 if (obj_id == (vaddr_t)o) { in tee_obj_get() 27 *obj = o; in tee_obj_get() 34 void tee_obj_close(struct user_ta_ctx *utc, struct tee_obj *o) in tee_obj_close() argument 36 TAILQ_REMOVE(&utc->objects, o, link); in tee_obj_close() 38 if ((o->info.handleFlags & TEE_HANDLE_FLAG_PERSISTENT)) { in tee_obj_close() 39 o->pobj->fops->close(&o->fh); in tee_obj_close() [all …]
|
| H A D | tee_pobj.c | 85 struct tee_pobj *o = NULL; in tee_pobj_get() local 91 TAILQ_FOREACH(o, &tee_pobjs, link) { in tee_pobj_get() 92 if ((obj_id_len == o->obj_id_len) && in tee_pobj_get() 93 (memcmp(obj_id, o->obj_id, obj_id_len) == 0) && in tee_pobj_get() 94 (memcmp(uuid, &o->uuid, sizeof(TEE_UUID)) == 0) && in tee_pobj_get() 95 (fops == o->fops)) { in tee_pobj_get() 96 *obj = o; in tee_pobj_get() 117 o = calloc(1, sizeof(struct tee_pobj)); in tee_pobj_get() 118 if (!o) { in tee_pobj_get() 123 o->refcnt = 1; in tee_pobj_get() [all …]
|
| H A D | tee_svc_cryp.c | 1179 struct tee_obj *o = NULL; in syscall_cryp_obj_get_info() local 1182 uref_to_vaddr(obj), &o); in syscall_cryp_obj_get_info() 1186 o_info.obj_type = o->info.objectType; in syscall_cryp_obj_get_info() 1187 o_info.obj_size = o->info.objectSize; in syscall_cryp_obj_get_info() 1188 o_info.max_obj_size = o->info.maxObjectSize; in syscall_cryp_obj_get_info() 1189 if (o->info.handleFlags & TEE_HANDLE_FLAG_PERSISTENT) { in syscall_cryp_obj_get_info() 1190 tee_pobj_lock_usage(o->pobj); in syscall_cryp_obj_get_info() 1191 o_info.obj_usage = o->pobj->obj_info_usage; in syscall_cryp_obj_get_info() 1192 tee_pobj_unlock_usage(o->pobj); in syscall_cryp_obj_get_info() 1194 o_info.obj_usage = o->info.objectUsage; in syscall_cryp_obj_get_info() [all …]
|
| H A D | tee_time_generic.c | 41 struct tee_ta_time_offs *o; in tee_time_ta_set_offs() local 53 o = realloc(tee_time_offs, n * sizeof(struct tee_ta_time_offs)); in tee_time_ta_set_offs() 54 if (!o) in tee_time_ta_set_offs() 56 tee_time_offs = o; in tee_time_ta_set_offs()
|
| /optee_os/core/include/kernel/ |
| H A D | refcount.h | 26 * // Some other thread may have initialized o by now so check that 27 * // we still need to initialize o. 28 * if (!o) { 29 * o = initialize(); 38 * // Now that we have the mutex o can't be ininialized/uninitialized 40 * // to guard against the thread above already having reinitialized o 41 * if (!refcount_val(r) && o) 42 * uninitialize(o) 46 * where r if the reference counter, o is the object and m the mutex
|
| /optee_os/core/arch/arm/kernel/ |
| H A D | link.mk | 45 $(out-dir)/$(platform-dir)/link_dummies_paged.o \ 46 $(out-dir)/$(platform-dir)/link_dummies_init.o \ 47 $(out-dir)/$(arch-dir)/kernel/link_dummies_paged.o \ 48 $(out-dir)/$(arch-dir)/kernel/link_dummies_init.o, \ 51 $(out-dir)/$(platform-dir)/link_dummies_init.o \ 52 $(out-dir)/$(arch-dir)/kernel/link_dummies_init.o, \ 54 ldargs-tee.elf := $(link-ldflags) $(link-objs) $(link-out-dir)/version.o \ 66 cleanfiles += $(link-out-dir)/all_objs.o 67 $(link-out-dir)/all_objs.o: $(objs) $(libdeps) $(MAKEFILE_LIST) 69 $(q)$(LDcore) $(ldargs-all_objs) -o $@ [all …]
|
| /optee_os/lib/libutils/ext/include/ |
| H A D | fault_mitigation.h | 155 #define __FTMN_FUNC_BYTE(f, o, l) ((o) < (l) ? (uint8_t)(f)[(o)] : 0) argument 158 #define __FTMN_GET_FUNC_U32(f, o, l) \ argument 159 (SHIFT_U32(__FTMN_FUNC_BYTE((f), (o), (l)), 0) | \ 160 SHIFT_U32(__FTMN_FUNC_BYTE((f), (o) + 1, (l)), 8) | \ 161 SHIFT_U32(__FTMN_FUNC_BYTE((f), (o) + 2, (l)), 16) | \ 162 SHIFT_U32(__FTMN_FUNC_BYTE((f), (o) + 3, (l)), 24)) 164 #define __FTMN_FUNC_HASH64(f, o, l) \ argument 165 (__FTMN_GET_FUNC_U32((f), (o), (l)) ^ \ 166 __FTMN_GET_FUNC_U32((f), (o) + 4, (l))) 168 #define __FTMN_FUNC_HASH32(f, o, l) \ argument [all …]
|
| /optee_os/core/arch/riscv/kernel/ |
| H A D | link.mk | 27 ldargs-tee.elf := $(link-ldflags) $(link-objs) $(link-out-dir)/version.o \ 39 cleanfiles += $(link-out-dir)/all_objs.o 40 $(link-out-dir)/all_objs.o: $(objs) $(libdeps) $(MAKEFILE_LIST) 42 $(q)$(LDcore) $(ldargs-all_objs) -o $@ 52 $(link-script-cppflags) $< -o $@ 54 $(link-out-dir)/version.o: 55 $(call gen-version-o) 66 cleanfiles += $(link-out-dir)/version.o 70 $(call gen-version-o) 73 $(q)$(LDcore) $(ldargs-tee.elf) -o $@ [all …]
|
| H A D | cache_helpers_rv.S | 11 * The FENCE instruction is used to order device I/O and memory accesses 14 * performs Fence on all memory and I/O.
|
| /optee_os/mk/ |
| H A D | macros.mk | 22 version-o-cflags = $(filter-out -g3,$(CFLAGS) $(core-platform-cflags) \ 30 define gen-version-o 32 @$(cmd-echo-silent) ' GEN $(link-out-dir)/version.o' 41 | $(CCcore) $(version-o-cflags) \ 42 -xc - -c -o version.o
|
| H A D | cleandirs.mk | 17 # Returns the list of all existing output directories up to $(O) including all 20 # Example: if cleanfiles is "foo/a/file1 foo/b/c/d/file2" and O=foo, this will 23 $(eval _O:=$(if $(O),$(O),.))$(wildcard $(addprefix $(_O)/,$(call _reverse,
|
| H A D | subdir.mk | 66 oname := $(out-dir)/$(base-prefix)$(basename $1).o 72 oname := $(out-dir)/$(base-prefix)$(basename $1).o 76 oname := $(out-dir)/$(base-prefix)$(basename $$(sub-dir)/$1).o 89 oname := $(out-dir)/$(base-prefix)$(basename $1).o 91 oname := $(out-dir)/$(base-prefix)$(basename $$(sub-dir)/$1).o 122 …r,$1,$(sub-dir-out)/$$(produce-$1),$(sub-dir-out)/$(basename $(produce-$1)).o,$(sub-dir-out),$(for…
|
| /optee_os/lib/libutils/isoc/include/ |
| H A D | inttypes.h | 30 #define PRIo8 "o" 31 #define PRIo16 "o" 32 #define PRIo32 "o" 33 #define PRIo64 __PRI64_PREFIX "o" 34 #define PRIoPTR __PRIPTR_PREFIX "o"
|
| /optee_os/core/lib/libtomcrypt/src/pk/ec25519/ |
| H A D | tweetnacl.c | 47 sv car25519(gf o) in car25519() argument 52 o[i]+=(1LL<<16); in car25519() 53 c=o[i]>>16; in car25519() 54 o[(i+1)*(i<15)]+=c-1+37*(c-1)*(i==15); in car25519() 55 o[i]-=c<<16; in car25519() 69 sv pack25519(u8 *o,const gf n) in pack25519() argument 89 o[2*i]=t[i]&0xff; in pack25519() 90 o[2*i+1]=t[i]>>8; in pack25519() 109 sv unpack25519(gf o, const u8 *n) in unpack25519() argument 112 FOR(i,16) o[i]=n[2*i]+((u64)n[2*i+1]<<8); in unpack25519() [all …]
|
| /optee_os/ |
| H A D | Makefile | 48 ifeq ($O,) 49 O := out macro 50 out-dir := $(O)/$(ARCH)-plat-$(PLATFORM) 52 out-dir := $(O) 110 @if [ "$(out-dir)" != "$(O)" ]; then $(cmd-echo-silent) ' CLEAN $(O)'; fi 111 ${q}if [ -d "$(O)" ]; then $(RMDIR) $(O); fi
|
| /optee_os/core/drivers/crypto/se050/core/ |
| H A D | storage.c | 16 TEE_Result crypto_storage_obj_del(struct tee_obj *o) in crypto_storage_obj_del() argument 27 if (!o) in crypto_storage_obj_del() 30 len = o->info.dataSize; in crypto_storage_obj_del() 41 ret = o->pobj->fops->read(o->fh, o->info.dataPosition, in crypto_storage_obj_del()
|
| /optee_os/core/include/tee/ |
| H A D | tee_obj.h | 27 void tee_obj_add(struct user_ta_ctx *utc, struct tee_obj *o); 32 void tee_obj_close(struct user_ta_ctx *utc, struct tee_obj *o); 36 TEE_Result tee_obj_verify(struct tee_ta_session *sess, struct tee_obj *o); 39 void tee_obj_free(struct tee_obj *o);
|
| H A D | tee_svc_cryp.h | 85 TEE_Result tee_obj_set_type(struct tee_obj *o, uint32_t obj_type, 88 void tee_obj_attr_free(struct tee_obj *o); 89 void tee_obj_attr_clear(struct tee_obj *o); 90 TEE_Result tee_obj_attr_to_binary(struct tee_obj *o, void *data, 92 TEE_Result tee_obj_attr_from_binary(struct tee_obj *o, const void *data, 94 TEE_Result tee_obj_attr_copy_from(struct tee_obj *o, const struct tee_obj *src);
|
| /optee_os/core/pta/tests/ |
| H A D | fs_htree.c | 410 size_t o = 0; in aux_alloc() local 413 if (test_get_offs_size(TEE_FS_HTREE_TYPE_BLOCK, num_blocks, 1, &o, &sz)) in aux_alloc() 420 aux->data_alloced = o + sz; in aux_alloc() 442 size_t o = 0; in test_write_read() local 452 * o is the number of blocks we're rewriting starting at m. in test_write_read() 456 for (o = 0; o < (n - m); o++) { in test_write_read() 457 res = htree_test_rewrite(aux, n, m, o); in test_write_read() 459 o += 2; in test_write_read()
|
| /optee_os/ta/mk/ |
| H A D | ta_dev_kit.mk | 16 ifneq ($O,) 17 out-dir := $O 122 @$(cmd-echo-silent) ' CLEAN $(O)' 123 ${q}if [ -d "$(O)" ]; then $(RMDIR) $(O); fi
|
| /optee_os/keys/ |
| H A D | default.pem | 34 mTH0UYfcfGuV4+9o/ywgQlylPEjv+4ney6cBUTNqQEO2mRj2EBK2axJaHrrRXTcz 42 yDOxJEqwFoS44ln6UsMKPfq96f3K976NV/dm1BnT2HolWU2aoQp7qByBfVy/o/xL
|
| H A D | default_ta.pem | 34 mTH0UYfcfGuV4+9o/ywgQlylPEjv+4ney6cBUTNqQEO2mRj2EBK2axJaHrrRXTcz 42 yDOxJEqwFoS44ln6UsMKPfq96f3K976NV/dm1BnT2HolWU2aoQp7qByBfVy/o/xL
|
| /optee_os/core/lib/zlib/ |
| H A D | inflate.h | 36 COPY_, /* i/o: same as COPY below, but only first time in */ 37 COPY, /* i/o: waiting for input or output to copy stored block */ 46 MATCH, /* o: waiting for output space to copy string */ 47 LIT, /* o: waiting for output space to write literal */
|
| /optee_os/core/lib/libtomcrypt/src/misc/base32/ |
| H A D | base32_decode.c | 31 …13/*N*/,14/*O*/,15/*P*/,16/*Q*/,17/*R*/,18/*S*/,19/*T*/,20/*U*/,21/*V*/,22/*W*/,23/*X*/,24/*Y*/,25… in base32_decode() 37 …23/*N*/,24/*O*/,25/*P*/,26/*Q*/,27/*R*/,28/*S*/,29/*T*/,30/*U*/,31/*V*/,99/*W*/,99/*X*/,99/*Y*/,99… in base32_decode() 43 …2/*N*/,16/*O*/,13/*P*/,14/*Q*/, 4/*R*/,22/*S*/,17/*T*/,19/*U*/,99/*V*/,20/*W*/,15/*X*/, 0/*Y*/,23/… in base32_decode() 45 { /* id = BASE32_CROCKFORD : 0123456789ABCDEFGHJKMNPQRSTVWXYZ + O=>0 + IL=>1 */ in base32_decode() 49 …21/*N*/, 0/*O*/,22/*P*/,23/*Q*/,24/*R*/,25/*S*/,26/*T*/,99/*U*/,27/*V*/,28/*W*/,29/*X*/,30/*Y*/,31… in base32_decode()
|