summaryrefslogtreecommitdiff
path: root/arch/arm/cpu
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2015-04-19 11:48:19 +0200
committerHans de Goede <hdegoede@redhat.com>2015-05-04 16:51:53 +0200
commit939ed1cba84cefedfbaeed2690c05bb9360d9b88 (patch)
tree4edf3589f72144319ecd85cc96ea494d718b86d6 /arch/arm/cpu
parentd88c2f114970ab5153f39901324b9983d227f618 (diff)
downloadu-boot-imx-939ed1cba84cefedfbaeed2690c05bb9360d9b88.zip
u-boot-imx-939ed1cba84cefedfbaeed2690c05bb9360d9b88.tar.gz
u-boot-imx-939ed1cba84cefedfbaeed2690c05bb9360d9b88.tar.bz2
sunxi: emac: Add driver model support
Modify the sunxi-emac eth driver to support driver model. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk> Reviewed-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'arch/arm/cpu')
-rw-r--r--arch/arm/cpu/armv7/sunxi/board.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/cpu/armv7/sunxi/board.c b/arch/arm/cpu/armv7/sunxi/board.c
index 873f8b3..732e5c8 100644
--- a/arch/arm/cpu/armv7/sunxi/board.c
+++ b/arch/arm/cpu/armv7/sunxi/board.c
@@ -12,7 +12,9 @@
#include <common.h>
#include <i2c.h>
+#ifndef CONFIG_DM_ETH
#include <netdev.h>
+#endif
#include <miiphy.h>
#include <serial.h>
#ifdef CONFIG_SPL_BUILD
@@ -219,7 +221,7 @@ int cpu_eth_init(bd_t *bis)
mdelay(200);
#endif
-#ifdef CONFIG_SUNXI_EMAC
+#if defined CONFIG_SUNXI_EMAC && !defined CONFIG_DM_ETH
rc = sunxi_emac_initialize(bis);
if (rc < 0) {
printf("sunxi: failed to initialize emac\n");