From 3f2546b2ef55b661fd8dd69682b38992225e86f6 Mon Sep 17 00:00:00 2001 From: fishsoupisgood Date: Mon, 29 Apr 2019 01:17:54 +0100 Subject: Initial import of qemu-2.4.1 --- roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c (limited to 'roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c') diff --git a/roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c b/roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c new file mode 100644 index 00000000..37f4b8b4 --- /dev/null +++ b/roms/u-boot/arch/arm/cpu/armv7/omap3/emac.c @@ -0,0 +1,29 @@ +/* + * + * DaVinci EMAC initialization. + * + * (C) Copyright 2011, Ilya Yanok, Emcraft Systems + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#include +#include +#include +#include + +/* + * Initializes on-chip ethernet controllers. + * to override, implement board_eth_init() + */ +int cpu_eth_init(bd_t *bis) +{ + u32 reset; + + /* ensure that the module is out of reset */ + reset = readl(&am35x_scm_general_regs->ip_sw_reset); + reset &= ~CPGMACSS_SW_RST; + writel(reset, &am35x_scm_general_regs->ip_sw_reset); + + return davinci_emac_initialize(); +} -- cgit v1.2.3