common: Drop net.h from common header
Move this header out of the common header. Network support is used in
quite a few places but it still does not warrant blanket inclusion.
Note that this net.h header itself has quite a lot in it. It could be
split into the driver-mode support, functions, structures, checksumming,
etc.
Signed-off-by: Simon Glass <sjg@chromium.org>
diff --git a/common/board_f.c b/common/board_f.c
index a5ead31..bae4267 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -40,6 +40,7 @@
#include <trace.h>
#include <video.h>
#include <watchdog.h>
+#include <asm/cache.h>
#ifdef CONFIG_MACH_TYPE
#include <asm/mach-types.h>
#endif
diff --git a/common/board_r.c b/common/board_r.c
index bd074eb..33efcf6 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -18,6 +18,7 @@
#include <image.h>
#include <irq_func.h>
#include <net.h>
+#include <asm/cache.h>
#include <u-boot/crc.h>
/* TODO: can we just include all these headers whether needed or not? */
#if defined(CONFIG_CMD_BEDBUG)
diff --git a/common/bootm.c b/common/bootm.c
index db4362a..96cba01 100644
--- a/common/bootm.c
+++ b/common/bootm.c
@@ -15,6 +15,8 @@
#include <lmb.h>
#include <malloc.h>
#include <mapmem.h>
+#include <net.h>
+#include <asm/cache.h>
#include <asm/io.h>
#if defined(CONFIG_CMD_USB)
#include <usb.h>
diff --git a/common/bouncebuf.c b/common/bouncebuf.c
index 0ace152..6bb8b53 100644
--- a/common/bouncebuf.c
+++ b/common/bouncebuf.c
@@ -10,6 +10,7 @@
#include <malloc.h>
#include <errno.h>
#include <bouncebuf.h>
+#include <asm/cache.h>
static int addr_aligned(struct bounce_buffer *state)
{
diff --git a/common/fdt_support.c b/common/fdt_support.c
index 02cf5c6..fad551f 100644
--- a/common/fdt_support.c
+++ b/common/fdt_support.c
@@ -9,6 +9,7 @@
#include <common.h>
#include <env.h>
#include <mapmem.h>
+#include <net.h>
#include <stdio_dev.h>
#include <linux/ctype.h>
#include <linux/types.h>
diff --git a/common/hash.c b/common/hash.c
index ff4986a..2cf7635 100644
--- a/common/hash.c
+++ b/common/hash.c
@@ -16,6 +16,7 @@
#include <malloc.h>
#include <mapmem.h>
#include <hw_sha.h>
+#include <asm/cache.h>
#include <asm/io.h>
#include <linux/errno.h>
#include <u-boot/crc.h>
diff --git a/common/image.c b/common/image.c
index d8d14e8..14e27fb 100644
--- a/common/image.c
+++ b/common/image.c
@@ -11,6 +11,7 @@
#include <cpu_func.h>
#include <env.h>
#include <malloc.h>
+#include <asm/cache.h>
#include <u-boot/crc.h>
#include <watchdog.h>
diff --git a/common/lcd.c b/common/lcd.c
index f8bc1ce..c421090 100644
--- a/common/lcd.c
+++ b/common/lcd.c
@@ -12,6 +12,7 @@
#include <command.h>
#include <cpu_func.h>
#include <env_callback.h>
+#include <asm/cache.h>
#include <linux/types.h>
#include <stdio_dev.h>
#include <lcd.h>
diff --git a/common/log_syslog.c b/common/log_syslog.c
index 5e3e20e..698c585 100644
--- a/common/log_syslog.c
+++ b/common/log_syslog.c
@@ -7,6 +7,7 @@
#include <common.h>
#include <log.h>
+#include <net.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/common/main.c b/common/main.c
index 06d7ff5..64287f7 100644
--- a/common/main.c
+++ b/common/main.c
@@ -13,6 +13,7 @@
#include <console.h>
#include <env.h>
#include <init.h>
+#include <net.h>
#include <version.h>
static void run_preboot_environment_command(void)
diff --git a/common/spl/spl_atf.c b/common/spl/spl_atf.c
index 702367b..bc2921c 100644
--- a/common/spl/spl_atf.c
+++ b/common/spl/spl_atf.c
@@ -14,6 +14,7 @@
#include <cpu_func.h>
#include <errno.h>
#include <spl.h>
+#include <asm/cache.h>
static struct bl2_to_bl31_params_mem bl31_params_mem;
static struct bl31_params *bl2_to_bl31_params;
diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c
index c51e4be..3df4c8f 100644
--- a/common/spl/spl_fit.c
+++ b/common/spl/spl_fit.c
@@ -12,6 +12,7 @@
#include <image.h>
#include <malloc.h>
#include <spl.h>
+#include <asm/cache.h>
#include <linux/libfdt.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/common/usb_storage.c b/common/usb_storage.c
index b291ac5..76af7cc 100644
--- a/common/usb_storage.c
+++ b/common/usb_storage.c
@@ -39,6 +39,7 @@
#include <mapmem.h>
#include <memalign.h>
#include <asm/byteorder.h>
+#include <asm/cache.h>
#include <asm/processor.h>
#include <dm/device-internal.h>
#include <dm/lists.h>