1 // Copyright 2017 The Fuchsia Authors. All rights reserved. 2 // This is a GENERATED file, see //zircon/system/host/sysgen. 3 // The license governing this file can be found in the LICENSE file. 4 5 #[link(name = "zircon")] 6 extern { zx_time_get( clock_id: u32 ) -> zx_time_t7 pub fn zx_time_get( 8 clock_id: u32 9 ) -> zx_time_t; 10 zx_nanosleep( deadline: zx_time_t ) -> zx_status_t11 pub fn zx_nanosleep( 12 deadline: zx_time_t 13 ) -> zx_status_t; 14 zx_ticks_get( ) -> u6415 pub fn zx_ticks_get( 16 ) -> u64; 17 zx_ticks_per_second( ) -> u6418 pub fn zx_ticks_per_second( 19 ) -> u64; 20 zx_deadline_after( nanoseconds: zx_duration_t ) -> zx_time_t21 pub fn zx_deadline_after( 22 nanoseconds: zx_duration_t 23 ) -> zx_time_t; 24 zx_clock_adjust( handle: zx_handle_t, clock_id: u32, offset: i64 ) -> zx_status_t25 pub fn zx_clock_adjust( 26 handle: zx_handle_t, 27 clock_id: u32, 28 offset: i64 29 ) -> zx_status_t; 30 zx_system_get_num_cpus( ) -> u3231 pub fn zx_system_get_num_cpus( 32 ) -> u32; 33 zx_system_get_version( version: *mut u8, version_len: u32 ) -> zx_status_t34 pub fn zx_system_get_version( 35 version: *mut u8, 36 version_len: u32 37 ) -> zx_status_t; 38 zx_system_get_physmem( ) -> u6439 pub fn zx_system_get_physmem( 40 ) -> u64; 41 zx_cache_flush( addr: *const u8, len: usize, options: u32 ) -> zx_status_t42 pub fn zx_cache_flush( 43 addr: *const u8, 44 len: usize, 45 options: u32 46 ) -> zx_status_t; 47 zx_handle_close( handle: zx_handle_t ) -> zx_status_t48 pub fn zx_handle_close( 49 handle: zx_handle_t 50 ) -> zx_status_t; 51 zx_handle_duplicate( handle: zx_handle_t, rights: zx_rights_t, out: *mut zx_handle_t ) -> zx_status_t52 pub fn zx_handle_duplicate( 53 handle: zx_handle_t, 54 rights: zx_rights_t, 55 out: *mut zx_handle_t 56 ) -> zx_status_t; 57 zx_handle_replace( handle: zx_handle_t, rights: zx_rights_t, out: *mut zx_handle_t ) -> zx_status_t58 pub fn zx_handle_replace( 59 handle: zx_handle_t, 60 rights: zx_rights_t, 61 out: *mut zx_handle_t 62 ) -> zx_status_t; 63 zx_object_wait_one( handle: zx_handle_t, waitfor: zx_signals_t, deadline: zx_time_t, observed: *mut zx_signals_t ) -> zx_status_t64 pub fn zx_object_wait_one( 65 handle: zx_handle_t, 66 waitfor: zx_signals_t, 67 deadline: zx_time_t, 68 observed: *mut zx_signals_t 69 ) -> zx_status_t; 70 zx_object_wait_many( items: *mut zx_wait_item_t, count: u32, deadline: zx_time_t ) -> zx_status_t71 pub fn zx_object_wait_many( 72 items: *mut zx_wait_item_t, 73 count: u32, 74 deadline: zx_time_t 75 ) -> zx_status_t; 76 zx_object_wait_async( handle: zx_handle_t, port_handle: zx_handle_t, key: u64, signals: zx_signals_t, options: u32 ) -> zx_status_t77 pub fn zx_object_wait_async( 78 handle: zx_handle_t, 79 port_handle: zx_handle_t, 80 key: u64, 81 signals: zx_signals_t, 82 options: u32 83 ) -> zx_status_t; 84 zx_object_signal( handle: zx_handle_t, clear_mask: u32, set_mask: u32 ) -> zx_status_t85 pub fn zx_object_signal( 86 handle: zx_handle_t, 87 clear_mask: u32, 88 set_mask: u32 89 ) -> zx_status_t; 90 zx_object_signal_peer( handle: zx_handle_t, clear_mask: u32, set_mask: u32 ) -> zx_status_t91 pub fn zx_object_signal_peer( 92 handle: zx_handle_t, 93 clear_mask: u32, 94 set_mask: u32 95 ) -> zx_status_t; 96 zx_object_get_property( handle: zx_handle_t, property: u32, value: *mut u8, size: usize ) -> zx_status_t97 pub fn zx_object_get_property( 98 handle: zx_handle_t, 99 property: u32, 100 value: *mut u8, 101 size: usize 102 ) -> zx_status_t; 103 zx_object_set_property( handle: zx_handle_t, property: u32, value: *const u8, size: usize ) -> zx_status_t104 pub fn zx_object_set_property( 105 handle: zx_handle_t, 106 property: u32, 107 value: *const u8, 108 size: usize 109 ) -> zx_status_t; 110 zx_object_set_cookie( handle: zx_handle_t, scope: zx_handle_t, cookie: u64 ) -> zx_status_t111 pub fn zx_object_set_cookie( 112 handle: zx_handle_t, 113 scope: zx_handle_t, 114 cookie: u64 115 ) -> zx_status_t; 116 zx_object_get_cookie( handle: zx_handle_t, scope: zx_handle_t, cookie: *mut u64 ) -> zx_status_t117 pub fn zx_object_get_cookie( 118 handle: zx_handle_t, 119 scope: zx_handle_t, 120 cookie: *mut u64 121 ) -> zx_status_t; 122 zx_object_get_info( handle: zx_handle_t, topic: u32, buffer: *mut u8, buffer_size: usize, actual_count: *mut usize, avail_count: *mut usize ) -> zx_status_t123 pub fn zx_object_get_info( 124 handle: zx_handle_t, 125 topic: u32, 126 buffer: *mut u8, 127 buffer_size: usize, 128 actual_count: *mut usize, 129 avail_count: *mut usize 130 ) -> zx_status_t; 131 zx_object_get_child( handle: zx_handle_t, koid: u64, rights: zx_rights_t, out: *mut zx_handle_t ) -> zx_status_t132 pub fn zx_object_get_child( 133 handle: zx_handle_t, 134 koid: u64, 135 rights: zx_rights_t, 136 out: *mut zx_handle_t 137 ) -> zx_status_t; 138 zx_channel_create( options: u32, out0: *mut zx_handle_t, out1: *mut zx_handle_t ) -> zx_status_t139 pub fn zx_channel_create( 140 options: u32, 141 out0: *mut zx_handle_t, 142 out1: *mut zx_handle_t 143 ) -> zx_status_t; 144 zx_channel_read( handle: zx_handle_t, options: u32, bytes: *mut u8, handles: *mut zx_handle_t, num_bytes: u32, num_handles: u32, actual_bytes: *mut u32, actual_handles: *mut u32 ) -> zx_status_t145 pub fn zx_channel_read( 146 handle: zx_handle_t, 147 options: u32, 148 bytes: *mut u8, 149 handles: *mut zx_handle_t, 150 num_bytes: u32, 151 num_handles: u32, 152 actual_bytes: *mut u32, 153 actual_handles: *mut u32 154 ) -> zx_status_t; 155 zx_channel_write( handle: zx_handle_t, options: u32, bytes: *const u8, num_bytes: u32, handles: *const zx_handle_t, num_handles: u32 ) -> zx_status_t156 pub fn zx_channel_write( 157 handle: zx_handle_t, 158 options: u32, 159 bytes: *const u8, 160 num_bytes: u32, 161 handles: *const zx_handle_t, 162 num_handles: u32 163 ) -> zx_status_t; 164 zx_channel_call_noretry( handle: zx_handle_t, options: u32, deadline: zx_time_t, args: *const zx_channel_call_args_t, actual_bytes: *mut u32, actual_handles: *mut u32, read_status: *mut zx_status_t ) -> zx_status_t165 pub fn zx_channel_call_noretry( 166 handle: zx_handle_t, 167 options: u32, 168 deadline: zx_time_t, 169 args: *const zx_channel_call_args_t, 170 actual_bytes: *mut u32, 171 actual_handles: *mut u32, 172 read_status: *mut zx_status_t 173 ) -> zx_status_t; 174 zx_channel_call_finish( deadline: zx_time_t, args: *const zx_channel_call_args_t, actual_bytes: *mut u32, actual_handles: *mut u32, read_status: *mut zx_status_t ) -> zx_status_t175 pub fn zx_channel_call_finish( 176 deadline: zx_time_t, 177 args: *const zx_channel_call_args_t, 178 actual_bytes: *mut u32, 179 actual_handles: *mut u32, 180 read_status: *mut zx_status_t 181 ) -> zx_status_t; 182 zx_channel_call( handle: zx_handle_t, options: u32, deadline: zx_time_t, args: *const zx_channel_call_args_t, actual_bytes: *mut u32, actual_handles: *mut u32, read_status: *mut zx_status_t ) -> zx_status_t183 pub fn zx_channel_call( 184 handle: zx_handle_t, 185 options: u32, 186 deadline: zx_time_t, 187 args: *const zx_channel_call_args_t, 188 actual_bytes: *mut u32, 189 actual_handles: *mut u32, 190 read_status: *mut zx_status_t 191 ) -> zx_status_t; 192 zx_socket_create( options: u32, out0: *mut zx_handle_t, out1: *mut zx_handle_t ) -> zx_status_t193 pub fn zx_socket_create( 194 options: u32, 195 out0: *mut zx_handle_t, 196 out1: *mut zx_handle_t 197 ) -> zx_status_t; 198 zx_socket_write( handle: zx_handle_t, options: u32, buffer: *const u8, size: usize, actual: *mut usize ) -> zx_status_t199 pub fn zx_socket_write( 200 handle: zx_handle_t, 201 options: u32, 202 buffer: *const u8, 203 size: usize, 204 actual: *mut usize 205 ) -> zx_status_t; 206 zx_socket_read( handle: zx_handle_t, options: u32, buffer: *mut u8, size: usize, actual: *mut usize ) -> zx_status_t207 pub fn zx_socket_read( 208 handle: zx_handle_t, 209 options: u32, 210 buffer: *mut u8, 211 size: usize, 212 actual: *mut usize 213 ) -> zx_status_t; 214 zx_thread_exit( )215 pub fn zx_thread_exit( 216 ); 217 zx_thread_create( process: zx_handle_t, name: *const u8, name_len: u32, options: u32, out: *mut zx_handle_t ) -> zx_status_t218 pub fn zx_thread_create( 219 process: zx_handle_t, 220 name: *const u8, 221 name_len: u32, 222 options: u32, 223 out: *mut zx_handle_t 224 ) -> zx_status_t; 225 zx_thread_start( handle: zx_handle_t, thread_entry: usize, stack: usize, arg1: usize, arg2: usize ) -> zx_status_t226 pub fn zx_thread_start( 227 handle: zx_handle_t, 228 thread_entry: usize, 229 stack: usize, 230 arg1: usize, 231 arg2: usize 232 ) -> zx_status_t; 233 zx_thread_read_state( handle: zx_handle_t, kind: u32, buffer: *mut u8, len: u32, actual: *mut u32 ) -> zx_status_t234 pub fn zx_thread_read_state( 235 handle: zx_handle_t, 236 kind: u32, 237 buffer: *mut u8, 238 len: u32, 239 actual: *mut u32 240 ) -> zx_status_t; 241 zx_thread_write_state( handle: zx_handle_t, kind: u32, buffer: *const u8, buffer_len: u32 ) -> zx_status_t242 pub fn zx_thread_write_state( 243 handle: zx_handle_t, 244 kind: u32, 245 buffer: *const u8, 246 buffer_len: u32 247 ) -> zx_status_t; 248 zx_thread_set_priority( prio: i32 ) -> zx_status_t249 pub fn zx_thread_set_priority( 250 prio: i32 251 ) -> zx_status_t; 252 zx_process_exit( retcode: isize )253 pub fn zx_process_exit( 254 retcode: isize 255 ); 256 zx_process_create( job: zx_handle_t, name: *const u8, name_len: u32, options: u32, proc_handle: *mut zx_handle_t, vmar_handle: *mut zx_handle_t ) -> zx_status_t257 pub fn zx_process_create( 258 job: zx_handle_t, 259 name: *const u8, 260 name_len: u32, 261 options: u32, 262 proc_handle: *mut zx_handle_t, 263 vmar_handle: *mut zx_handle_t 264 ) -> zx_status_t; 265 zx_process_start( process_handle: zx_handle_t, thread_handle: zx_handle_t, entry: usize, stack: usize, arg_handle: zx_handle_t, arg2: usize ) -> zx_status_t266 pub fn zx_process_start( 267 process_handle: zx_handle_t, 268 thread_handle: zx_handle_t, 269 entry: usize, 270 stack: usize, 271 arg_handle: zx_handle_t, 272 arg2: usize 273 ) -> zx_status_t; 274 zx_process_read_memory( proc_: zx_handle_t, vaddr: usize, buffer: *mut u8, len: usize, actual: *mut usize ) -> zx_status_t275 pub fn zx_process_read_memory( 276 proc_: zx_handle_t, 277 vaddr: usize, 278 buffer: *mut u8, 279 len: usize, 280 actual: *mut usize 281 ) -> zx_status_t; 282 zx_process_write_memory( proc_: zx_handle_t, vaddr: usize, buffer: *const u8, len: usize, actual: *mut usize ) -> zx_status_t283 pub fn zx_process_write_memory( 284 proc_: zx_handle_t, 285 vaddr: usize, 286 buffer: *const u8, 287 len: usize, 288 actual: *mut usize 289 ) -> zx_status_t; 290 zx_job_create( parent_job: zx_handle_t, options: u32, out: *mut zx_handle_t ) -> zx_status_t291 pub fn zx_job_create( 292 parent_job: zx_handle_t, 293 options: u32, 294 out: *mut zx_handle_t 295 ) -> zx_status_t; 296 zx_job_set_policy( job: zx_handle_t, options: u32, topic: u32, policy: *const u8, count: u32 ) -> zx_status_t297 pub fn zx_job_set_policy( 298 job: zx_handle_t, 299 options: u32, 300 topic: u32, 301 policy: *const u8, 302 count: u32 303 ) -> zx_status_t; 304 zx_task_bind_exception_port( object: zx_handle_t, eport: zx_handle_t, key: u64, options: u32 ) -> zx_status_t305 pub fn zx_task_bind_exception_port( 306 object: zx_handle_t, 307 eport: zx_handle_t, 308 key: u64, 309 options: u32 310 ) -> zx_status_t; 311 zx_task_suspend( task_handle: zx_handle_t ) -> zx_status_t312 pub fn zx_task_suspend( 313 task_handle: zx_handle_t 314 ) -> zx_status_t; 315 zx_task_resume( task_handle: zx_handle_t, options: u32 ) -> zx_status_t316 pub fn zx_task_resume( 317 task_handle: zx_handle_t, 318 options: u32 319 ) -> zx_status_t; 320 zx_task_kill( task_handle: zx_handle_t ) -> zx_status_t321 pub fn zx_task_kill( 322 task_handle: zx_handle_t 323 ) -> zx_status_t; 324 zx_event_create( options: u32, out: *mut zx_handle_t ) -> zx_status_t325 pub fn zx_event_create( 326 options: u32, 327 out: *mut zx_handle_t 328 ) -> zx_status_t; 329 zx_eventpair_create( options: u32, out0: *mut zx_handle_t, out1: *mut zx_handle_t ) -> zx_status_t330 pub fn zx_eventpair_create( 331 options: u32, 332 out0: *mut zx_handle_t, 333 out1: *mut zx_handle_t 334 ) -> zx_status_t; 335 zx_futex_wait( value_ptr: *mut zx_futex_t, current_value: isize, deadline: zx_time_t ) -> zx_status_t336 pub fn zx_futex_wait( 337 value_ptr: *mut zx_futex_t, 338 current_value: isize, 339 deadline: zx_time_t 340 ) -> zx_status_t; 341 zx_futex_wake( value_ptr: *const zx_futex_t, count: u32 ) -> zx_status_t342 pub fn zx_futex_wake( 343 value_ptr: *const zx_futex_t, 344 count: u32 345 ) -> zx_status_t; 346 zx_futex_requeue( wake_ptr: *mut zx_futex_t, wake_count: u32, current_value: isize, requeue_ptr: *mut zx_futex_t, requeue_count: u32 ) -> zx_status_t347 pub fn zx_futex_requeue( 348 wake_ptr: *mut zx_futex_t, 349 wake_count: u32, 350 current_value: isize, 351 requeue_ptr: *mut zx_futex_t, 352 requeue_count: u32 353 ) -> zx_status_t; 354 zx_port_create( options: u32, out: *mut zx_handle_t ) -> zx_status_t355 pub fn zx_port_create( 356 options: u32, 357 out: *mut zx_handle_t 358 ) -> zx_status_t; 359 zx_port_queue( handle: zx_handle_t, packet: *const zx_port_packet_t, size: usize ) -> zx_status_t360 pub fn zx_port_queue( 361 handle: zx_handle_t, 362 packet: *const zx_port_packet_t, 363 size: usize 364 ) -> zx_status_t; 365 zx_port_wait( handle: zx_handle_t, deadline: zx_time_t, packet: *mut zx_port_packet_t, size: usize ) -> zx_status_t366 pub fn zx_port_wait( 367 handle: zx_handle_t, 368 deadline: zx_time_t, 369 packet: *mut zx_port_packet_t, 370 size: usize 371 ) -> zx_status_t; 372 zx_port_cancel( handle: zx_handle_t, source: zx_handle_t, key: u64 ) -> zx_status_t373 pub fn zx_port_cancel( 374 handle: zx_handle_t, 375 source: zx_handle_t, 376 key: u64 377 ) -> zx_status_t; 378 zx_timer_create( options: u32, clock_id: u32, out: *mut zx_handle_t ) -> zx_status_t379 pub fn zx_timer_create( 380 options: u32, 381 clock_id: u32, 382 out: *mut zx_handle_t 383 ) -> zx_status_t; 384 zx_timer_set( handle: zx_handle_t, deadline: zx_time_t, slack: zx_duration_t ) -> zx_status_t385 pub fn zx_timer_set( 386 handle: zx_handle_t, 387 deadline: zx_time_t, 388 slack: zx_duration_t 389 ) -> zx_status_t; 390 zx_timer_cancel( handle: zx_handle_t ) -> zx_status_t391 pub fn zx_timer_cancel( 392 handle: zx_handle_t 393 ) -> zx_status_t; 394 zx_vmo_create( size: u64, options: u32, out: *mut zx_handle_t ) -> zx_status_t395 pub fn zx_vmo_create( 396 size: u64, 397 options: u32, 398 out: *mut zx_handle_t 399 ) -> zx_status_t; 400 zx_vmo_read( handle: zx_handle_t, data: *mut u8, offset: u64, len: usize, actual: *mut usize ) -> zx_status_t401 pub fn zx_vmo_read( 402 handle: zx_handle_t, 403 data: *mut u8, 404 offset: u64, 405 len: usize, 406 actual: *mut usize 407 ) -> zx_status_t; 408 zx_vmo_write( handle: zx_handle_t, data: *const u8, offset: u64, len: usize, actual: *mut usize ) -> zx_status_t409 pub fn zx_vmo_write( 410 handle: zx_handle_t, 411 data: *const u8, 412 offset: u64, 413 len: usize, 414 actual: *mut usize 415 ) -> zx_status_t; 416 zx_vmo_get_size( handle: zx_handle_t, size: *mut u64 ) -> zx_status_t417 pub fn zx_vmo_get_size( 418 handle: zx_handle_t, 419 size: *mut u64 420 ) -> zx_status_t; 421 zx_vmo_set_size( handle: zx_handle_t, size: u64 ) -> zx_status_t422 pub fn zx_vmo_set_size( 423 handle: zx_handle_t, 424 size: u64 425 ) -> zx_status_t; 426 zx_vmo_op_range( handle: zx_handle_t, op: u32, offset: u64, size: u64, buffer: *mut u8, buffer_size: usize ) -> zx_status_t427 pub fn zx_vmo_op_range( 428 handle: zx_handle_t, 429 op: u32, 430 offset: u64, 431 size: u64, 432 buffer: *mut u8, 433 buffer_size: usize 434 ) -> zx_status_t; 435 zx_vmo_clone( handle: zx_handle_t, options: u32, offset: u64, size: u64, out: *mut zx_handle_t ) -> zx_status_t436 pub fn zx_vmo_clone( 437 handle: zx_handle_t, 438 options: u32, 439 offset: u64, 440 size: u64, 441 out: *mut zx_handle_t 442 ) -> zx_status_t; 443 zx_vmo_set_cache_policy( handle: zx_handle_t, cache_policy: u32 ) -> zx_status_t444 pub fn zx_vmo_set_cache_policy( 445 handle: zx_handle_t, 446 cache_policy: u32 447 ) -> zx_status_t; 448 zx_vmar_allocate( parent_vmar_handle: zx_handle_t, offset: usize, size: usize, map_flags: u32, child_vmar: *mut zx_handle_t, child_addr: *mut usize ) -> zx_status_t449 pub fn zx_vmar_allocate( 450 parent_vmar_handle: zx_handle_t, 451 offset: usize, 452 size: usize, 453 map_flags: u32, 454 child_vmar: *mut zx_handle_t, 455 child_addr: *mut usize 456 ) -> zx_status_t; 457 zx_vmar_destroy( vmar_handle: zx_handle_t ) -> zx_status_t458 pub fn zx_vmar_destroy( 459 vmar_handle: zx_handle_t 460 ) -> zx_status_t; 461 zx_vmar_map( vmar_handle: zx_handle_t, vmar_offset: usize, vmo_handle: zx_handle_t, vmo_offset: u64, len: usize, map_flags: u32, mapped_addr: *mut usize ) -> zx_status_t462 pub fn zx_vmar_map( 463 vmar_handle: zx_handle_t, 464 vmar_offset: usize, 465 vmo_handle: zx_handle_t, 466 vmo_offset: u64, 467 len: usize, 468 map_flags: u32, 469 mapped_addr: *mut usize 470 ) -> zx_status_t; 471 zx_vmar_unmap( vmar_handle: zx_handle_t, addr: usize, len: usize ) -> zx_status_t472 pub fn zx_vmar_unmap( 473 vmar_handle: zx_handle_t, 474 addr: usize, 475 len: usize 476 ) -> zx_status_t; 477 zx_vmar_protect( vmar_handle: zx_handle_t, addr: usize, len: usize, prot_flags: u32 ) -> zx_status_t478 pub fn zx_vmar_protect( 479 vmar_handle: zx_handle_t, 480 addr: usize, 481 len: usize, 482 prot_flags: u32 483 ) -> zx_status_t; 484 zx_vmar_root_self() -> zx_handle_t485 pub fn zx_vmar_root_self() -> zx_handle_t; 486 zx_cprng_draw( buffer: *mut u8, len: usize, actual: *mut usize ) -> zx_status_t487 pub fn zx_cprng_draw( 488 buffer: *mut u8, 489 len: usize, 490 actual: *mut usize 491 ) -> zx_status_t; 492 zx_cprng_add_entropy( buffer: *const u8, len: usize ) -> zx_status_t493 pub fn zx_cprng_add_entropy( 494 buffer: *const u8, 495 len: usize 496 ) -> zx_status_t; 497 zx_fifo_create( elem_count: u32, elem_size: u32, options: u32, out0: *mut zx_handle_t, out1: *mut zx_handle_t ) -> zx_status_t498 pub fn zx_fifo_create( 499 elem_count: u32, 500 elem_size: u32, 501 options: u32, 502 out0: *mut zx_handle_t, 503 out1: *mut zx_handle_t 504 ) -> zx_status_t; 505 zx_fifo_read( handle: zx_handle_t, data: *mut u8, len: usize, num_written: *mut u32 ) -> zx_status_t506 pub fn zx_fifo_read( 507 handle: zx_handle_t, 508 data: *mut u8, 509 len: usize, 510 num_written: *mut u32 511 ) -> zx_status_t; 512 zx_fifo_write( handle: zx_handle_t, data: *const u8, len: usize, num_written: *mut u32 ) -> zx_status_t513 pub fn zx_fifo_write( 514 handle: zx_handle_t, 515 data: *const u8, 516 len: usize, 517 num_written: *mut u32 518 ) -> zx_status_t; 519 zx_vmar_unmap_handle_close_thread_exit( vmar_handle: zx_handle_t, addr: usize, len: usize, handle: zx_handle_t ) -> zx_status_t520 pub fn zx_vmar_unmap_handle_close_thread_exit( 521 vmar_handle: zx_handle_t, 522 addr: usize, 523 len: usize, 524 handle: zx_handle_t 525 ) -> zx_status_t; 526 zx_futex_wake_handle_close_thread_exit( value_ptr: *const zx_futex_t, count: u32, new_value: isize, handle: zx_handle_t )527 pub fn zx_futex_wake_handle_close_thread_exit( 528 value_ptr: *const zx_futex_t, 529 count: u32, 530 new_value: isize, 531 handle: zx_handle_t 532 ); 533 zx_log_create( options: u32, out: *mut zx_handle_t ) -> zx_status_t534 pub fn zx_log_create( 535 options: u32, 536 out: *mut zx_handle_t 537 ) -> zx_status_t; 538 zx_log_write( handle: zx_handle_t, len: u32, buffer: *const u8, options: u32 ) -> zx_status_t539 pub fn zx_log_write( 540 handle: zx_handle_t, 541 len: u32, 542 buffer: *const u8, 543 options: u32 544 ) -> zx_status_t; 545 zx_log_read( handle: zx_handle_t, len: u32, buffer: *mut u8, options: u32 ) -> zx_status_t546 pub fn zx_log_read( 547 handle: zx_handle_t, 548 len: u32, 549 buffer: *mut u8, 550 options: u32 551 ) -> zx_status_t; 552 zx_ktrace_read( handle: zx_handle_t, data: *mut u8, offset: u32, len: u32, actual: *mut u32 ) -> zx_status_t553 pub fn zx_ktrace_read( 554 handle: zx_handle_t, 555 data: *mut u8, 556 offset: u32, 557 len: u32, 558 actual: *mut u32 559 ) -> zx_status_t; 560 zx_ktrace_control( handle: zx_handle_t, action: u32, options: u32, ptr: *mut u8 ) -> zx_status_t561 pub fn zx_ktrace_control( 562 handle: zx_handle_t, 563 action: u32, 564 options: u32, 565 ptr: *mut u8 566 ) -> zx_status_t; 567 zx_ktrace_write( handle: zx_handle_t, id: u32, arg0: u32, arg1: u32 ) -> zx_status_t568 pub fn zx_ktrace_write( 569 handle: zx_handle_t, 570 id: u32, 571 arg0: u32, 572 arg1: u32 573 ) -> zx_status_t; 574 zx_mtrace_control( handle: zx_handle_t, kind: u32, action: u32, options: u32, ptr: *mut u8, size: u32 ) -> zx_status_t575 pub fn zx_mtrace_control( 576 handle: zx_handle_t, 577 kind: u32, 578 action: u32, 579 options: u32, 580 ptr: *mut u8, 581 size: u32 582 ) -> zx_status_t; 583 zx_debug_read( handle: zx_handle_t, buffer: *mut u8, length: u32 ) -> zx_status_t584 pub fn zx_debug_read( 585 handle: zx_handle_t, 586 buffer: *mut u8, 587 length: u32 588 ) -> zx_status_t; 589 zx_debug_write( buffer: *const u8, length: u32 ) -> zx_status_t590 pub fn zx_debug_write( 591 buffer: *const u8, 592 length: u32 593 ) -> zx_status_t; 594 zx_debug_send_command( resource_handle: zx_handle_t, buffer: *const u8, length: u32 ) -> zx_status_t595 pub fn zx_debug_send_command( 596 resource_handle: zx_handle_t, 597 buffer: *const u8, 598 length: u32 599 ) -> zx_status_t; 600 zx_interrupt_create( handle: zx_handle_t, vector: u32, options: u32, out_handle: *mut zx_handle_t ) -> zx_status_t601 pub fn zx_interrupt_create( 602 handle: zx_handle_t, 603 vector: u32, 604 options: u32, 605 out_handle: *mut zx_handle_t 606 ) -> zx_status_t; 607 zx_interrupt_complete( handle: zx_handle_t ) -> zx_status_t608 pub fn zx_interrupt_complete( 609 handle: zx_handle_t 610 ) -> zx_status_t; 611 zx_interrupt_wait( handle: zx_handle_t ) -> zx_status_t612 pub fn zx_interrupt_wait( 613 handle: zx_handle_t 614 ) -> zx_status_t; 615 zx_interrupt_signal( handle: zx_handle_t ) -> zx_status_t616 pub fn zx_interrupt_signal( 617 handle: zx_handle_t 618 ) -> zx_status_t; 619 zx_mmap_device_io( handle: zx_handle_t, io_addr: u32, len: u32 ) -> zx_status_t620 pub fn zx_mmap_device_io( 621 handle: zx_handle_t, 622 io_addr: u32, 623 len: u32 624 ) -> zx_status_t; 625 zx_vmo_create_contiguous( rsrc_handle: zx_handle_t, size: usize, alignment_log2: u32, out: *mut zx_handle_t ) -> zx_status_t626 pub fn zx_vmo_create_contiguous( 627 rsrc_handle: zx_handle_t, 628 size: usize, 629 alignment_log2: u32, 630 out: *mut zx_handle_t 631 ) -> zx_status_t; 632 zx_vmo_create_physical( rsrc_handle: zx_handle_t, paddr: zx_paddr_t, size: usize, out: *mut zx_handle_t ) -> zx_status_t633 pub fn zx_vmo_create_physical( 634 rsrc_handle: zx_handle_t, 635 paddr: zx_paddr_t, 636 size: usize, 637 out: *mut zx_handle_t 638 ) -> zx_status_t; 639 zx_bootloader_fb_get_info( format: *mut u32, width: *mut u32, height: *mut u32, stride: *mut u32 ) -> zx_status_t640 pub fn zx_bootloader_fb_get_info( 641 format: *mut u32, 642 width: *mut u32, 643 height: *mut u32, 644 stride: *mut u32 645 ) -> zx_status_t; 646 zx_set_framebuffer( handle: zx_handle_t, vaddr: *mut u8, len: u32, format: u32, width: u32, height: u32, stride: u32 ) -> zx_status_t647 pub fn zx_set_framebuffer( 648 handle: zx_handle_t, 649 vaddr: *mut u8, 650 len: u32, 651 format: u32, 652 width: u32, 653 height: u32, 654 stride: u32 655 ) -> zx_status_t; 656 zx_set_framebuffer_vmo( handle: zx_handle_t, vmo: zx_handle_t, len: u32, format: u32, width: u32, height: u32, stride: u32 ) -> zx_status_t657 pub fn zx_set_framebuffer_vmo( 658 handle: zx_handle_t, 659 vmo: zx_handle_t, 660 len: u32, 661 format: u32, 662 width: u32, 663 height: u32, 664 stride: u32 665 ) -> zx_status_t; 666 zx_pci_get_nth_device( handle: zx_handle_t, index: u32, out_info: *mut zx_pcie_device_info_t, out_handle: *mut zx_handle_t ) -> zx_status_t667 pub fn zx_pci_get_nth_device( 668 handle: zx_handle_t, 669 index: u32, 670 out_info: *mut zx_pcie_device_info_t, 671 out_handle: *mut zx_handle_t 672 ) -> zx_status_t; 673 zx_pci_enable_bus_master( handle: zx_handle_t, enable: bool ) -> zx_status_t674 pub fn zx_pci_enable_bus_master( 675 handle: zx_handle_t, 676 enable: bool 677 ) -> zx_status_t; 678 zx_pci_enable_pio( handle: zx_handle_t, enable: bool ) -> zx_status_t679 pub fn zx_pci_enable_pio( 680 handle: zx_handle_t, 681 enable: bool 682 ) -> zx_status_t; 683 zx_pci_reset_device( handle: zx_handle_t ) -> zx_status_t684 pub fn zx_pci_reset_device( 685 handle: zx_handle_t 686 ) -> zx_status_t; 687 zx_pci_cfg_pio_rw( handle: zx_handle_t, bus: u8, dev: u8, func: u8, offset: u8, val: *mut u32, width: usize, write: bool ) -> zx_status_t688 pub fn zx_pci_cfg_pio_rw( 689 handle: zx_handle_t, 690 bus: u8, 691 dev: u8, 692 func: u8, 693 offset: u8, 694 val: *mut u32, 695 width: usize, 696 write: bool 697 ) -> zx_status_t; 698 zx_pci_get_bar( handle: zx_handle_t, bar_num: u32, out_bar: *mut zx_pci_resource_t ) -> zx_status_t699 pub fn zx_pci_get_bar( 700 handle: zx_handle_t, 701 bar_num: u32, 702 out_bar: *mut zx_pci_resource_t 703 ) -> zx_status_t; 704 zx_pci_get_config( handle: zx_handle_t, out_config: *mut zx_pci_resource_t ) -> zx_status_t705 pub fn zx_pci_get_config( 706 handle: zx_handle_t, 707 out_config: *mut zx_pci_resource_t 708 ) -> zx_status_t; 709 zx_pci_io_write( handle: zx_handle_t, bar_num: u32, offset: u32, len: u32, value: u32 ) -> zx_status_t710 pub fn zx_pci_io_write( 711 handle: zx_handle_t, 712 bar_num: u32, 713 offset: u32, 714 len: u32, 715 value: u32 716 ) -> zx_status_t; 717 zx_pci_io_read( handle: zx_handle_t, bar_num: u32, offset: u32, len: u32, out_value: *mut u32 ) -> zx_status_t718 pub fn zx_pci_io_read( 719 handle: zx_handle_t, 720 bar_num: u32, 721 offset: u32, 722 len: u32, 723 out_value: *mut u32 724 ) -> zx_status_t; 725 zx_pci_map_interrupt( handle: zx_handle_t, which_irq: i32, out_handle: *mut zx_handle_t ) -> zx_status_t726 pub fn zx_pci_map_interrupt( 727 handle: zx_handle_t, 728 which_irq: i32, 729 out_handle: *mut zx_handle_t 730 ) -> zx_status_t; 731 zx_pci_query_irq_mode_caps( handle: zx_handle_t, mode: u32, out_max_irqs: *mut u32 ) -> zx_status_t732 pub fn zx_pci_query_irq_mode_caps( 733 handle: zx_handle_t, 734 mode: u32, 735 out_max_irqs: *mut u32 736 ) -> zx_status_t; 737 zx_pci_set_irq_mode( handle: zx_handle_t, mode: u32, requested_irq_count: u32 ) -> zx_status_t738 pub fn zx_pci_set_irq_mode( 739 handle: zx_handle_t, 740 mode: u32, 741 requested_irq_count: u32 742 ) -> zx_status_t; 743 zx_pci_init( handle: zx_handle_t, init_buf: *const zx_pci_init_arg_t, len: u32 ) -> zx_status_t744 pub fn zx_pci_init( 745 handle: zx_handle_t, 746 init_buf: *const zx_pci_init_arg_t, 747 len: u32 748 ) -> zx_status_t; 749 zx_pci_add_subtract_io_range( handle: zx_handle_t, mmio: bool, base: u64, len: u64, add: bool ) -> zx_status_t750 pub fn zx_pci_add_subtract_io_range( 751 handle: zx_handle_t, 752 mmio: bool, 753 base: u64, 754 len: u64, 755 add: bool 756 ) -> zx_status_t; 757 zx_acpi_uefi_rsdp( handle: zx_handle_t ) -> u64758 pub fn zx_acpi_uefi_rsdp( 759 handle: zx_handle_t 760 ) -> u64; 761 zx_acpi_cache_flush( handle: zx_handle_t ) -> zx_status_t762 pub fn zx_acpi_cache_flush( 763 handle: zx_handle_t 764 ) -> zx_status_t; 765 zx_resource_create( parent_handle: zx_handle_t, kind: u32, low: u64, high: u64, resource_out: *mut zx_handle_t ) -> zx_status_t766 pub fn zx_resource_create( 767 parent_handle: zx_handle_t, 768 kind: u32, 769 low: u64, 770 high: u64, 771 resource_out: *mut zx_handle_t 772 ) -> zx_status_t; 773 zx_guest_create( resource: zx_handle_t, options: u32, physmem_vmo: zx_handle_t, out: *mut zx_handle_t ) -> zx_status_t774 pub fn zx_guest_create( 775 resource: zx_handle_t, 776 options: u32, 777 physmem_vmo: zx_handle_t, 778 out: *mut zx_handle_t 779 ) -> zx_status_t; 780 zx_guest_set_trap( guest: zx_handle_t, kind: u32, addr: zx_vaddr_t, len: usize, fifo: zx_handle_t ) -> zx_status_t781 pub fn zx_guest_set_trap( 782 guest: zx_handle_t, 783 kind: u32, 784 addr: zx_vaddr_t, 785 len: usize, 786 fifo: zx_handle_t 787 ) -> zx_status_t; 788 zx_vcpu_create( guest: zx_handle_t, options: u32, args: *const zx_vcpu_create_args_t, out: *mut zx_handle_t ) -> zx_status_t789 pub fn zx_vcpu_create( 790 guest: zx_handle_t, 791 options: u32, 792 args: *const zx_vcpu_create_args_t, 793 out: *mut zx_handle_t 794 ) -> zx_status_t; 795 zx_vcpu_resume( vcpu: zx_handle_t, packet: *mut zx_guest_packet_t ) -> zx_status_t796 pub fn zx_vcpu_resume( 797 vcpu: zx_handle_t, 798 packet: *mut zx_guest_packet_t 799 ) -> zx_status_t; 800 zx_vcpu_interrupt( vcpu: zx_handle_t, vector: u32 ) -> zx_status_t801 pub fn zx_vcpu_interrupt( 802 vcpu: zx_handle_t, 803 vector: u32 804 ) -> zx_status_t; 805 zx_vcpu_read_state( vcpu: zx_handle_t, kind: u32, buffer: *mut u8, len: u32 ) -> zx_status_t806 pub fn zx_vcpu_read_state( 807 vcpu: zx_handle_t, 808 kind: u32, 809 buffer: *mut u8, 810 len: u32 811 ) -> zx_status_t; 812 zx_vcpu_write_state( vcpu: zx_handle_t, kind: u32, buffer: *const u8, len: u32 ) -> zx_status_t813 pub fn zx_vcpu_write_state( 814 vcpu: zx_handle_t, 815 kind: u32, 816 buffer: *const u8, 817 len: u32 818 ) -> zx_status_t; 819 zx_system_mexec( kernel: zx_handle_t, bootimage: zx_handle_t, cmdline: *const u8, cmdline_len: u32 ) -> zx_status_t820 pub fn zx_system_mexec( 821 kernel: zx_handle_t, 822 bootimage: zx_handle_t, 823 cmdline: *const u8, 824 cmdline_len: u32 825 ) -> zx_status_t; 826 zx_job_set_relative_importance( root_resource: zx_handle_t, job: zx_handle_t, less_important_job: zx_handle_t ) -> zx_status_t827 pub fn zx_job_set_relative_importance( 828 root_resource: zx_handle_t, 829 job: zx_handle_t, 830 less_important_job: zx_handle_t 831 ) -> zx_status_t; 832 zx_syscall_test_0( ) -> zx_status_t833 pub fn zx_syscall_test_0( 834 ) -> zx_status_t; 835 zx_syscall_test_1( a: isize ) -> zx_status_t836 pub fn zx_syscall_test_1( 837 a: isize 838 ) -> zx_status_t; 839 zx_syscall_test_2( a: isize, b: isize ) -> zx_status_t840 pub fn zx_syscall_test_2( 841 a: isize, 842 b: isize 843 ) -> zx_status_t; 844 zx_syscall_test_3( a: isize, b: isize, c: isize ) -> zx_status_t845 pub fn zx_syscall_test_3( 846 a: isize, 847 b: isize, 848 c: isize 849 ) -> zx_status_t; 850 zx_syscall_test_4( a: isize, b: isize, c: isize, d: isize ) -> zx_status_t851 pub fn zx_syscall_test_4( 852 a: isize, 853 b: isize, 854 c: isize, 855 d: isize 856 ) -> zx_status_t; 857 zx_syscall_test_5( a: isize, b: isize, c: isize, d: isize, e: isize ) -> zx_status_t858 pub fn zx_syscall_test_5( 859 a: isize, 860 b: isize, 861 c: isize, 862 d: isize, 863 e: isize 864 ) -> zx_status_t; 865 zx_syscall_test_6( a: isize, b: isize, c: isize, d: isize, e: isize, f: isize ) -> zx_status_t866 pub fn zx_syscall_test_6( 867 a: isize, 868 b: isize, 869 c: isize, 870 d: isize, 871 e: isize, 872 f: isize 873 ) -> zx_status_t; 874 zx_syscall_test_7( a: isize, b: isize, c: isize, d: isize, e: isize, f: isize, g: isize ) -> zx_status_t875 pub fn zx_syscall_test_7( 876 a: isize, 877 b: isize, 878 c: isize, 879 d: isize, 880 e: isize, 881 f: isize, 882 g: isize 883 ) -> zx_status_t; 884 zx_syscall_test_8( a: isize, b: isize, c: isize, d: isize, e: isize, f: isize, g: isize, h: isize ) -> zx_status_t885 pub fn zx_syscall_test_8( 886 a: isize, 887 b: isize, 888 c: isize, 889 d: isize, 890 e: isize, 891 f: isize, 892 g: isize, 893 h: isize 894 ) -> zx_status_t; 895 zx_syscall_test_wrapper( a: isize, b: isize, c: isize ) -> zx_status_t896 pub fn zx_syscall_test_wrapper( 897 a: isize, 898 b: isize, 899 c: isize 900 ) -> zx_status_t; 901 902 903 } 904