summaryrefslogtreecommitdiffstats
path: root/src/drivers/net/b44.c
diff options
context:
space:
mode:
authorPiotr Jaroszyński2010-07-27 20:37:55 +0200
committerMichael Brown2010-08-16 17:54:03 +0200
commit5bbad9c8f0eacf92fa0ddb6d2d34afe7a0d4278e (patch)
tree6994da16fdddf65f13409b184fdbba7d3907ff80 /src/drivers/net/b44.c
parent[dhcp] Allow multiple interfaces in dhcp command (diff)
downloadipxe-5bbad9c8f0eacf92fa0ddb6d2d34afe7a0d4278e.tar.gz
ipxe-5bbad9c8f0eacf92fa0ddb6d2d34afe7a0d4278e.tar.xz
ipxe-5bbad9c8f0eacf92fa0ddb6d2d34afe7a0d4278e.zip
[ioapi] Move get_memmap() to the I/O API group
pcbios specific get_memmap() is used by the b44 driver making all-drivers builds fail on other platforms. Move it to the I/O API group and provide a dummy implementation on EFI. Signed-off-by: Piotr Jaroszyński <p.jaroszynski@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/drivers/net/b44.c')
-rw-r--r--src/drivers/net/b44.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/drivers/net/b44.c b/src/drivers/net/b44.c
index 29aa5fa6..a104652c 100644
--- a/src/drivers/net/b44.c
+++ b/src/drivers/net/b44.c
@@ -43,7 +43,6 @@ FILE_LICENCE ( GPL2_OR_LATER );
#include <ipxe/netdevice.h>
#include <ipxe/ethernet.h>
#include <ipxe/if_ether.h>
-#include <ipxe/memmap.h>
#include "b44.h"
@@ -89,6 +88,8 @@ int phys_ram_within_limit(u64 limit)
struct memory_region *highest = NULL;
get_memmap(&memmap);
+ if (memmap.count == 0)
+ return 0;
highest = &memmap.regions[memmap.count - 1];
return (highest->end < limit);