@@ -5,13 +5,14 @@
* Przemyslaw Marczak <p.marczak@samsung.com>
*/
-#include "regulator_common.h"
#include <common.h>
#include <errno.h>
#include <dm.h>
#include <power/pmic.h>
#include <power/regulator.h>
+#include "regulator_common.h"
+
static int fixed_regulator_ofdata_to_platdata(struct udevice *dev)
{
struct dm_regulator_uclass_platdata *uc_pdata;
@@ -4,7 +4,6 @@
* Keerthy <j-keerthy@ti.com>
*/
-#include "regulator_common.h"
#include <common.h>
#include <fdtdec.h>
#include <errno.h>
@@ -14,6 +13,8 @@
#include <power/pmic.h>
#include <power/regulator.h>
+#include "regulator_common.h"
+
#define GPIO_REGULATOR_MAX_STATES 2
DECLARE_GLOBAL_DATA_PTR;
@@ -4,10 +4,12 @@
* Sven Schwermer <sven.svenschwermer@disruptive-technologies.com>
*/
-#include "regulator_common.h"
#include <common.h>
+#include <dm.h>
#include <power/regulator.h>
+#include "regulator_common.h"
+
int regulator_common_ofdata_to_platdata(struct udevice *dev,
struct regulator_common_platdata *dev_pdata, const char *enable_gpio_name)
{
@@ -7,9 +7,7 @@
#ifndef _REGULATOR_COMMON_H
#define _REGULATOR_COMMON_H
-#include <common.h>
#include <asm/gpio.h>
-#include <dm.h>
struct regulator_common_platdata {
struct gpio_desc gpio; /* GPIO for regulator enable control */
This file should not include common.h and dm.h so remove them. Also move the inclusion of this file to after the normal includes. Signed-off-by: Simon Glass <sjg@chromium.org> --- drivers/power/regulator/fixed.c | 3 ++- drivers/power/regulator/gpio-regulator.c | 3 ++- drivers/power/regulator/regulator_common.c | 4 +++- drivers/power/regulator/regulator_common.h | 2 -- 4 files changed, 7 insertions(+), 5 deletions(-)