blob: 8a2c2dc8906f8f82786d3552d04eeade306d480a [file] [log] [blame]
Stefan Roese50752792009-01-21 17:24:39 +01001/*
2 * (C) Copyright 2008 Stefan Roese <sr@denx.de>, DENX Software Engineering
3 *
4 * Copyright (C) 2006 Micronas GmbH
5 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02006 * SPDX-License-Identifier: GPL-2.0+
Stefan Roese50752792009-01-21 17:24:39 +01007 */
8
9#include <common.h>
10#include <asm/io.h>
11#include "vct.h"
12
13int ebi_initialize(void)
14{
15#if defined(CONFIG_VCT_NOR)
16 if (ebi_init_nor_flash())
17 return -1;
18#endif
19
20#if defined(CONFIG_VCT_ONENAND)
21 if (ebi_init_onenand())
22 return -1;
23#endif
24
25#if defined(CONFIG_DRIVER_SMC911X)
26 if (ebi_init_smc911x())
27 return -1;
28#endif
29
30 reg_write(EBI_CTRL_SIG_ACTLV(EBI_BASE), 0x00004100);
31
32 ebi_wait();
33
34 return 0;
35}