elilo/elilo-cleanup.diff

119 lines
3.5 KiB
Diff
Raw Normal View History

--- elilo/alloc.c
+++ elilo/alloc.c
@@ -110,7 +110,7 @@
}
alloc_add(tmp, size, ALLOC_POOL);
- DBG_PRT((L"alloc: allocated %d bytes @[0x%lx-0x%lx]\n", size, tmp, tmp+size));
+ DBG_PRT((L"alloc: allocated %d bytes @[0x%lx-0x%lx]", size, tmp, tmp+size));
return tmp;
}
@@ -140,7 +140,7 @@
alloc_add(addr, pgcnt, ALLOC_PAGES);
- DBG_PRT((L"allocator: allocated %d pages @0x%lx\n", pgcnt, tmp));
+ DBG_PRT((L"allocator: allocated %d pages @0x%lx", pgcnt, tmp));
return addr;
}
@@ -161,7 +161,7 @@
VERB_PRT(1, Print(L"allocator: invalid free @ 0x%lx\n", addr));
return;
found:
- DBG_PRT((L"free: %s @0x%lx size=%ld\n",
+ DBG_PRT((L"free: %s @0x%lx size=%ld",
p->type == ALLOC_POOL ? L"Pool": L"Page",
addr, p->size));
@@ -195,7 +195,7 @@
while(used_allocs) {
- DBG_PRT((L"free_all %a @ 0x%lx\n", used_allocs->type == ALLOC_POOL ? "pool" : "pages", used_allocs->addr));
+ DBG_PRT((L"free_all %a @ 0x%lx", used_allocs->type == ALLOC_POOL ? "pool" : "pages", used_allocs->addr));
if (used_allocs->type == ALLOC_POOL)
uefi_call_wrapper(BS->FreePool, 1, used_allocs->addr);
@@ -239,13 +239,13 @@
VOID
free_kmem(VOID)
{
- DBG_PRT((L"free_kmem before (%lx, %ld)\n", kmem_addr, kmem_pgcnt));
+ DBG_PRT((L"free_kmem before (%lx, %ld)", kmem_addr, kmem_pgcnt));
if (kmem_addr && kmem_pgcnt != 0) {
free(kmem_addr);
kmem_addr = NULL;
kmem_pgcnt = 0;
}
- DBG_PRT((L"free_kmem after (%lx, %ld)\n", kmem_addr, kmem_pgcnt));
+ DBG_PRT((L"free_kmem after (%lx, %ld)", kmem_addr, kmem_pgcnt));
}
VOID
--- elilo/fileops.c
+++ elilo/fileops.c
@@ -497,7 +497,7 @@
str2 = str == NULL ? L"Unknown" : str;
- DBG_PRT((L"%s : %-8s : %s\n", dev_tab[idx].name,
+ DBG_PRT((L"%s : %-8s : %s", dev_tab[idx].name,
(dev_tab[idx].fops ? dev_tab[idx].fops->name: L"N/A"), str2));
if (str) FreePool(str);
--- elilo/glue_netfs.c
+++ elilo/glue_netfs.c
@@ -167,6 +167,8 @@
set_var(VAR_NETFS_DOMAINAME, info.domainame);
if (info.using_pxe) {
+ DBG_PRT((L"netfs_setdefaults: using_pxe"));
+
status = netfs->netfs_query_layer(netfs, 0, NETFS_CONFIG_LAYER, maxlen, config[0].fname);
if (EFI_ERROR(status)) {
StrnCpy(config[0].fname, NETFS_DEFAULT_CONFIG, maxlen-1);
@@ -184,7 +186,7 @@
# if defined(CONFIG_ia64)
# define CONFIG_ARCH_EXTENSION L"-ia64.conf\0"
# elif defined (CONFIG_ia32)
-# define CONFIG_ARCH_EXTENSION L"-ia64.conf\0"
+# define CONFIG_ARCH_EXTENSION L"-ia32.conf\0"
# elif defined (CONFIG_x86_64)
# define CONFIG_ARCH_EXTENSION L"-x86_64.conf\0"
# else
@@ -193,6 +195,7 @@
# define CONFIG_EXTENSION L".conf\0"
+ DBG_PRT((L"netfs_setdefaults: not using_pxe, machine specific"));
len = StrLen(CONFIG_ARCH_EXTENSION) + 1;
/*
* will try machine/subnet specific files first.
--- elilo/x86_64/bzimage.c
+++ elilo/x86_64/bzimage.c
@@ -193,18 +193,20 @@
* Now read the rest of the kernel image into memory.
*/
- DBG_PRT((L"reading kernel image...\n"));
+ Print(L"Loading kernel %s... ", kname);
size = kernel_size;
efi_status = fops_read(fd, kernel_load_address, &size);
if (EFI_ERROR(efi_status) || size < 0x10000) {
- ERR_PRT((L"Error reading kernel image %s.", kname));
+ ERR_PRT((L"Error reading kernel image (0x%x).", efi_status));
free(param_start);
param_start = NULL;
param_size = 0;
fops_close(fd);
free_kmem();
return -1;
+ } else {
+ Print(L" done\n");
}
DBG_PRT((L"kernel image read: %d bytes, %d Kbytes\n", size, size / 1024));