X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=board%2Fnetvia%2Fnetvia.c;h=b3bbf47e01e6abd97473e87482ee8632514f649c;hb=3765b3e7bd0f8e46914d417f29cbcb0c72b1acf7;hp=9dd732b3c2800004508069425539defa4d6e5fee;hpb=993cad9364c6b87ae429d1ed1130d8153f6f027e;p=platform%2Fkernel%2Fu-boot.git diff --git a/board/netvia/netvia.c b/board/netvia/netvia.c index 9dd732b..b3bbf47 100644 --- a/board/netvia/netvia.c +++ b/board/netvia/netvia.c @@ -2,23 +2,7 @@ * (C) Copyright 2000 * Wolfgang Denk, DENX Software Engineering, wd@denx.de. * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0+ */ /* @@ -245,9 +229,9 @@ int checkboard(void) #define MCR_MCLF(x) ((unsigned long)((x) & 15) << (31 - 23)) #define MCR_MCLF_MASK MCR_MCLF(15) -long int initdram(int board_type) +phys_size_t initdram(int board_type) { - volatile immap_t *immap = (immap_t *) CFG_IMMR; + volatile immap_t *immap = (immap_t *) CONFIG_SYS_IMMR; volatile memctl8xx_t *memctl = &immap->im_memctl; long int size; @@ -256,17 +240,17 @@ long int initdram(int board_type) /* * Preliminary prescaler for refresh */ - memctl->memc_mptpr = CFG_MPTPR_1BK_8K; + memctl->memc_mptpr = CONFIG_SYS_MPTPR_1BK_8K; memctl->memc_mar = MAR_SDRAM_INIT; /* 32-bit address to be output on the address bus if AMX = 0b11 */ /* * Map controller bank 3 to the SDRAM bank at preliminary address. */ - memctl->memc_or3 = CFG_OR3_PRELIM; - memctl->memc_br3 = CFG_BR3_PRELIM; + memctl->memc_or3 = CONFIG_SYS_OR3_PRELIM; + memctl->memc_br3 = CONFIG_SYS_BR3_PRELIM; - memctl->memc_mamr = CFG_MAMR_9COL & ~MAMR_PTAE; /* no refresh yet */ + memctl->memc_mamr = CONFIG_SYS_MAMR_9COL & ~MAMR_PTAE; /* no refresh yet */ udelay(200); @@ -282,7 +266,7 @@ long int initdram(int board_type) udelay(1000); - memctl->memc_mamr = CFG_MAMR_9COL; + memctl->memc_mamr = CONFIG_SYS_MAMR_9COL; size = SDRAM_MAX_SIZE; @@ -356,9 +340,9 @@ int misc_init_r(void) #error Unknown NETVIA board version. #endif -int board_pre_init(void) +int board_early_init_f(void) { - volatile immap_t *immap = (immap_t *) CFG_IMMR; + volatile immap_t *immap = (immap_t *) CONFIG_SYS_IMMR; volatile iop8xx_t *ioport = &immap->im_ioport; volatile cpm8xx_t *cpm = &immap->im_cpm; volatile memctl8xx_t *memctl = &immap->im_memctl; @@ -415,21 +399,3 @@ int board_pre_init(void) return 0; } - -#if (CONFIG_COMMANDS & CFG_CMD_NAND) - -#include - -extern void nand_probe(ulong physadr); -extern struct nand_chip nand_dev_desc[CFG_MAX_NAND_DEVICE]; - -void nand_init(void) -{ - nand_probe(CFG_NAND_BASE); - if (nand_dev_desc[0].ChipID != NAND_ChipID_UNKNOWN) { - nand_dev_desc[0].name = "NetVia NAND flash"; - puts("NAND: "); - print_size(nand_dev_desc[0].totlen, "\n"); - } -} -#endif