diff options
author | Simon Glass <sjg@chromium.org> | 2020-02-03 07:36:16 -0700 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2020-02-05 19:33:46 -0700 |
commit | 336d4615f8fa774557d14f9b3245daa9e5fe3dbc (patch) | |
tree | 7a4d2d33113f44238d64e7e409fd3aafef63c2ed /drivers/power | |
parent | 61b29b82683863a970fd4609a7c58512872616bc (diff) | |
download | u-boot-336d4615f8fa774557d14f9b3245daa9e5fe3dbc.tar.gz |
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>
Diffstat (limited to 'drivers/power')
-rw-r--r-- | drivers/power/domain/bcm6328-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/imx8-power-domain-legacy.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/imx8-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/imx8m-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/meson-ee-pwrc.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/meson-gx-pwrc-vpu.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/mtk-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/power-domain-uclass.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/sandbox-power-domain-test.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/sandbox-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/tegra186-power-domain.c | 1 | ||||
-rw-r--r-- | drivers/power/domain/ti-sci-power-domain.c | 2 | ||||
-rw-r--r-- | drivers/power/pmic/fan53555.c | 1 | ||||
-rw-r--r-- | drivers/power/pmic/i2c_pmic_emul.c | 1 | ||||
-rw-r--r-- | drivers/power/pmic/stpmic1.c | 1 | ||||
-rw-r--r-- | drivers/power/regulator/pwm_regulator.c | 1 | ||||
-rw-r--r-- | drivers/power/regulator/stm32-vrefbuf.c | 1 | ||||
-rw-r--r-- | drivers/power/regulator/tps62360_regulator.c | 1 |
18 files changed, 19 insertions, 0 deletions
diff --git a/drivers/power/domain/bcm6328-power-domain.c b/drivers/power/domain/bcm6328-power-domain.c index 425451e4cd..a6426bee27 100644 --- a/drivers/power/domain/bcm6328-power-domain.c +++ b/drivers/power/domain/bcm6328-power-domain.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <asm/io.h> diff --git a/drivers/power/domain/imx8-power-domain-legacy.c b/drivers/power/domain/imx8-power-domain-legacy.c index 74fcb05c15..6f01a60b34 100644 --- a/drivers/power/domain/imx8-power-domain-legacy.c +++ b/drivers/power/domain/imx8-power-domain-legacy.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <asm/io.h> #include <asm/arch/power-domain.h> diff --git a/drivers/power/domain/imx8-power-domain.c b/drivers/power/domain/imx8-power-domain.c index 8e328f02c2..571146e19d 100644 --- a/drivers/power/domain/imx8-power-domain.c +++ b/drivers/power/domain/imx8-power-domain.c @@ -6,6 +6,7 @@ #define DEBUG #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <asm/arch/power-domain.h> #include <asm/arch/sci/sci.h> diff --git a/drivers/power/domain/imx8m-power-domain.c b/drivers/power/domain/imx8m-power-domain.c index fbfd17718b..5b6467cda7 100644 --- a/drivers/power/domain/imx8m-power-domain.c +++ b/drivers/power/domain/imx8m-power-domain.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <asm/io.h> #include <asm/arch/power-domain.h> diff --git a/drivers/power/domain/meson-ee-pwrc.c b/drivers/power/domain/meson-ee-pwrc.c index aa11866591..7082c80bfa 100644 --- a/drivers/power/domain/meson-ee-pwrc.c +++ b/drivers/power/domain/meson-ee-pwrc.c @@ -6,6 +6,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <regmap.h> #include <syscon.h> diff --git a/drivers/power/domain/meson-gx-pwrc-vpu.c b/drivers/power/domain/meson-gx-pwrc-vpu.c index 02f73548d6..12cdfcdd1f 100644 --- a/drivers/power/domain/meson-gx-pwrc-vpu.c +++ b/drivers/power/domain/meson-gx-pwrc-vpu.c @@ -8,6 +8,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <regmap.h> #include <syscon.h> diff --git a/drivers/power/domain/mtk-power-domain.c b/drivers/power/domain/mtk-power-domain.c index 789fc5ab64..3ff7ca1bef 100644 --- a/drivers/power/domain/mtk-power-domain.c +++ b/drivers/power/domain/mtk-power-domain.c @@ -7,6 +7,7 @@ #include <clk.h> #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <regmap.h> #include <syscon.h> diff --git a/drivers/power/domain/power-domain-uclass.c b/drivers/power/domain/power-domain-uclass.c index be0a8026f6..d9c623b56e 100644 --- a/drivers/power/domain/power-domain-uclass.c +++ b/drivers/power/domain/power-domain-uclass.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain.h> #include <power-domain-uclass.h> #include <dm/device-internal.h> diff --git a/drivers/power/domain/sandbox-power-domain-test.c b/drivers/power/domain/sandbox-power-domain-test.c index 148b6b1707..2191a94146 100644 --- a/drivers/power/domain/sandbox-power-domain-test.c +++ b/drivers/power/domain/sandbox-power-domain-test.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain.h> #include <asm/io.h> #include <asm/power-domain.h> diff --git a/drivers/power/domain/sandbox-power-domain.c b/drivers/power/domain/sandbox-power-domain.c index a5ae235d53..3a834a9f1e 100644 --- a/drivers/power/domain/sandbox-power-domain.c +++ b/drivers/power/domain/sandbox-power-domain.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <power-domain-uclass.h> #include <asm/io.h> #include <asm/power-domain.h> diff --git a/drivers/power/domain/tegra186-power-domain.c b/drivers/power/domain/tegra186-power-domain.c index d2a25ca333..e87244197f 100644 --- a/drivers/power/domain/tegra186-power-domain.c +++ b/drivers/power/domain/tegra186-power-domain.c @@ -5,6 +5,7 @@ #include <common.h> #include <dm.h> +#include <malloc.h> #include <misc.h> #include <power-domain-uclass.h> #include <asm/arch-tegra/bpmp_abi.h> diff --git a/drivers/power/domain/ti-sci-power-domain.c b/drivers/power/domain/ti-sci-power-domain.c index 3866db589a..a5866703ae 100644 --- a/drivers/power/domain/ti-sci-power-domain.c +++ b/drivers/power/domain/ti-sci-power-domain.c @@ -11,7 +11,9 @@ #include <common.h> #include <dm.h> #include <errno.h> +#include <malloc.h> #include <power-domain-uclass.h> +#include <dm/device_compat.h> #include <linux/err.h> #include <linux/soc/ti/ti_sci_protocol.h> #include <dt-bindings/soc/ti,sci_pm_domain.h> diff --git a/drivers/power/pmic/fan53555.c b/drivers/power/pmic/fan53555.c index 11304d2146..a5f855ce2a 100644 --- a/drivers/power/pmic/fan53555.c +++ b/drivers/power/pmic/fan53555.c @@ -6,6 +6,7 @@ #include <common.h> #include <dm.h> #include <dm/device-internal.h> +#include <dm/device_compat.h> #include <dm/lists.h> #include <i2c.h> #include <power/fan53555.h> diff --git a/drivers/power/pmic/i2c_pmic_emul.c b/drivers/power/pmic/i2c_pmic_emul.c index b58c8302cf..86d7b89b1f 100644 --- a/drivers/power/pmic/i2c_pmic_emul.c +++ b/drivers/power/pmic/i2c_pmic_emul.c @@ -8,6 +8,7 @@ #include <errno.h> #include <dm.h> #include <i2c.h> +#include <malloc.h> #include <power/pmic.h> #include <power/sandbox_pmic.h> diff --git a/drivers/power/pmic/stpmic1.c b/drivers/power/pmic/stpmic1.c index 2297af4157..2c85410b1b 100644 --- a/drivers/power/pmic/stpmic1.c +++ b/drivers/power/pmic/stpmic1.c @@ -11,6 +11,7 @@ #include <sysreset.h> #include <time.h> #include <dm/device.h> +#include <dm/device_compat.h> #include <dm/lists.h> #include <power/pmic.h> #include <power/stpmic1.h> diff --git a/drivers/power/regulator/pwm_regulator.c b/drivers/power/regulator/pwm_regulator.c index cd05c9b603..4030144dd3 100644 --- a/drivers/power/regulator/pwm_regulator.c +++ b/drivers/power/regulator/pwm_regulator.c @@ -11,6 +11,7 @@ #include <dm.h> #include <errno.h> #include <pwm.h> +#include <dm/device_compat.h> #include <power/regulator.h> DECLARE_GLOBAL_DATA_PTR; diff --git a/drivers/power/regulator/stm32-vrefbuf.c b/drivers/power/regulator/stm32-vrefbuf.c index 645528e84e..08a10f05b4 100644 --- a/drivers/power/regulator/stm32-vrefbuf.c +++ b/drivers/power/regulator/stm32-vrefbuf.c @@ -10,6 +10,7 @@ #include <clk.h> #include <dm.h> #include <asm/io.h> +#include <dm/device_compat.h> #include <linux/iopoll.h> #include <linux/kernel.h> #include <power/regulator.h> diff --git a/drivers/power/regulator/tps62360_regulator.c b/drivers/power/regulator/tps62360_regulator.c index 2c076c0db5..ce54495490 100644 --- a/drivers/power/regulator/tps62360_regulator.c +++ b/drivers/power/regulator/tps62360_regulator.c @@ -7,6 +7,7 @@ #include <common.h> #include <dm.h> #include <i2c.h> +#include <dm/device_compat.h> #include <power/regulator.h> #define TPS62360_REG_SET0 0 |