dm: core: Create a new header file for 'compat' features
At present dm/device.h includes the linux-compatible features. This
requires including linux/compat.h which in turn includes a lot of headers.
One of these is malloc.h which we thus end up including in every file in
U-Boot. Apart from the inefficiency of this, it is problematic for sandbox
which needs to use the system malloc() in some files.
Move the compatibility features into a separate header file.
Signed-off-by: Simon Glass <sjg@chromium.org>
diff --git a/cmd/usb_mass_storage.c b/cmd/usb_mass_storage.c
index 570cf3a..c5c6899 100644
--- a/cmd/usb_mass_storage.c
+++ b/cmd/usb_mass_storage.c
@@ -11,6 +11,7 @@
#include <command.h>
#include <console.h>
#include <g_dnl.h>
+#include <malloc.h>
#include <part.h>
#include <usb.h>
#include <usb_mass_storage.h>