authorgravatar for n@nirf.deNick Erdmann <n@nirf.de> 2019-08-09 23:12:59+02:00
committergravatar for n@nirf.deNick Erdmann <n@nirf.de> 2019-08-10 19:14:31+02:00
log9445b3f057bdeb57cdb02c86b94145ae9a345531
treec81d9719a276ac2b28e831bc6f8c48bcc457a59f
parent88fdb303ff7a33d87207bbd61a648c5c1dbe56ad
signature Commit is signed but in an unrecognized format.

std/os/uefi: change type of Handle from @OpaqueType to *@OpaqueType


5 files changed, 9 insertions(+), 9 deletions(-)

std/os/uefi.zig+2-2
......@@ -5,7 +5,7 @@ pub const tables = @import("uefi/tables.zig");
55const builtin = @import("builtin");
66pub const is_the_target = builtin.os == .uefi;
77
8pub var handle: *Handle = undefined;
8pub var handle: Handle = undefined;
99pub var system_table: *tables.SystemTable = undefined;
1010
1111pub const Event = @OpaqueType();
......@@ -18,7 +18,7 @@ pub const Guid = extern struct {
1818 clock_seq_low: u8,
1919 node: [6]u8,
2020};
21pub const Handle = @OpaqueType();
21pub const Handle = *@OpaqueType();
2222pub const Time = extern struct {
2323 year: u16,
2424 month: u8,
std/os/uefi/protocols/edid_override_protocol.zig+2-2
......@@ -4,10 +4,10 @@ const Handle = uefi.Handle;
44
55/// UEFI Specification, Version 2.8, 12.9
66pub const EdidOverrideProtocol = extern struct {
7 _get_edid: extern fn (*const EdidOverrideProtocol, *const Handle, *u32, *usize, *?[*]u8) usize,
7 _get_edid: extern fn (*const EdidOverrideProtocol, Handle, *u32, *usize, *?[*]u8) usize,
88
99 /// attributes must be align(4)
10 pub fn getEdid(self: *const EdidOverrideProtocol, handle: *const Handle, attributes: *EdidOverrideProtocolAttributes, edid_size: *usize, edid: *?[*]u8) usize {
10 pub fn getEdid(self: *const EdidOverrideProtocol, handle: Handle, attributes: *EdidOverrideProtocolAttributes, edid_size: *usize, edid: *?[*]u8) usize {
1111 return self._get_edid(self, handle, attributes, edid_size, edid);
1212 }
1313
std/os/uefi/tables/boot_services.zig+1-1
......@@ -39,7 +39,7 @@ pub const BootServices = extern struct {
3939 installConfigurationTable: usize, // TODO
4040 imageLoad: usize, // TODO
4141 imageStart: usize, // TODO
42 exit: extern fn (*const Handle, usize, usize, ?*const c_void) usize,
42 exit: extern fn (Handle, usize, usize, ?*const c_void) usize,
4343 imageUnload: usize, // TODO
4444 exitBootServices: usize, // TODO
4545 getNextMonotonicCount: usize, // TODO
std/os/uefi/tables/system_table.zig+3-3
......@@ -19,11 +19,11 @@ pub const SystemTable = extern struct {
1919 hdr: TableHeader,
2020 firmware_vendor: *u16,
2121 firmware_revision: u32,
22 console_in_handle: ?*Handle,
22 console_in_handle: ?Handle,
2323 con_in: ?*SimpleTextInputExProtocol,
24 console_out_handle: ?*Handle,
24 console_out_handle: ?Handle,
2525 con_out: ?*SimpleTextOutputProtocol,
26 standard_error_handle: ?*Handle,
26 standard_error_handle: ?Handle,
2727 std_err: ?*SimpleTextOutputProtocol,
2828 runtime_services: *RuntimeServices,
2929 boot_services: ?*BootServices,
std/special/start.zig+1-1
......@@ -31,7 +31,7 @@ extern fn wasm_freestanding_start() void {
3131 _ = callMain();
3232}
3333
34extern fn EfiMain(handle: *uefi.Handle, system_table: *uefi.tables.SystemTable) usize {
34extern fn EfiMain(handle: uefi.Handle, system_table: *uefi.tables.SystemTable) usize {
3535 const bad_efi_main_ret = "expected return type of main to be 'void', 'noreturn', or 'usize'";
3636 uefi.handle = handle;
3737 uefi.system_table = system_table;