static int x86_tpl_init(void) { int ret; debug("%s starting\n", __func__); ret = spl_init(); if (ret) { debug("%s: spl_init() failed\n", __func__); return ret; } ret = arch_cpu_init(); if (ret) { debug("%s: arch_cpu_init() failed\n", __func__); return ret; } ret = arch_cpu_init_dm(); if (ret) { debug("%s: arch_cpu_init_dm() failed\n", __func__); return ret; } preloader_console_init(); ret = print_cpuinfo(); if (ret) { debug("%s: print_cpuinfo() failed\n", __func__); return ret; } return 0; }
int main() { for (int i = 0; i < 9; ++i) { done[i] = 0; } print_cpuinfo(); inval_dcache(); core_count = print_processor_info(); //done = malloc(sizeof(unsigned int _SPM *)*core_count); com_spm_size = com_spm_test(); main_mem_size = main_mem_test(); int param = 0; printf("Creating corethreads..."); for(int i = 0; i < get_cpucnt(); i++) { if (i != NOC_MASTER) { corethread_t ct = (corethread_t) i; if(corethread_create(&ct,&slave_tester,(void*)param) != 0){ printf("Corethread %d not created\n",i); } } } puts("OK"); printf("Performing main mem load test..."); fflush(stdout); mem_load_test(); printf("OK\n"); noc_test_master(); int* ret; for (int i = 0; i < get_cpucnt(); ++i) { if (i != NOC_MASTER) { corethread_join((corethread_t)i,(void**)&ret); } } printf("Joined with other cores\n"); return 0; }
void display_boot_info(void) { char bl1_version[9] = {0}; printf(" \n"); display_banner(); print_cpuinfo(); // Display dram info display_dram_config(); // Display BL1 version #ifdef CONFIG_TRUSTZONE printf("BL1 version: N/A (TrustZone Enabled BSP)\n"); #else strncpy(&bl1_version[0], (char *)0x02022fc8, 8); printf("BL1 version: %s\n", &bl1_version[0]); #endif // Display boot mode printf("\n\nChecking Boot Mode ..."); if(OmPin == BOOT_ONENAND) { printf(" OneNand\n"); } else if (OmPin == BOOT_NAND) { printf(" NAND\n"); } else if (OmPin == BOOT_MMCSD) { printf(" SDMMC\n"); } else if (OmPin == BOOT_EMMC) { printf(" EMMC4.3\n"); } else if (OmPin == BOOT_EMMC_4_4) { printf(" EMMC4.41\n"); } printf("\n"); }
int board_late_init(void) { if (!power_init()) clock_1GHz(); print_cpuinfo(); return 0; }
void board_init_f(ulong dummy) { #if 0 arch_cpu_init(); board_early_init_f(); timer_init(); preloader_console_init(); print_cpuinfo(); board_init_r(NULL, 0); #endif }
int main(int argc, char *argv[]) { int i; FILE *out; const char *out_filename = NULL; for (i = 1; i < argc; i++) { const char *arg = argv[i]; if (strcmp(arg, "-d") == 0 || strcmp(arg, "--debug") == 0) { if (++i < argc) out_filename = argv[i]; else out_filename = "-"; /* stdout */ } else if (strcmp(arg, "-h") == 0 || strcmp(arg, "--help") == 0) { print_usage(argv[0]); return 0; } } struct cpuinfo *cip = cpuinfo_new(); if (cip == NULL) { fprintf(stderr, "ERROR: could not allocate cpuinfo descriptor\n"); return 1; } if (out_filename == NULL || strcmp(out_filename, "-") == 0) out = stdout; else { if ((out = fopen(out_filename, "w")) == NULL) { fprintf(stderr, "ERROR: could not open debug file '%s'\n", out_filename); return 2; } } if (out_filename) cpuinfo_set_debug_file(out); print_cpuinfo(cip, out); if (out_filename) { /* debug mode */ fprintf(out, "\n### DEBUGGING INFORMATION ###\n\n"); cpuinfo_dump(cip, out); } if (out != stdout) fclose(out); cpuinfo_destroy(cip); return 0; }
int board_init(void) { gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100; mxc_set_sata_internal_clock(); setup_iomux_i2c(); if (!power_init()) clock_1GHz(); print_cpuinfo(); lcd_enable(); return 0; }
void kernel_init(multiboot_info_t *mboot_info) { extern char __start_bss[], __stop_bss[]; memset(__start_bss, 0, __stop_bss - __start_bss); /* mboot_info is a physical address. while some arches currently have the * lower memory mapped, everyone should have it mapped at kernbase by now. * also, it might be in 'free' memory, so once we start dynamically using * memory, we may clobber it. */ multiboot_kaddr = (struct multiboot_info*)((physaddr_t)mboot_info + KERNBASE); extract_multiboot_cmdline(multiboot_kaddr); cons_init(); print_cpuinfo(); printk("Boot Command Line: '%s'\n", boot_cmdline); exception_table_init(); cache_init(); // Determine systems's cache properties pmem_init(multiboot_kaddr); kmem_cache_init(); // Sets up slab allocator kmalloc_init(); hashtable_init(); radix_init(); cache_color_alloc_init(); // Inits data structs colored_page_alloc_init(); // Allocates colors for agnostic processes acpiinit(); topology_init(); kthread_init(); /* might need to tweak when this happens */ vmr_init(); file_init(); page_check(); idt_init(); kernel_msg_init(); timer_init(); vfs_init(); devfs_init(); train_timing(); kb_buf_init(&cons_buf); arch_init(); block_init(); enable_irq(); run_linker_funcs(); /* reset/init devtab after linker funcs 3 and 4. these run NIC and medium * pre-inits, which need to happen before devether. */ devtabreset(); devtabinit(); #ifdef CONFIG_EXT2FS mount_fs(&ext2_fs_type, "/dev/ramdisk", "/mnt", 0); #endif /* CONFIG_EXT2FS */ #ifdef CONFIG_ETH_AUDIO eth_audio_init(); #endif /* CONFIG_ETH_AUDIO */ get_coreboot_info(&sysinfo); booting = 0; #ifdef CONFIG_RUN_INIT_SCRIPT if (run_init_script()) { printk("Configured to run init script, but no script specified!\n"); manager(); } #else manager(); #endif }