Home
last modified time | relevance | path

Searched refs:iter (Results 1 – 25 of 25) sorted by relevance

/trusty/kernel/lib/dtb_embedded/
Ddtb_embedded.c42 void dtb_embedded_iterator_reset(struct dtb_embedded_iterator* iter) { in dtb_embedded_iterator_reset() argument
43 if (iter) { in dtb_embedded_iterator_reset()
44 iter->offset = 0; in dtb_embedded_iterator_reset()
51 struct dtb_embedded_iterator* iter = (struct dtb_embedded_iterator*)calloc( in dtb_embedded_iterator_new() local
53 if (!iter) { in dtb_embedded_iterator_new()
58 dtb_embedded_iterator_reset(iter); in dtb_embedded_iterator_new()
59 *piter = iter; in dtb_embedded_iterator_new()
73 int dtb_embedded_iterator_next(struct dtb_embedded_iterator* iter, in dtb_embedded_iterator_next() argument
76 if (!iter) { in dtb_embedded_iterator_next()
93 if (iter->offset >= total_size) { in dtb_embedded_iterator_next()
[all …]
/trusty/kernel/lib/trusty/include/lib/trusty/
Duio.h47 struct iovec_iter iter = {.iov_cnt = iov_cnt}; in iovec_iter_create() local
48 return iter; in iovec_iter_create()
51 static inline int iovec_iter_has_next(const struct iovec_iter* iter) { in iovec_iter_has_next() argument
52 return iter->iov_index < iter->iov_cnt; in iovec_iter_has_next()
78 struct iovec_iter* iter);
/trusty/kernel/lib/trusty/
Diovec.c146 struct iovec_iter* iter) { in user_iovec_to_membuf_iter() argument
157 while (buf_len > 0 && iovec_iter_has_next(iter)) { in user_iovec_to_membuf_iter()
160 &uiov, iov_uaddr + iter->iov_index * sizeof(struct iovec_user), in user_iovec_to_membuf_iter()
166 if (uiov.iov_len < iter->data_offset) in user_iovec_to_membuf_iter()
170 size_t to_copy = uiov.iov_len - iter->data_offset; in user_iovec_to_membuf_iter()
175 ret = copy_from_user(buf, uiov.iov_base + iter->data_offset, to_copy); in user_iovec_to_membuf_iter()
180 iter->data_offset += to_copy; in user_iovec_to_membuf_iter()
181 if (iter->data_offset >= uiov.iov_len) { in user_iovec_to_membuf_iter()
182 iter->iov_index += 1; in user_iovec_to_membuf_iter()
183 iter->data_offset = 0; in user_iovec_to_membuf_iter()
[all …]
Dsyscall.c135 struct iovec_iter iter = iovec_iter_create(iov_cnt); in sys_std_writev() local
139 while (iovec_iter_has_next(&iter)) { in sys_std_writev()
140 ret = user_iovec_to_membuf_iter(buf, sizeof(buf), iov_uaddr, &iter); in sys_std_writev()
/trusty/kernel/lib/shared/device_tree/client/include/lib/shared/device_tree/
Ddevice_tree.h65 struct device_tree_inode_iter** iter);
83 struct device_tree_inode_iter** iter);
93 int device_tree_inode_iter_get_next_node(struct device_tree_inode_iter* iter,
132 struct device_tree_inode_iter** iter);
167 int device_tree_iprop_iter_get_next_prop(struct device_tree_iprop_iter* iter,
/trusty/kernel/lib/shared/device_tree/client/
Ddevice_tree.cpp91 struct device_tree_inode_iter** iter) { in device_tree_idevice_tree_get_compatible_nodes() argument
93 self, &compat_str, 1, iter); in device_tree_idevice_tree_get_compatible_nodes()
100 struct device_tree_inode_iter** iter) { in device_tree_idevice_tree_get_compatible_nodes_from_list() argument
118 *iter = &pinode_iter_container->cbinder; in device_tree_idevice_tree_get_compatible_nodes_from_list()
123 int device_tree_inode_iter_get_next_node(struct device_tree_inode_iter* iter, in device_tree_inode_iter_get_next_node() argument
125 assert(iter != nullptr); in device_tree_inode_iter_get_next_node()
129 const auto pinode_iter = device_tree_inode_iter_to_INodeIterator(iter); in device_tree_inode_iter_get_next_node()
188 struct device_tree_inode_iter** iter) { in device_tree_inode_get_subnodes() argument
190 assert(iter != nullptr); in device_tree_inode_get_subnodes()
204 *iter = &pinode_iter_container->cbinder; in device_tree_inode_get_subnodes()
[all …]
/trusty/kernel/lib/dtb_embedded/include/lib/dtb_embedded/
Ddtb_embedded.h57 void dtb_embedded_iterator_reset(struct dtb_embedded_iterator* iter);
72 int dtb_embedded_iterator_next(struct dtb_embedded_iterator* iter,
/trusty/kernel/platform/generic-arm64/
Ddtb.c47 struct dtb_embedded_iterator* iter; in find_dtb_by_compatible() local
48 rc = dtb_embedded_iterator_new(&iter); in find_dtb_by_compatible()
54 rc = dtb_embedded_iterator_next(iter, &current_dtb, &current_dtb_size); in find_dtb_by_compatible()
68 dtb_embedded_iterator_free(&iter); in find_dtb_by_compatible()
/trusty/kernel/lib/shared/device_tree/service/
Ddevice_tree_service.cpp92 sp<NodeIterator> iter = sp<NodeIterator>::make(std::move(compatible_strs), in get_compatible_nodes_from_list() local
94 if (iter == nullptr) { in get_compatible_nodes_from_list()
98 *node_iter = iter; in get_compatible_nodes_from_list()
221 sp<NodeIterator> iter = sp<NodeIterator>::make(subnode_offset, mDtb); in get_subnodes() local
222 if (iter == nullptr) { in get_subnodes()
226 *node_iter = iter; in get_subnodes()
249 sp<PropIterator> iter = sp<PropIterator>::make(prop_offset, mDtb); in get_props() local
250 if (iter == nullptr) { in get_props()
254 *prop_iter = iter; in get_props()
/trusty/user/base/app/apploader/
Dapp_manifest_parser.cpp35 struct app_manifest_iterator iter; in apploader_parse_manifest() local
36 app_manifest_iterator_reset(&iter, manifest_start, manifest_size); in apploader_parse_manifest()
55 while (app_manifest_iterator_next(&iter, &entry, &out_error)) { in apploader_parse_manifest()
/trusty/kernel/app/usercopytest/
Diovectest.c110 struct iovec_iter iter = iovec_iter_create(iov_cnt); in iovectest_readback() local
112 while (iovec_iter_has_next(&iter)) { in iovectest_readback()
114 _state->iovec_addr, &iter); in iovectest_readback()
119 if (iter.iov_index < iter.iov_cnt) { in iovectest_readback()
/trusty/user/base/app/device_tree/tests/
Dmain.c36 struct device_tree_inode_iter* iter = NULL; in TEST_F_SETUP() local
46 root_compat, &iter); in TEST_F_SETUP()
48 ASSERT_NE(iter, NULL); in TEST_F_SETUP()
50 rc = device_tree_inode_iter_get_next_node(iter, &_state->root_node); in TEST_F_SETUP()
59 if (iter) { in TEST_F_SETUP()
60 device_tree_inode_iter_release(&iter); in TEST_F_SETUP()
/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.rs95 for (i, b) in s.iter().enumerate().take(slots.len()) { in try_to_vec()
/trusty/user/app/storage/
Dclient.c866 struct file_iterate_state iter; member
898 static bool storage_file_list_iter(struct file_iterate_state* iter, in storage_file_list_iter() argument
904 containerof(iter, struct storage_file_list_state, iter); in storage_file_list_iter()
946 .iter.file = storage_file_list_iter, in storage_file_list()
996 iterate_res = file_iterate(&session->tr, last_name, false, &state.iter, in storage_file_list()
1003 iterate_res = file_iterate(&session->tr, last_name, true, &state.iter, in storage_file_list()
Dfile.h63 bool (*file)(struct file_iterate_state* iter,
Dsuper.c981 struct file_iterate_state iter; member
988 static bool fs_check_file(struct file_iterate_state* iter, in fs_check_file() argument
994 containerof(iter, struct fs_check_state, iter); in fs_check_file()
1048 .iter.file = fs_check_file, in fs_check_full()
1089 file_iterate(&iterate_tr, NULL, false, &state.iter, true); in fs_check_full()
/trusty/user/app/keymint/
Dsecure_storage_manager.rs479 use core::iter::zip;
545 for cert_data in certs_data.iter() { in read_certificates_test()
563 for (cert, cert_data) in zip(certs.iter(), certs_data.iter()) { in read_certificates_test()
570 for cert_data in certs_data.iter() { in read_certificates_test()
757 for cert_data in certs.iter() { in provision_certs_test_impl()
776 for (cert, read_cert) in certs.iter().zip(read_certs.iter()) { in provision_certs_test_impl()
/trusty/user/base/lib/tipc/rust/src/
Dhandle.rs158 if msg_info.len > buffers.iter().map(|b| b.len()).sum() { in recv_vectored()
213 buffers.iter().map(|buf| trusty_sys::iovec { in send_vectored()
218 let total_num_bytes = buffers.iter().map(|b| b.len()).sum(); in send_vectored()
Dservice.rs350 for (idx, b) in self.0.clock_seq_and_node.iter().enumerate() { in fmt()
844 let port_idx = self.ports.iter()
888 self.services.iter().map(|s| {
1032 .iter() in new_with_dispatcher()
/trusty/user/app/sample/hwcryptokey-test/
Dversioned_keys_explicit.rs73 let differing_bytes = key1.iter().zip(key2.iter()).filter(|(&x1, &x2)| x1 != x2).count(); in keys_are_sufficiently_distinct()
/trusty/user/base/lib/unittest-rust/src/
Dlib.rs267 let owned_tests: Vec<_> = tests.iter().map(make_owned_test).collect(); in test_main_static_abort()
/trusty/user/app/storage/test/block_host_test/
Dblock_test.c1752 struct file_iterate_state iter; member
1758 static bool file_iterate_many_iter(struct file_iterate_state* iter, in file_iterate_many_iter() argument
1764 containerof(iter, struct file_iterate_many_state, iter); in file_iterate_many_iter()
1790 .iter.file = file_iterate_many_iter, in file_iterate_many_test()
1798 res = file_iterate(tr, NULL, false, &state.iter, false); in file_iterate_many_test()
1801 res = file_iterate(tr, NULL, true, &state.iter, false); in file_iterate_many_test()
1807 res = file_iterate(tr, NULL, false, &state.iter, false); in file_iterate_many_test()
1811 res = file_iterate(tr, state.last_path, false, &state.iter, false); in file_iterate_many_test()
1815 res = file_iterate(tr, NULL, true, &state.iter, false); in file_iterate_many_test()
/trusty/user/base/lib/hwkey/rust/src/
Dtest.rs42 let differing_bytes = sk.iter().zip(lk).filter(|&(s, l)| s ^ l != 0).count(); in keys_are_sufficiently_distinct()
/trusty/device/arm/generic-arm64/project/qemu/
Dqemu.py214 for line in iter(self.com_pipe_out.readline, ""):