Home
last modified time | relevance | path

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

1234

/external/rust/crates/quiche/src/
Dffi.rs145 let protos = unsafe { slice::from_raw_parts(protos, protos_len) }; in quiche_config_set_application_protos()
330 let scid = unsafe { slice::from_raw_parts(scid, scid_len) }; in quiche_accept()
333 Some(unsafe { slice::from_raw_parts(odcid, odcid_len) }) in quiche_accept()
356 let scid = unsafe { slice::from_raw_parts(scid, scid_len) }; in quiche_connect()
370 let scid = unsafe { slice::from_raw_parts(scid, scid_len) }; in quiche_negotiate_version()
371 let dcid = unsafe { slice::from_raw_parts(dcid, dcid_len) }; in quiche_negotiate_version()
392 let scid = unsafe { slice::from_raw_parts(scid, scid_len) }; in quiche_retry()
393 let dcid = unsafe { slice::from_raw_parts(dcid, dcid_len) }; in quiche_retry()
394 let new_scid = unsafe { slice::from_raw_parts(new_scid, new_scid_len) }; in quiche_retry()
395 let token = unsafe { slice::from_raw_parts(token, token_len) }; in quiche_retry()
[all …]
Dtls.rs407 unsafe { slice::from_raw_parts(ptr, len) } in quic_transport_params()
422 unsafe { slice::from_raw_parts(ptr, len as usize) } in alpn_protocol()
496 let der = slice::from_raw_parts(out, out_len as usize); in peer_cert()
587 let secret = unsafe { slice::from_raw_parts(secret, secret_len) }; in set_read_secret()
637 let secret = unsafe { slice::from_raw_parts(secret, secret_len) }; in set_write_secret()
668 let buf = unsafe { slice::from_raw_parts(data, len) }; in add_handshake_data()
749 slice::from_raw_parts(inp, in_len as usize) in select_alpn()
/external/crosvm/data_model/src/
Dsys.rs27 unsafe { Self::from_raw_parts(buf.as_mut_ptr(), buf.len()) } in new()
36 pub unsafe fn from_raw_parts(addr: *mut u8, len: usize) -> IoBufMut<'a> { in from_raw_parts() method
73 unsafe { slice::from_raw_parts(iovs.as_ptr() as *const libc::iovec, iovs.len()) } in as_iobufs()
Dvolatile_memory.rs121 pub unsafe fn from_raw_parts(addr: *mut u8, len: usize) -> VolatileSlice<'a> { in from_raw_parts() method
122 VolatileSlice(IoBufMut::from_raw_parts(addr, len)) in from_raw_parts()
150 slice::from_raw_parts(iovs.as_ptr() as *const IoBufMut, iovs.len()) in as_iobufs()
170 unsafe { Ok(VolatileSlice::from_raw_parts(new_addr as *mut u8, new_size)) } in offset()
189 Ok(unsafe { VolatileSlice::from_raw_parts(new_addr as *mut u8, count) }) in sub_slice()
389 unsafe { VolatileSlice::from_raw_parts(self.as_mut_ptr() as *mut u8, self.size()) } in to_slice()
427 Ok(unsafe { VolatileSlice::from_raw_parts(new_addr as *mut u8, count) }) in get_slice()
Dlib.rs7 use std::slice::{from_raw_parts, from_raw_parts_mut};
103 unsafe { from_raw_parts(self as *const Self as *const u8, size_of::<Self>()) } in as_slice()
/external/rust/cxx/tests/ffi/
Dcast.rs7 unsafe { slice::from_raw_parts(ptr, len) } in c_char_to_unsigned()
13 unsafe { slice::from_raw_parts(ptr, len) } in unsigned_to_c_char()
/external/crosvm/sys_util/src/
Dstruct_util.rs78 std::slice::from_raw_parts( in struct_basic_read()
102 std::slice::from_raw_parts( in struct_read_past_end()
140 std::slice::from_raw_parts( in struct_slice_read()
Dsock_ctrl_msg.rs386 unsafe { slice::from_raw_parts(bufs.as_ptr() as *const iovec, bufs.len()) } in as_iobuf_slice()
402 unsafe { slice::from_raw_parts(bufs.as_ptr() as *const iovec, bufs.len()) } in as_iobuf_slice()
426 use std::slice::from_raw_parts;
527 file.write_all(unsafe { from_raw_parts(&1203u64 as *const u64 as *const u8, 8) }) in send_recv_only_fd()
561 file.write_all(unsafe { from_raw_parts(&1203u64 as *const u64 as *const u8, 8) }) in send_recv_with_fd()
/external/rust/crates/quiche/src/h3/
Dffi.rs239 let body = unsafe { slice::from_raw_parts(body, body_len) }; in quiche_h3_send_body()
275 let data = unsafe { slice::from_raw_parts(data, data_len) }; in quiche_h3_send_dgram()
314 let headers = unsafe { slice::from_raw_parts(ptr, len) }; in headers_from_ptr()
321 let slice = slice::from_raw_parts(h.name, h.name_len); in headers_from_ptr()
326 let slice = slice::from_raw_parts(h.value, h.value_len); in headers_from_ptr()
/external/rust/crates/half/src/
Dvec.rs139 unsafe { Vec::from_raw_parts(pointer, length, capacity) } in reinterpret_into()
181 unsafe { Vec::from_raw_parts(pointer, length, capacity) } in reinterpret_into()
227 unsafe { Vec::from_raw_parts(pointer, length, capacity) } in reinterpret_into()
/external/rust/crates/rusqlite/src/types/
Dvalue_ref.rs130 use std::slice::from_raw_parts; in from_value()
143 let s = from_raw_parts(text as *const u8, len as usize); in from_value()
161 ValueRef::Blob(from_raw_parts(blob as *const u8, len as usize)) in from_value()
/external/rust/cxx/src/
Drust_vec.rs70 Self::from(unsafe { Vec::from_raw_parts(ptr, len, cap) }) in from_vec_string()
86 unsafe { Vec::from_raw_parts(ptr, len, cap) } in into_vec_string()
Drust_slice.rs28 slice::from_raw_parts(ptr.cast(), len) in as_slice()
/external/crosvm/crosvm_plugin/src/
Dlib.rs28 use std::slice::{from_raw_parts, from_raw_parts_mut};
1549 let ret = self_.set_irq_routing(slice::from_raw_parts(routes, route_count as usize)); in crosvm_set_irq_routing()
1569 let hints = slice::from_raw_parts(hints, hints_count as usize); in crosvm_set_hypercall_hint()
1583 slice::from_raw_parts(hint.details, hint.details_count as usize), in crosvm_set_hypercall_hint()
1619 let state = from_raw_parts(state as *mut u8, size_of::<kvm_pic_state>()); in crosvm_set_pic_state()
1643 let state = from_raw_parts(state as *mut u8, size_of::<kvm_ioapic_state>()); in crosvm_set_ioapic_state()
1667 let state = from_raw_parts(state as *mut u8, size_of::<kvm_pit_state2>()); in crosvm_set_pit_state()
1691 let state = from_raw_parts(clock_data as *mut u8, size_of::<kvm_clock_data>()); in crosvm_set_clock()
1790 let regs = from_raw_parts(regs as *mut u8, size_of::<kvm_regs>()); in crosvm_vcpu_set_regs()
1826 let sregs = from_raw_parts(sregs as *mut u8, size_of::<kvm_sregs>()); in crosvm_vcpu_set_sregs()
[all …]
/external/rust/crates/rusqlite/src/
Dunlock_notify.rs46 use std::slice::from_raw_parts; in unlock_notify_cb()
47 let args = from_raw_parts(ap_arg as *const &UnlockNotification, n_arg as usize); in unlock_notify_cb()
Dcollation.rs60 let c_slice = slice::from_raw_parts(arg3 as *const u8, arg2 as usize); in create_collation()
64 let c_slice = slice::from_raw_parts(arg5 as *const u8, arg4 as usize); in create_collation()
/external/rust/crates/grpcio/src/
Dmetadata.rs175 let key_str = str::from_utf8_unchecked(slice::from_raw_parts(key as _, key_len)); in get()
176 let val_bytes = slice::from_raw_parts(val as *const u8, val_len); in get()
210 pub unsafe fn from_raw_parts(p: *mut grpc_metadata, len: usize, cap: usize) -> Metadata { in from_raw_parts() method
/external/flatbuffers/rust/flatbuffers/src/
Dvector.rs20 use std::slice::from_raw_parts;
87 let s: &'a [T] = unsafe { from_raw_parts(ptr, len) }; in safe_slice()
136 let s: &[T] = unsafe { from_raw_parts(ptr, len) }; in follow_slice_helper()
/external/rust/cxx/src/symbols/
Dexception.rs7 let slice = slice::from_raw_parts(ptr, len); in exception()
Drust_str.rs19 let slice = slice::from_raw_parts(ptr, len); in str_from()
Drust_string.rs24 let slice = slice::from_raw_parts(ptr, len); in string_from()
/external/rust/crates/vmm_vhost/src/vhost_user/
Dconnection.rs193 [slice::from_raw_parts( in send_header()
226 slice::from_raw_parts( in send_message()
230 slice::from_raw_parts(body as *const T as *const u8, mem::size_of::<T>()), in send_message()
274 slice::from_raw_parts( in send_message_with_payload()
278 slice::from_raw_parts(body as *const T as *const u8, mem::size_of::<T>()), in send_message_with_payload()
279 slice::from_raw_parts(payload.as_ptr() as *const u8, len), in send_message_with_payload()
/external/crosvm/tpm2/src/
Dlib.rs147 slice::from_raw_parts(response, response_size as usize) in execute_command()
/external/flatbuffers/tests/include_test/sub/
Dinclude_test2_generated.rs114 ::std::slice::from_raw_parts(self as *const Unused as *const u8, Self::size()) in push()
125 ::std::slice::from_raw_parts(*self as *const Unused as *const u8, Self::size()) in push()
/external/flatbuffers/tests/namespace_test/
Dnamespace_test1_generated.rs118 ::std::slice::from_raw_parts(self as *const StructInNestedNS as *const u8, Self::size()) in push()
129 … ::std::slice::from_raw_parts(*self as *const StructInNestedNS as *const u8, Self::size()) in push()

1234