1 #ifndef STARTUP_INC_INCLUDED
2 #define STARTUP_INC_INCLUDED
4 #include <hwregs/asm/reg_map_asm.h>
5 #include <hwregs/asm/gio_defs_asm.h>
8 #include <hwregs/asm/pinmux_defs_asm.h>
18 move.d CONFIG_ETRAX_DEF_GIO_PA_OUT, $r0
22 move.d CONFIG_ETRAX_DEF_GIO_PA_OE, $r0
26 move.d CONFIG_ETRAX_DEF_GIO_PB_OUT, $r0
30 move.d CONFIG_ETRAX_DEF_GIO_PB_OE, $r0
34 move.d CONFIG_ETRAX_DEF_GIO_PC_OUT, $r0
38 move.d CONFIG_ETRAX_DEF_GIO_PC_OE, $r0
42 move.d 0xFFFFFFFF, $r0
48 ;;
If eth_mdio, eth, geth
bits are
set in hwprot, don
't
49 ;; set them to gpio, as this means they have been configured
51 move.d 0xFC000000, $r2 ;
pins 25..0 are eth_mdio, eth, geth
54 btstq
REG_BIT(pinmux, rw_hwprot, eth), $r0
55 GIO_SET_P 0x00FFFF00, $r2 ;;
pins 8..23 are eth
56 btstq
REG_BIT(pinmux, rw_hwprot, eth_mdio), $r0
57 GIO_SET_P 0x03000000, $r2 ;;
pins 24..25 are eth_mdio
58 btstq
REG_BIT(pinmux, rw_hwprot, geth), $r0
59 GIO_SET_P 0x000000FF, $r2 ;;
pins 0..7 are geth
68 REG_STATE(clkgen, rw_clk_ctrl, ddr2,
yes) | \
69 REG_STATE(clkgen, rw_clk_ctrl, memarb_bar_ddr,
yes), $r0
73 .macro SETUP_WAIT_STATES
75 move.d CONFIG_ETRAX_PIO_CE0_CFG, $r1
78 move.d CONFIG_ETRAX_PIO_CE1_CFG, $r1
81 move.d CONFIG_ETRAX_PIO_CE2_CFG, $r1