File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -134,6 +134,13 @@ pub enum ShimVerificationOutput {
134134#[ unsafe_protocol( ShimSupport :: SHIM_LOCK_GUID ) ]
135135struct ShimLockProtocol {
136136 /// Verify the data in `buffer` with the size `buffer_size` to determine if it is valid.
137+ /// NOTE: On x86_64, this function uses SYSV calling conventions. On aarch64 it uses the
138+ /// efiapi calling convention. This is truly wild, but you can verify it yourself by
139+ /// looking at: https://github.com/rhboot/shim/blob/15.8/shim.h#L207-L212
140+ /// There is no calling convention declared like there should be.
141+ #[ cfg( target_arch = "x86_64" ) ]
142+ pub shim_verify : unsafe extern "sysv64" fn ( buffer : * const c_void , buffer_size : u32 ) -> Status ,
143+ #[ cfg( target_arch = "aarch64" ) ]
137144 pub shim_verify : unsafe extern "efiapi" fn ( buffer : * const c_void , buffer_size : u32 ) -> Status ,
138145 /// Unused function that is defined by the shim.
139146 _generate_header : * mut c_void ,
You can’t perform that action at this time.
0 commit comments