Date: Thu, 31 Jan 2008 18:30:32 GMT From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 134557 for review Message-ID: <200801311830.m0VIUWeT082267@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=134557 Change 134557 by imp@imp_lighthouse on 2008/01/31 18:29:40 Move copy of mips_proc0_init out of here too. Minor tweaks to make it more closely match what malta does. Affected files ... .. //depot/projects/mips2-jnpr/src/sys/mips/mips32/octeon32/octeon_machdep.c#5 edit Differences ... ==== //depot/projects/mips2-jnpr/src/sys/mips/mips32/octeon32/octeon_machdep.c#5 (text+ko) ==== @@ -1139,10 +1139,11 @@ int realmem_bytes; - realmem_bytes = (((octeon_board_real())?256:96) << 20); /* Override. Temporary hard-code */ + /* XXX: Override. Temporary hard-code */ + realmem_bytes = (((octeon_board_real())?256:96) << 20); /* phys_avail regions are in bytes */ phys_avail[0] = (MIPS_KSEG0_TO_PHYS((vm_offset_t)&end) + PAGE_SIZE) & ~(PAGE_SIZE - 1); - phys_avail[1] = realmem_bytes - 64; + phys_avail[1] = phys_avail[0] + realmem_bytes - 64 - 1; #ifdef MEM_EXTEND @@ -1190,17 +1191,9 @@ init_param1(); init_param2(physmem); - mips_cpu_init(); pmap_bootstrap(); - - proc_linkup(&proc0, &thread0); - thread0.td_kstack = kstack0; - pcpu_init(pcpup, 0, sizeof(struct pcpu)); - pcpup->pc_curthread = &thread0; - cpu_thread_alloc(curthread); - pcpup->pc_curpcb = curthread->td_pcb; - + mips_proc0_init(); mutex_init(); #ifdef DDB @@ -1258,8 +1251,7 @@ /* clear the BSS and SBSS segments */ kernend = round_page((vm_offset_t)&end); - -// memset(&edata, 0, kernend - (vm_offset_t)(&edata)); + memset(&edata, 0, kernend - (vm_offset_t)(&edata)); tick_early_init(OCTEON_CLOCK_DEFAULT); /* Quick Default. To avoid divide-by-0 @@ -1269,8 +1261,6 @@ cninit(); printf(" Initialized memory: 0x%p to 0x%lX\n", &edata, ((long) &edata) + ((long)kernend - (long)(&edata))); - mips_boot_params_init(); - mips_wbflush(); mips_init(); uint64_t platform_counter_freq = OCTEON_CLOCK_DEFAULT; tick_init_params(platform_counter_freq, 0);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200801311830.m0VIUWeT082267>