34
34
DECLARE_GLOBAL_DATA_PTR;
36
#if !defined(CONFIG_SYS_NO_FLASH)
37
36
extern flash_info_t flash_info[CONFIG_SYS_MAX_FLASH_BANKS]; /* info for FLASH chips */
40
extern void __ft_board_setup(void *blob, bd_t *bd);
41
ulong flash_get_size(ulong base, int banknum);
38
ulong flash_get_size (ulong base, int banknum);
43
40
int board_early_init_f(void)
125
122
int misc_init_r(void)
127
#if !defined(CONFIG_SYS_NO_FLASH)
129
125
int size_val = 0;
131
127
#ifdef CONFIG_440EPX
132
128
unsigned long usb2d0cr = 0;
133
129
unsigned long usb2phy0cr, usb2h0cr = 0;
134
130
unsigned long sdr0_pfc1;
135
131
char *act = getenv("usbact");
139
#if !defined(CONFIG_SYS_NO_FLASH)
140
134
/* Re-do flash sizing to get full correct info */
142
136
/* adjust flash start and offset */
520
513
return 0; /* No hotkeys supported */
522
515
#endif /* CONFIG_POST */
524
#if defined(CONFIG_NAND_U_BOOT) || defined(CONFIG_SYS_RAMBOOT)
526
* On NAND-booting sequoia, we need to patch the chips select numbers
527
* in the dtb (CS0 - NAND, CS3 - NOR)
529
void ft_board_setup(void *blob, bd_t *bd)
534
struct fdt_property *prop;
538
/* First do common fdt setup */
539
__ft_board_setup(blob, bd);
541
/* And now configure NOR chip select to 3 instead of 0 */
542
strcpy(path, "/plb/opb/ebc/nor_flash@0,0");
543
nodeoffset = fdt_path_offset(blob, path);
544
prop = fdt_get_property_w(blob, nodeoffset, "reg", &len);
546
printf("Unable to update NOR chip select for NAND booting\n");
549
reg = (u32 *)&prop->data[0];
551
rc = fdt_find_and_setprop(blob, path, "reg", reg, 3 * sizeof(u32), 1);
553
printf("Unable to update property NOR mappings, err=%s\n",
558
/* And now configure NAND chip select to 0 instead of 3 */
559
strcpy(path, "/plb/opb/ebc/ndfc@3,0");
560
nodeoffset = fdt_path_offset(blob, path);
561
prop = fdt_get_property_w(blob, nodeoffset, "reg", &len);
563
printf("Unable to update NDFC chip select for NAND booting\n");
566
reg = (u32 *)&prop->data[0];
568
rc = fdt_find_and_setprop(blob, path, "reg", reg, 3 * sizeof(u32), 1);
570
printf("Unable to update property NDFC mappings, err=%s\n",
575
#endif /* CONFIG_NAND_U_BOOT */