File tree Expand file tree Collapse file tree 2 files changed +29
-5
lines changed Expand file tree Collapse file tree 2 files changed +29
-5
lines changed Original file line number Diff line number Diff line change @@ -61,11 +61,11 @@ impl<'boot> Pointer<'boot> {
6161#[ derive( Debug , Copy , Clone ) ]
6262#[ repr( C ) ]
6363pub struct PointerMode {
64- // The pointer device's resolution on the X/Y/Z axis in counts/mm.
65- // If a value is 0, then the device does _not_ support that axis.
66- resolution : ( u64 , u64 , u64 ) ,
64+ /// The pointer device's resolution on the X/Y/Z axis in counts/mm.
65+ /// If a value is 0, then the device does _not_ support that axis.
66+ pub resolution : ( u64 , u64 , u64 ) ,
6767 /// Whether the devices has a left button / right button.
68- has_button : ( bool , bool ) ,
68+ pub has_button : ( bool , bool ) ,
6969}
7070
7171/// The relative change in the pointer's state.
Original file line number Diff line number Diff line change @@ -96,7 +96,12 @@ pub struct BootServices {
9696 exit_data_size : * mut usize ,
9797 exit_data : & mut * mut Char16 ,
9898 ) -> Status ,
99- exit : usize ,
99+ exit : extern "efiapi" fn (
100+ image_handle : Handle ,
101+ exit_status : Status ,
102+ exit_data_size : usize ,
103+ exit_data : * mut Char16 ,
104+ ) -> !,
100105 unload_image : extern "efiapi" fn ( image_handle : Handle ) -> Status ,
101106 exit_boot_services :
102107 unsafe extern "efiapi" fn ( image_handle : Handle , map_key : MemoryMapKey ) -> Status ,
@@ -485,6 +490,25 @@ impl BootServices {
485490 }
486491 }
487492
493+ /// Exits the UEFI application and returns control to the UEFI component
494+ /// that started the UEFI application.
495+ ///
496+ /// # Safety
497+ ///
498+ /// This function is unsafe because it is up to the caller to ensure that
499+ /// all resources allocated by the application is freed before invoking
500+ /// exit and returning control to the UEFI component that started the UEFI
501+ /// application.
502+ pub unsafe fn exit (
503+ & self ,
504+ image_handle : Handle ,
505+ exit_status : Status ,
506+ exit_data_size : usize ,
507+ exit_data : * mut Char16 ,
508+ ) -> ! {
509+ ( self . exit ) ( image_handle, exit_status, exit_data_size, exit_data)
510+ }
511+
488512 /// Exits the UEFI boot services
489513 ///
490514 /// This unsafe method is meant to be an implementation detail of the safe
You can’t perform that action at this time.
0 commit comments