Lines Matching refs:op

341 int efi_runtime_call(struct xenpf_efi_runtime_call *op)  in efi_runtime_call()  argument
354 switch ( op->function ) in efi_runtime_call()
360 if ( op->misc ) in efi_runtime_call()
367 status = efi_rs->GetTime(cast_time(&op->u.get_time.time), &caps); in efi_runtime_call()
373 op->u.get_time.resolution = caps.Resolution; in efi_runtime_call()
374 op->u.get_time.accuracy = caps.Accuracy; in efi_runtime_call()
376 op->misc = XEN_EFI_GET_TIME_SET_CLEARS_NS; in efi_runtime_call()
382 if ( op->misc ) in efi_runtime_call()
389 status = efi_rs->SetTime(cast_time(&op->u.set_time)); in efi_runtime_call()
398 if ( op->misc ) in efi_runtime_call()
406 cast_time(&op->u.get_wakeup_time)); in efi_runtime_call()
413 op->misc |= XEN_EFI_GET_WAKEUP_TIME_ENABLED; in efi_runtime_call()
415 op->misc |= XEN_EFI_GET_WAKEUP_TIME_PENDING; in efi_runtime_call()
421 if ( op->misc & ~(XEN_EFI_SET_WAKEUP_TIME_ENABLE | in efi_runtime_call()
429 status = efi_rs->SetWakeupTime(!!(op->misc & in efi_runtime_call()
431 (op->misc & in efi_runtime_call()
434 cast_time(&op->u.set_wakeup_time)); in efi_runtime_call()
438 op->misc = 0; in efi_runtime_call()
442 if ( op->misc ) in efi_runtime_call()
447 status = efi_rs->GetNextHighMonotonicCount(&op->misc); in efi_runtime_call()
460 if ( op->misc ) in efi_runtime_call()
463 len = gwstrlen(guest_handle_cast(op->u.get_variable.name, CHAR16)); in efi_runtime_call()
469 __copy_from_guest(name, op->u.get_variable.name, len); in efi_runtime_call()
471 size = op->u.get_variable.size; in efi_runtime_call()
488 name, cast_guid(&op->u.get_variable.vendor_guid), in efi_runtime_call()
489 &op->misc, &size, data); in efi_runtime_call()
493 copy_to_guest(op->u.get_variable.data, data, size) ) in efi_runtime_call()
495 op->u.get_variable.size = size; in efi_runtime_call()
511 len = gwstrlen(guest_handle_cast(op->u.set_variable.name, CHAR16)); in efi_runtime_call()
517 __copy_from_guest(name, op->u.set_variable.name, len); in efi_runtime_call()
519 data = xmalloc_bytes(op->u.set_variable.size); in efi_runtime_call()
522 else if ( copy_from_guest(data, op->u.set_variable.data, in efi_runtime_call()
523 op->u.set_variable.size) ) in efi_runtime_call()
530 name, cast_guid(&op->u.set_variable.vendor_guid), in efi_runtime_call()
531 op->misc, op->u.set_variable.size, data); in efi_runtime_call()
550 if ( op->misc ) in efi_runtime_call()
553 size = op->u.get_next_variable_name.size; in efi_runtime_call()
557 if ( copy_from_guest(name.raw, op->u.get_next_variable_name.name, in efi_runtime_call()
569 cast_guid(&op->u.get_next_variable_name.vendor_guid)); in efi_runtime_call()
577 __copy_to_guest(op->u.get_next_variable_name.name, in efi_runtime_call()
578 name.raw, op->u.get_next_variable_name.size) ) in efi_runtime_call()
580 op->u.get_next_variable_name.size = size; in efi_runtime_call()
590 if ( op->misc & ~XEN_EFI_VARINFO_BOOT_SNAPSHOT ) in efi_runtime_call()
593 if ( op->misc & XEN_EFI_VARINFO_BOOT_SNAPSHOT ) in efi_runtime_call()
595 if ( (op->u.query_variable_info.attr in efi_runtime_call()
602 op->u.query_variable_info.max_store_size = in efi_runtime_call()
604 op->u.query_variable_info.remain_store_size = in efi_runtime_call()
608 op->u.query_variable_info.max_size = efi_boot_max_var_size; in efi_runtime_call()
613 op->u.query_variable_info.max_size = 0; in efi_runtime_call()
626 op->u.query_variable_info.attr, in efi_runtime_call()
627 &op->u.query_variable_info.max_store_size, in efi_runtime_call()
628 &op->u.query_variable_info.remain_store_size, in efi_runtime_call()
629 &op->u.query_variable_info.max_size); in efi_runtime_call()
635 if ( op->misc ) in efi_runtime_call()
651 op->status = status; in efi_runtime_call()
653 op->status = (status & 0x3fffffff) | ((status >> 32) & 0xc0000000); in efi_runtime_call()