summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/drivers/net/rtl8139.c3
-rw-r--r--src/hci/mucurses/slk.c2
-rw-r--r--src/hci/mucurses/windows.c2
-rw-r--r--src/interface/pxe/pxe_preboot.c2
-rw-r--r--src/net/ipv4.c6
-rw-r--r--src/net/ipv6.c1
6 files changed, 7 insertions, 9 deletions
diff --git a/src/drivers/net/rtl8139.c b/src/drivers/net/rtl8139.c
index c88796021..ff1fa646a 100644
--- a/src/drivers/net/rtl8139.c
+++ b/src/drivers/net/rtl8139.c
@@ -66,11 +66,12 @@
*/
+#include <stdint.h>
+#include <stdlib.h>
#include <io.h>
#include <errno.h>
#include <vsprintf.h>
#include <timer.h>
-#include <malloc.h>
#include <byteswap.h>
#include <gpxe/pci.h>
#include <gpxe/if_ether.h>
diff --git a/src/hci/mucurses/slk.c b/src/hci/mucurses/slk.c
index ca0822882..4422e15a0 100644
--- a/src/hci/mucurses/slk.c
+++ b/src/hci/mucurses/slk.c
@@ -1,6 +1,6 @@
#include <curses.h>
#include <stddef.h>
-#include <malloc.h>
+#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include "mucurses.h"
diff --git a/src/hci/mucurses/windows.c b/src/hci/mucurses/windows.c
index c1a3a9315..63d0af08c 100644
--- a/src/hci/mucurses/windows.c
+++ b/src/hci/mucurses/windows.c
@@ -1,6 +1,6 @@
#include <curses.h>
#include <stddef.h>
-#include <malloc.h>
+#include <stdlib.h>
#include "mucurses.h"
/** @file
diff --git a/src/interface/pxe/pxe_preboot.c b/src/interface/pxe/pxe_preboot.c
index 894ed4365..09fa5fef3 100644
--- a/src/interface/pxe/pxe_preboot.c
+++ b/src/interface/pxe/pxe_preboot.c
@@ -25,7 +25,7 @@
#include <stdint.h>
#include <string.h>
-#include <malloc.h>
+#include <stdlib.h>
#include <gpxe/uaccess.h>
#include <gpxe/dhcp.h>
#include "pxe.h"
diff --git a/src/net/ipv4.c b/src/net/ipv4.c
index 8a1e8df3e..065bf61c4 100644
--- a/src/net/ipv4.c
+++ b/src/net/ipv4.c
@@ -1,8 +1,8 @@
#include <string.h>
#include <stdint.h>
+#include <stdlib.h>
#include <errno.h>
#include <byteswap.h>
-#include <malloc.h>
#include <vsprintf.h>
#include <gpxe/list.h>
#include <gpxe/in.h>
@@ -199,9 +199,7 @@ static void ipv4_frag_expired ( struct retry_timer *timer __unused,
* @v fragbug Fragment buffer
*/
static void free_fragbuf ( struct frag_buffer *fragbuf ) {
- if ( fragbuf ) {
- free_dma ( fragbuf, sizeof ( *fragbuf ) );
- }
+ free ( fragbuf );
}
/**
diff --git a/src/net/ipv6.c b/src/net/ipv6.c
index e38e314aa..26c43dd0b 100644
--- a/src/net/ipv6.c
+++ b/src/net/ipv6.c
@@ -2,7 +2,6 @@
#include <stdint.h>
#include <string.h>
#include <stdlib.h>
-#include <malloc.h>
#include <vsprintf.h>
#include <byteswap.h>
#include <gpxe/in.h>