Home
last modified time | relevance | path

Searched refs:mem (Results 1 – 22 of 22) sorted by relevance

/trusty/user/base/lib/scudo/test/
Dscudo_test.c185 void* mem = memalign(PAGE_SIZE, PAGE_SIZE); in TEST_F() local
186 ASSERT_NE(mem, NULL); in TEST_F()
187 memset(mem, 0x33, PAGE_SIZE); in TEST_F()
189 mem, PAGE_SIZE, in TEST_F()
192 printf("created memref %d for %p\n", ref, mem); in TEST_F()
195 EXPECT_EQ(*((volatile char*)mem), 0x77); in TEST_F()
198 free(mem); in TEST_F()
207 void* mem = memalign(PAGE_SIZE, PAGE_SIZE * 32); in TEST_F() local
208 ASSERT_NE(mem, NULL); in TEST_F()
209 memset(mem, 0x33, PAGE_SIZE); in TEST_F()
[all …]
/trusty/user/base/lib/scudo/test/srv/
Dscudo_app.cpp381 void* mem = malloc(64); in scudo_on_message() local
382 char* arr = reinterpret_cast<char*>(mem); in scudo_on_message()
385 3 + reinterpret_cast<char*>(retagged(mem)); in scudo_on_message()
390 free(mem); in scudo_on_message()
395 void* mem = malloc(64); in scudo_on_message() local
396 char* arr = reinterpret_cast<char*>(mem); in scudo_on_message()
398 volatile char* retagged_arr = reinterpret_cast<char*>(retagged(mem)); in scudo_on_message()
403 free(mem); in scudo_on_message()
408 void* mem = malloc(64); in scudo_on_message() local
409 memset(mem, 64, 0xaa); in scudo_on_message()
[all …]
/trusty/user/app/keymint/
Dffi_bindings.rs27 use core::mem;
50 mem::size_of::<sys::keybox_resp>() + mem::size_of::<sys::keybox_unwrap_resp>();
57 KEYBOX_RESP_HDR_SIZE == (mem::size_of::<u32>() + mem::size_of::<u32>() + mem::size_of::<u64>()),
Dkeys.rs20 use core::mem::size_of;
43 const U32_SIZE: usize = core::mem::size_of::<u32>();
Dipc_manager.rs19 use core::{cell::RefCell, mem};
460 key_material: mem::take(&mut payload.0), in handle_message()
Dkeymaster_attributes.rs911 ::std::mem::replace(&mut self.certs, ::protobuf::RepeatedField::new()) in take_certs()
/trusty/user/base/lib/system_state/rust/src/
Dlib.rs30 use core::mem;
180 mem::size_of::<system_state_resp>() + mem::size_of::<system_state_get_flag_resp>();
183 if bytes.len() < mem::size_of::<system_state_resp>() { in deserialize()
194 < mem::size_of::<system_state_resp>() in deserialize()
195 + mem::size_of::<system_state_get_flag_resp>() in deserialize()
/trusty/user/base/lib/dlmalloc/
Ddlmalloc.c1338 DLMALLOC_EXPORT void mspace_free(mspace msp, void* mem);
1349 DLMALLOC_EXPORT void* mspace_realloc(mspace msp, void* mem, size_t newsize);
1401 DLMALLOC_EXPORT size_t mspace_usable_size(const void* mem);
2226 #define _mem2chunk(mem) ((mchunkptr)((char*)(mem) - TWO_SIZE_T_SIZES)) argument
2230 #define mem2chunk(mem) (mchunkptr)hwasan_remove_ptr_tag(_mem2chunk(mem)) argument
2233 #define mem2chunk(mem) _mem2chunk(mem) argument
2828 static void do_check_malloced_chunk(mstate m, void* mem, size_t s);
3299 static void do_check_malloced_chunk(mstate m, void* mem, size_t s) { in do_check_malloced_chunk() argument
3300 if (mem != 0) { in do_check_malloced_chunk()
3301 mchunkptr p = mem2chunk(mem); in do_check_malloced_chunk()
[all …]
/trusty/user/base/lib/tipc/rust/src/
Dserialization.rs3 use core::{mem, slice};
33 let bytes: &'s [u8] = slice::from_raw_parts(&*ptr, mem::size_of::<T>()); in serialize_as_bytes()
Dhandle.rs22 use core::mem::MaybeUninit;
Dservice.rs19 use core::mem::{ManuallyDrop, MaybeUninit};
236 const UUID_BYTE_LEN: usize = std::mem::size_of::<trusty_sys::uuid>();
256 let uuid = unsafe { std::mem::transmute_copy(bytes) };
/trusty/user/app/sample/stats-test/
DREADME.md40 test ->> test: wait until shared mem is updated
49 consumer ->> consumer: write atom to shared mem
50 consumer -->> test: shared mem updated
54 test ->> test: verify shared mem == atom
91 test ->> test: wait for shared mem to be updated
98 consumer ->> consumer: write atom to shared mem
101 test ->> test: verify shared mem holds the canned data
/trusty/user/base/lib/hwwsk/rust/src/
Dlib.rs36 use core::mem;
86 let header_size = mem::size_of::<hwwsk_req_hdr>(); in deserialize()
146 let header_size = mem::size_of::<hwwsk_generate_key_req>(); in deserialize()
222 let header_size = mem::size_of::<u32>() * 2; in deserialize()
227 let (cmd_bytes, rest) = bytes.split_at(mem::size_of::<u32>()); in deserialize()
228 let (status_bytes, payload_bytes) = rest.split_at(mem::size_of::<u32>()); in deserialize()
/trusty/user/app/storage/test/storage-unittest-aidl/unittests/
Dhelpers.rs59 const U32_SIZE: usize = std::mem::size_of::<u32>(); in check_pattern32()
84 const U32_SIZE: usize = std::mem::size_of::<u32>(); in fill_pattern32()
97 if chunk_len % std::mem::size_of::<u32>() != 0 { in check_valid_size()
/trusty/user/base/lib/trusty-std/src/
Dlib.rs58 i64, i8, intrinsics, isize, iter, marker, mem, ops, option, pin, primitive, ptr, result, u128,
Dclone_ext.rs99 core::mem::forget(guard); in try_to_vec()
/trusty/user/base/lib/hwkey/rust/src/
Dlib.rs35 use core::mem;
185 const HEADER_SIZE: usize = mem::size_of::<hwkey_derive_versioned_msg>(); in derive()
587 let header_size = mem::size_of::<hwkey_msg>(); in deserialize()
624 let header_size = mem::size_of::<hwkey_derive_versioned_msg>(); in deserialize()
Dtest.rs418 const HEADER_SIZE: usize = mem::size_of::<hwkey_derive_versioned_msg>(); in test_hwkey_derive_large_payload()
/trusty/user/base/lib/storage/rust/src/
Dtransaction.rs43 core::mem::forget(self); in end_transaction()
Dlib.rs141 use core::mem::MaybeUninit;
/trusty/user/base/lib/hwbcc/rust/src/
Dlib.rs44 use core::mem;
169 let header_size = mem::size_of::<hwbcc_resp_hdr>(); in deserialize()
/trusty/user/app/sample/memref-test/rust/
Dmemref_test.rs53 std::mem::drop(remote_handle); in drop_shared_buf_handle()