robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2007 |
| 3 | * Robert Lazarski, Instituto Atlantico, robertlazarski@gmail.com |
| 4 | * |
| 5 | * Copyright 2007 Freescale Semiconductor, Inc. |
| 6 | * |
| 7 | * See file CREDITS for list of people who contributed to this |
| 8 | * project. |
| 9 | * |
| 10 | * This program is free software; you can redistribute it and/or |
| 11 | * modify it under the terms of the GNU General Public License as |
| 12 | * published by the Free Software Foundation; either version 2 of |
| 13 | * the License, or (at your option) any later version. |
| 14 | * |
| 15 | * This program is distributed in the hope that it will be useful, |
| 16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 18 | * GNU General Public License for more details. |
| 19 | * |
| 20 | * You should have received a copy of the GNU General Public License |
| 21 | * along with this program; if not, write to the Free Software |
| 22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
| 23 | * MA 02111-1307 USA |
| 24 | */ |
| 25 | |
| 26 | #include <common.h> |
| 27 | #include <command.h> |
| 28 | #include <pci.h> |
| 29 | #include <asm/processor.h> |
| 30 | #include <asm/immap_85xx.h> |
Kumar Gala | 9bbd643 | 2009-04-02 13:22:48 -0500 | [diff] [blame] | 31 | #include <asm/fsl_pci.h> |
Kumar Gala | fe436d0 | 2008-08-26 23:14:14 -0500 | [diff] [blame] | 32 | #include <asm/fsl_ddr_sdram.h> |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 33 | #include <asm/io.h> |
Kumar Gala | fe436d0 | 2008-08-26 23:14:14 -0500 | [diff] [blame] | 34 | #include <asm/mmu.h> |
Jon Loeliger | de9737d | 2008-03-04 10:03:03 -0600 | [diff] [blame] | 35 | #include <spd_sdram.h> |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 36 | #include <miiphy.h> |
| 37 | #include <libfdt.h> |
| 38 | #include <fdt_support.h> |
| 39 | |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 40 | long int fixed_sdram(void); |
| 41 | |
| 42 | int board_early_init_f (void) |
| 43 | { |
| 44 | return 0; |
| 45 | } |
| 46 | |
| 47 | int checkboard (void) |
| 48 | { |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 49 | volatile ccsr_gur_t *gur = (void *)(CONFIG_SYS_MPC85xx_GUTS_ADDR); |
Becky Bruce | 0d4cee1 | 2010-06-17 11:37:20 -0500 | [diff] [blame] | 50 | volatile fsl_lbc_t *lbc = LBC_BASE_ADDR; |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 51 | volatile ccsr_local_ecm_t *ecm = (void *)(CONFIG_SYS_MPC85xx_ECM_ADDR); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 52 | |
| 53 | if ((uint)&gur->porpllsr != 0xe00e0000) { |
Wolfgang Denk | 12cec0a | 2008-07-11 01:16:00 +0200 | [diff] [blame] | 54 | printf("immap size error %lx\n",(ulong)&gur->porpllsr); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 55 | } |
| 56 | printf ("Board: ATUM8548\n"); |
| 57 | |
| 58 | lbc->ltesr = 0xffffffff; /* Clear LBC error interrupts */ |
| 59 | lbc->lteir = 0xffffffff; /* Enable LBC error interrupts */ |
| 60 | ecm->eedr = 0xffffffff; /* Clear ecm errors */ |
| 61 | ecm->eeer = 0xffffffff; /* Enable ecm errors */ |
| 62 | |
| 63 | return 0; |
| 64 | } |
| 65 | |
| 66 | #if !defined(CONFIG_SPD_EEPROM) |
| 67 | /************************************************************************* |
| 68 | * fixed sdram init -- doesn't use serial presence detect. |
| 69 | ************************************************************************/ |
| 70 | long int fixed_sdram (void) |
| 71 | { |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 72 | volatile ccsr_ddr_t *ddr= (void *)(CONFIG_SYS_MPC85xx_DDR_ADDR); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 73 | |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 74 | ddr->cs0_bnds = CONFIG_SYS_DDR_CS0_BNDS; |
| 75 | ddr->cs0_config = CONFIG_SYS_DDR_CS0_CONFIG; |
| 76 | ddr->timing_cfg_0 = CONFIG_SYS_DDR_TIMING_0; |
| 77 | ddr->timing_cfg_1 = CONFIG_SYS_DDR_TIMING_1; |
| 78 | ddr->timing_cfg_2 = CONFIG_SYS_DDR_TIMING_2; |
| 79 | ddr->sdram_mode = CONFIG_SYS_DDR_MODE; |
| 80 | ddr->sdram_interval = CONFIG_SYS_DDR_INTERVAL; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 81 | #if defined (CONFIG_DDR_ECC) |
| 82 | ddr->err_disable = 0x0000000D; |
| 83 | ddr->err_sbe = 0x00ff0000; |
| 84 | #endif |
| 85 | asm("sync;isync;msync"); |
| 86 | udelay(500); |
| 87 | #if defined (CONFIG_DDR_ECC) |
| 88 | /* Enable ECC checking */ |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 89 | ddr->sdram_cfg = (CONFIG_SYS_DDR_CONTROL | 0x20000000); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 90 | #else |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 91 | ddr->sdram_cfg = CONFIG_SYS_DDR_CONTROL; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 92 | #endif |
| 93 | asm("sync; isync; msync"); |
| 94 | udelay(500); |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 95 | return CONFIG_SYS_SDRAM_SIZE * 1024 * 1024; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 96 | } |
| 97 | #endif /* !defined(CONFIG_SPD_EEPROM) */ |
| 98 | |
Becky Bruce | bd99ae7 | 2008-06-09 16:03:40 -0500 | [diff] [blame] | 99 | phys_size_t |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 100 | initdram(int board_type) |
| 101 | { |
| 102 | long dram_size = 0; |
| 103 | |
| 104 | puts("Initializing\n"); |
| 105 | |
| 106 | #if defined(CONFIG_SPD_EEPROM) |
Kumar Gala | fe436d0 | 2008-08-26 23:14:14 -0500 | [diff] [blame] | 107 | puts("fsl_ddr_sdram\n"); |
| 108 | dram_size = fsl_ddr_sdram(); |
| 109 | dram_size = setup_ddr_tlbs(dram_size / 0x100000); |
| 110 | dram_size *= 0x100000; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 111 | #else |
| 112 | puts("fixed_sdram\n"); |
| 113 | dram_size = fixed_sdram (); |
| 114 | #endif |
| 115 | |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 116 | puts(" DDR: "); |
| 117 | return dram_size; |
| 118 | } |
| 119 | |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 120 | #if defined(CONFIG_SYS_DRAM_TEST) |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 121 | int |
| 122 | testdram(void) |
| 123 | { |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 124 | uint *pstart = (uint *) CONFIG_SYS_MEMTEST_START; |
| 125 | uint *pend = (uint *) CONFIG_SYS_MEMTEST_END; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 126 | uint *p; |
| 127 | |
| 128 | printf("Testing DRAM from 0x%08x to 0x%08x\n", |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 129 | CONFIG_SYS_MEMTEST_START, |
| 130 | CONFIG_SYS_MEMTEST_END); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 131 | |
| 132 | printf("DRAM test phase 1:\n"); |
| 133 | for (p = pstart; p < pend; p++) { |
| 134 | printf ("DRAM test attempting to write 0xaaaaaaaa at: %08x\n", (uint) p); |
| 135 | *p = 0xaaaaaaaa; |
Wolfgang Denk | 545b06a | 2008-01-10 00:55:14 +0100 | [diff] [blame] | 136 | } |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 137 | |
| 138 | for (p = pstart; p < pend; p++) { |
| 139 | if (*p != 0xaaaaaaaa) { |
| 140 | printf ("DRAM test fails at: %08x\n", (uint) p); |
| 141 | return 1; |
| 142 | } |
| 143 | } |
| 144 | |
| 145 | printf("DRAM test phase 2:\n"); |
| 146 | for (p = pstart; p < pend; p++) |
| 147 | *p = 0x55555555; |
| 148 | |
| 149 | for (p = pstart; p < pend; p++) { |
| 150 | if (*p != 0x55555555) { |
| 151 | printf ("DRAM test fails at: %08x\n", (uint) p); |
| 152 | return 1; |
| 153 | } |
| 154 | } |
| 155 | |
| 156 | printf("DRAM test passed.\n"); |
| 157 | return 0; |
| 158 | } |
| 159 | #endif |
| 160 | |
| 161 | #ifdef CONFIG_PCI1 |
| 162 | static struct pci_controller pci1_hose; |
| 163 | #endif |
| 164 | |
| 165 | #ifdef CONFIG_PCI2 |
| 166 | static struct pci_controller pci2_hose; |
| 167 | #endif |
| 168 | |
| 169 | #ifdef CONFIG_PCIE1 |
| 170 | static struct pci_controller pcie1_hose; |
| 171 | #endif |
| 172 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 173 | void pci_init_board(void) |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 174 | { |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 175 | volatile ccsr_gur_t *gur = (void *)(CONFIG_SYS_MPC85xx_GUTS_ADDR); |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 176 | struct fsl_pci_info pci_info[3]; |
| 177 | u32 devdisr, pordevsr, io_sel; |
| 178 | u32 porpllsr, pci_agent, pci_speed, pci_32, pci_arb, pci_clk_sel; |
| 179 | int first_free_busno = 0; |
| 180 | int num = 0; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 181 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 182 | int pcie_ep, pcie_configured; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 183 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 184 | devdisr = in_be32(&gur->devdisr); |
| 185 | pordevsr = in_be32(&gur->pordevsr); |
| 186 | porpllsr = in_be32(&gur->porpllsr); |
| 187 | io_sel = (pordevsr & MPC85xx_PORDEVSR_IO_SEL) >> 19; |
| 188 | |
| 189 | debug (" pci_init_board: devdisr=%x, io_sel=%x\n", devdisr, io_sel); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 190 | |
Wolfgang Denk | 545b06a | 2008-01-10 00:55:14 +0100 | [diff] [blame] | 191 | /* explicitly set 'Clock out select register' to echo SYSCLK input to our CPLD */ |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 192 | setbits_be32(&gur->clkocr, MPC85xx_ATUM_CLKOCR); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 193 | |
| 194 | if (io_sel & 1) { |
| 195 | if (!(gur->pordevsr & MPC85xx_PORDEVSR_SGMII1_DIS)) |
| 196 | printf (" eTSEC1 is in sgmii mode.\n"); |
| 197 | if (!(gur->pordevsr & MPC85xx_PORDEVSR_SGMII2_DIS)) |
| 198 | printf (" eTSEC2 is in sgmii mode.\n"); |
| 199 | if (!(gur->pordevsr & MPC85xx_PORDEVSR_SGMII3_DIS)) |
| 200 | printf (" eTSEC3 is in sgmii mode.\n"); |
| 201 | if (!(gur->pordevsr & MPC85xx_PORDEVSR_SGMII4_DIS)) |
| 202 | printf (" eTSEC4 is in sgmii mode.\n"); |
| 203 | } |
| 204 | |
| 205 | #ifdef CONFIG_PCIE1 |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 206 | pcie_configured = is_fsl_pci_cfg(LAW_TRGT_IF_PCIE_1, io_sel); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 207 | |
| 208 | if (pcie_configured && !(devdisr & MPC85xx_DEVDISR_PCIE)){ |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 209 | SET_STD_PCIE_INFO(pci_info[num], 1); |
| 210 | pcie_ep = fsl_setup_hose(&pcie1_hose, pci_info[num].regs); |
| 211 | #ifdef CONFIG_SYS_PCIE1_MEM_BUS2 |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 212 | /* outbound memory */ |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 213 | pci_set_region(&pcie1_hose.regions[0], |
| 214 | CONFIG_SYS_PCIE1_MEM_BUS2, |
Jean-Christophe PLAGNIOL-VILLARD | 0383694 | 2008-10-16 15:01:15 +0200 | [diff] [blame] | 215 | CONFIG_SYS_PCIE1_MEM_PHYS2, |
| 216 | CONFIG_SYS_PCIE1_MEM_SIZE2, |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 217 | PCI_REGION_MEM); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 218 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 219 | pcie1_hose.region_count = 1; |
| 220 | #endif |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 221 | printf ("PCIE1: connected to Slot as %s (base addr %lx)\n", |
Peter Tyser | 62825a5 | 2010-01-17 15:38:26 -0600 | [diff] [blame] | 222 | pcie_ep ? "Endpoint" : "Root Complex", |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 223 | pci_info[num].regs); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 224 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 225 | first_free_busno = fsl_pci_init_port(&pci_info[num++], |
| 226 | &pcie1_hose, first_free_busno); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 227 | } else { |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 228 | printf("PCIE1: disabled\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 229 | } |
| 230 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 231 | puts("\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 232 | #else |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 233 | setbits_be32(&gur->devdisr, MPC85xx_DEVDISR_PCIE); /* disable */ |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 234 | #endif |
| 235 | |
| 236 | #ifdef CONFIG_PCI1 |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 237 | pci_speed = 33333000; /*get_clock_freq (); PCI PSPEED in [4:5] */ |
| 238 | pci_32 = pordevsr & MPC85xx_PORDEVSR_PCI1_PCI32; /* PORDEVSR[15] */ |
| 239 | pci_arb = pordevsr & MPC85xx_PORDEVSR_PCI1_ARB; |
| 240 | pci_clk_sel = porpllsr & MPC85xx_PORDEVSR_PCI1_SPD; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 241 | |
| 242 | if (!(devdisr & MPC85xx_DEVDISR_PCI1)) { |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 243 | SET_STD_PCI_INFO(pci_info[num], 1); |
| 244 | pci_agent = fsl_setup_hose(&pci1_hose, pci_info[num].regs); |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 245 | printf("PCI1: %d bit, %s MHz, %s, %s, %s (base address %lx)\n", |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 246 | (pci_32) ? 32 : 64, |
| 247 | (pci_speed == 33333000) ? "33" : |
| 248 | (pci_speed == 66666000) ? "66" : "unknown", |
| 249 | pci_clk_sel ? "sync" : "async", |
| 250 | pci_agent ? "agent" : "host", |
| 251 | pci_arb ? "arbiter" : "external-arbiter", |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 252 | pci_info[num].regs); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 253 | |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 254 | first_free_busno = fsl_pci_init_port(&pci_info[num++], |
| 255 | &pci1_hose, first_free_busno); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 256 | } else { |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 257 | printf("PCI1: disabled\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 258 | } |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 259 | |
| 260 | puts("\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 261 | #else |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 262 | setbits_be32(&gur->devdisr, MPC85xx_DEVDISR_PCI1); /* disable */ |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 263 | #endif |
| 264 | |
| 265 | #ifdef CONFIG_PCI2 |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 266 | if (!(devdisr & MPC85xx_DEVDISR_PCI2)) { |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 267 | SET_STD_PCI_INFO(pci_info[num], 2); |
| 268 | pci_agent = fsl_setup_hose(&pci2_hose, pci_info[num].regs); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 269 | |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 270 | puts("PCI2\n"); |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 271 | first_free_busno = fsl_pci_init_port(&pci_info[num++], |
| 272 | &pci1_hose, first_free_busno); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 273 | } else { |
Peter Tyser | 2b91f71 | 2010-10-29 17:59:24 -0500 | [diff] [blame^] | 274 | printf("PCI2: disabled\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 275 | } |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 276 | puts("\n"); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 277 | #else |
Kumar Gala | beb2e43 | 2009-11-04 11:05:02 -0600 | [diff] [blame] | 278 | setbits_be32(&gur->devdisr, MPC85xx_DEVDISR_PCI2); /* disable */ |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 279 | #endif |
| 280 | } |
| 281 | |
| 282 | |
| 283 | int last_stage_init(void) |
| 284 | { |
Wolfgang Denk | 545b06a | 2008-01-10 00:55:14 +0100 | [diff] [blame] | 285 | int ic = icache_status (); |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 286 | printf ("icache_status: %d\n", ic); |
| 287 | return 0; |
| 288 | } |
| 289 | |
| 290 | #if defined(CONFIG_OF_BOARD_SETUP) |
Kumar Gala | c10a0c4 | 2008-10-21 08:28:33 -0500 | [diff] [blame] | 291 | void ft_board_setup(void *blob, bd_t *bd) |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 292 | { |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 293 | ft_cpu_setup(blob, bd); |
| 294 | |
Kumar Gala | d0f27d3 | 2010-07-08 22:37:44 -0500 | [diff] [blame] | 295 | FT_FSL_PCI_SETUP; |
robert lazarski | 2533e45 | 2007-12-21 10:39:27 -0500 | [diff] [blame] | 296 | } |
| 297 | #endif |