Lines Matching refs:gd
255 if (!gd->bd) { in spl_dcache_enable()
256 gd->bd = calloc(1, sizeof(bd_t)); in spl_dcache_enable()
257 if (!gd->bd) { in spl_dcache_enable()
261 gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE; in spl_dcache_enable()
262 gd->bd->bi_dram[0].size = SZ_256M; in spl_dcache_enable()
267 gd->arch.tlb_size = PGTABLE_SIZE; in spl_dcache_enable()
268 gd->arch.tlb_addr = (ulong)memalign(SZ_16K, ALIGN(PGTABLE_SIZE, SZ_4K)); in spl_dcache_enable()
269 if (!gd->arch.tlb_addr) { in spl_dcache_enable()
276 free(gd->bd); in spl_dcache_enable()
291 gd->malloc_base = CONFIG_MALLOC_F_ADDR; in spl_common_init()
293 gd->malloc_limit = CONFIG_VAL(SYS_MALLOC_F_LEN); in spl_common_init()
294 gd->malloc_ptr = 0; in spl_common_init()
340 gd->relocaddr = CONFIG_SPL_RELOC_TEXT_BASE; in spl_setup_relocate()
341 gd->new_gd = (gd_t *)gd; in spl_setup_relocate()
342 gd->start_addr_sp = gd->relocaddr; in spl_setup_relocate()
343 gd->fdt_size = ALIGN(fdt_totalsize(gd->fdt_blob) + 0x1000, 32); in spl_setup_relocate()
345 gd->start_addr_sp -= gd->fdt_size; in spl_setup_relocate()
346 gd->new_fdt = (void *)gd->start_addr_sp; in spl_setup_relocate()
347 memcpy(gd->new_fdt, gd->fdt_blob, gd->fdt_size); in spl_setup_relocate()
348 gd->fdt_blob = gd->new_fdt; in spl_setup_relocate()
350 gd->reloc_off = gd->relocaddr - (unsigned long)__image_copy_start; in spl_setup_relocate()
361 if (!gd->bd) in spl_set_bd()
362 gd->bd = &bdata; in spl_set_bd()
372 gd->flags |= GD_FLG_SPL_EARLY_INIT; in spl_early_init()
385 if (!(gd->flags & GD_FLG_SPL_EARLY_INIT)) { in spl_init()
390 gd->flags |= GD_FLG_SPL_INIT; in spl_init()
472 gd->dm_root_f = gd->dm_root; in spl_initr_dm()
473 gd->dm_root = NULL; in spl_initr_dm()
481 gd->timer = NULL; in spl_initr_dm()
531 gd->flags |= GD_FLG_FULL_MALLOC_INIT; in board_init_r()
533 if (!(gd->flags & GD_FLG_SPL_INIT)) { in board_init_r()
632 debug("SPL malloc() used %#lx bytes (%ld KB)\n", gd->malloc_ptr, in board_init_r()
633 gd->malloc_ptr / 1024); in board_init_r()
658 gd->baudrate = CONFIG_BAUDRATE; in preloader_console_init()
662 gd->have_console = 1; in preloader_console_init()
703 gd->malloc_base = ptr; in spl_relocate_stack_gd()
704 gd->malloc_limit = CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN; in spl_relocate_stack_gd()
705 gd->malloc_ptr = 0; in spl_relocate_stack_gd()
711 memcpy(new_gd, (void *)gd, sizeof(gd_t)); in spl_relocate_stack_gd()
716 gd = new_gd; in spl_relocate_stack_gd()
754 us = (get_ticks() - gd->sys_start_tick) / (gd->arch.timer_rate_hz / 1000000); in spl_cleanup_before_jump()
755 tt_us = get_ticks() / (gd->arch.timer_rate_hz / 1000000); in spl_cleanup_before_jump()