ref: d6ea4969607d9d6b33ae5a40a947f8a2aa2c0845
parent: f0ff0fb0544841d73bc29872d8e2fb4a6a8a5e06
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Oct 19 18:01:13 EDT 2014
efi: fix compiler warnings, remove indicator prints in readn()
--- a/sys/src/boot/efi/efi.c
+++ b/sys/src/boot/efi/efi.c
@@ -7,7 +7,7 @@
};
UINTN MK;
-EFI_HANDLE *IH;
+EFI_HANDLE IH;
EFI_SYSTEM_TABLE *ST;
EFI_GRAPHICS_OUTPUT_PROTOCOL *gop;
--- a/sys/src/boot/efi/mkfile
+++ b/sys/src/boot/efi/mkfile
@@ -1,6 +1,7 @@
TARG=bootia32.efi bootx64.efi
HFILES=fns.h mem.h
IMAGEBASE=0x8000
+CFLAGS=-FTVw
PEFLAGS=$CFLAGS '-DIMAGEBASE='$IMAGEBASE
all:V: $TARG
--- a/sys/src/boot/efi/sub.c
+++ b/sys/src/boot/efi/sub.c
@@ -20,19 +20,13 @@
{
uchar *p, *e;
- putc(' ');
p = data;
e = p + len;
while(p < e){
- if(((ulong)p & 0xF000) == 0){
- putc('\b');
- putc(hex[((ulong)p>>16)&0xF]);
- }
if((len = read(f, p, e - p)) <= 0)
break;
p += len;
}
- putc('\b');
return p - (uchar*)data;
}
@@ -362,13 +356,13 @@
if(readn(f, t, n) != n)
goto Error;
t += n;
- d = (uchar*)PGROUND((ulong)t);
+ d = (uchar*)PGROUND((uintptr)t);
memset(t, 0, d - t);
n = beswal(ex.data);
if(readn(f, d, n) != n)
goto Error;
d += n;
- t = (uchar*)PGROUND((ulong)d);
+ t = (uchar*)PGROUND((uintptr)d);
t += PGROUND(beswal(ex.bss));
memset(d, 0, t - d);