aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorSimon Glass2020-05-10 11:39:55 -0600
committerTom Rini2020-05-18 14:54:24 -0400
commitc3dc39a2f85b16bf590789f7e283cd72275cd168 (patch)
treefd07b448aa4192e1d4fede43e412d5fdfa584b82 /drivers
parentb79fdc76978515fba2c4f3b5b4f2e679c5ff1463 (diff)
arm: Don't include common.h in header files
It is bad practice to include common.h in other header files since it can bring in any number of superfluous definitions. It implies that some C files don't include it and thus may be missing CONFIG options that are set up by that file. The C files should include these themselves. Update some header files in arch/arm to drop this. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mtd/nand/raw/denali.c2
-rw-r--r--drivers/mtd/nand/raw/denali_dt.c2
-rw-r--r--drivers/usb/eth/lan7x.h7
3 files changed, 11 insertions, 0 deletions
diff --git a/drivers/mtd/nand/raw/denali.c b/drivers/mtd/nand/raw/denali.c
index b525b1be549..3a09a8165c1 100644
--- a/drivers/mtd/nand/raw/denali.c
+++ b/drivers/mtd/nand/raw/denali.c
@@ -11,6 +11,8 @@
#include <dm/device_compat.h>
#include <dm/devres.h>
#include <linux/bitfield.h>
+#include <linux/delay.h>
+#include <linux/dma-direction.h>
#include <linux/dma-mapping.h>
#include <linux/err.h>
#include <linux/errno.h>
diff --git a/drivers/mtd/nand/raw/denali_dt.c b/drivers/mtd/nand/raw/denali_dt.c
index 41b93e660a0..2728e8098fa 100644
--- a/drivers/mtd/nand/raw/denali_dt.c
+++ b/drivers/mtd/nand/raw/denali_dt.c
@@ -7,6 +7,8 @@
#include <clk.h>
#include <dm.h>
#include <dm/device_compat.h>
+#include <linux/bug.h>
+#include <linux/delay.h>
#include <linux/io.h>
#include <linux/ioport.h>
#include <linux/printk.h>
diff --git a/drivers/usb/eth/lan7x.h b/drivers/usb/eth/lan7x.h
index 7af610be370..35965e9645a 100644
--- a/drivers/usb/eth/lan7x.h
+++ b/drivers/usb/eth/lan7x.h
@@ -4,7 +4,10 @@
*/
#include <console.h>
+#include <time.h>
#include <watchdog.h>
+#include <linux/delay.h>
+#include <linux/errno.h>
/* USB Vendor Requests */
#define USB_VENDOR_REQUEST_WRITE_REGISTER 0xA0
@@ -122,6 +125,10 @@ int lan7x_write_reg(struct usb_device *udev, u32 index, u32 data);
int lan7x_read_reg(struct usb_device *udev, u32 index, u32 *data);
+/*
+ * FIXME: Code should not be in header files. Nive this to a file common to
+ * the two drivers.
+ */
static inline int lan7x_wait_for_bit(struct usb_device *udev,
const char *prefix, const u32 reg,
const u32 mask, const bool set,