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>
This commit is contained in:
Simon Glass
2020-02-03 07:36:16 -07:00
parent 61b29b8268
commit 336d4615f8
460 changed files with 593 additions and 77 deletions

View File

@@ -6,6 +6,7 @@
*/
#include <common.h>
#include <malloc.h>
#include <asm/bootm.h>
#include <asm/gpio.h>
#include <asm/setup.h>

View File

@@ -10,6 +10,7 @@
* Frederik Kriewitz <frederik@kriewitz.eu>
*/
#include <common.h>
#include <malloc.h>
#include <twl4030.h>
#include <status_led.h>
#include <asm/io.h>

View File

@@ -8,6 +8,7 @@
#include <env_internal.h>
#include <init.h>
#include <led.h>
#include <malloc.h>
#include <net.h>
#include <spi.h>
#include <spi_flash.h>

View File

@@ -4,6 +4,7 @@
*/
#include "vpd_reader.h"
#include <malloc.h>
#include <i2c.h>
#include <linux/bch.h>

View File

@@ -9,6 +9,7 @@
#include <env.h>
#include <errno.h>
#include <init.h>
#include <malloc.h>
#include <serial.h>
#include <spl.h>
#include <asm/arch/cpu.h>

View File

@@ -5,6 +5,7 @@
*/
#include <common.h>
#include <env.h>
#include <malloc.h>
#include <status_led.h>
#include <dm.h>
#include <ns16550.h>

View File

@@ -9,6 +9,7 @@
#include <common.h>
#include <dm.h>
#include <init.h>
#include <malloc.h>
#include <asm/io.h>
#include <asm/arch/imx-regs.h>
#include <asm/arch/sys_proto.h>

View File

@@ -10,6 +10,7 @@
#include <common.h>
#include <dm.h>
#include <clk.h>
#include <malloc.h>
#include <dt-bindings/clock/microchip,clock.h>
#include <mach/pic32.h>

View File

@@ -14,6 +14,7 @@
#include <common.h>
#include <dm.h>
#include <env.h>
#include <malloc.h>
#include <ns16550.h>
#include <netdev.h>
#include <twl4030.h>

View File

@@ -12,6 +12,7 @@
#include <common.h>
#include <env.h>
#include <errno.h>
#include <malloc.h>
#include <serial.h>
#include <spl.h>
#include <asm/arch/cpu.h>

View File

@@ -16,6 +16,7 @@
#include <env.h>
#include <errno.h>
#include <init.h>
#include <malloc.h>
#include <spl.h>
#include <asm/arch/cpu.h>
#include <asm/arch/hardware.h>

View File

@@ -14,6 +14,7 @@
#include <env.h>
#include <errno.h>
#include <init.h>
#include <malloc.h>
#include <spi.h>
#include <spl.h>
#include <asm/arch/cpu.h>

View File

@@ -16,6 +16,7 @@
#include <i2c.h>
#include <init.h>
#include <led.h>
#include <malloc.h>
#include <memalign.h>
#include <misc.h>
#include <mtd.h>

View File

@@ -5,6 +5,7 @@
*/
#include <clk.h>
#include <malloc.h>
#include <dm/device.h>
#include "clk-lib.h"

View File

@@ -4,6 +4,7 @@
* Tapani Utriainen <linuxfae@technexion.com>
*/
#include <common.h>
#include <malloc.h>
#include <netdev.h>
#include <twl4030.h>
#include <asm/io.h>

View File

@@ -12,6 +12,7 @@
#include <env.h>
#include <errno.h>
#include <init.h>
#include <malloc.h>
#include <spl.h>
#include <serial.h>
#include <asm/arch/cpu.h>

View File

@@ -11,6 +11,7 @@
#include <env.h>
#include <fdt_support.h>
#include <init.h>
#include <malloc.h>
#include <palmas.h>
#include <sata.h>
#include <serial.h>

View File

@@ -18,6 +18,7 @@
#include <common.h>
#include <dm.h>
#include <env.h>
#include <malloc.h>
#include <ns16550.h>
#include <twl4030.h>
#include <asm/io.h>