From owner-p4-projects@FreeBSD.ORG Wed Jan 16 01:05:12 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 061DD16A418; Wed, 16 Jan 2008 01:05:12 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A798516A474 for ; Wed, 16 Jan 2008 01:05:11 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 897B113C469 for ; Wed, 16 Jan 2008 01:05:11 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m0G15BNP054233 for ; Wed, 16 Jan 2008 01:05:11 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m0G15Bxf054224 for perforce@freebsd.org; Wed, 16 Jan 2008 01:05:11 GMT (envelope-from imp@freebsd.org) Date: Wed, 16 Jan 2008 01:05:11 GMT Message-Id: <200801160105.m0G15Bxf054224@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 133381 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Jan 2008 01:05:12 -0000 http://perforce.freebsd.org/chv.cgi?CH=133381 Change 133381 by imp@imp_lighthouse on 2008/01/16 01:04:10 integrate from mips2 Affected files ... .. //depot/projects/mips2-jnpr/src/sys/mips/include/md_var.h#7 integrate .. //depot/projects/mips2-jnpr/src/sys/mips/mips/machdep.c#13 integrate .. //depot/projects/mips2-jnpr/src/sys/mips/mips/pmap.c#16 edit .. //depot/projects/mips2-jnpr/src/sys/mips/mips32/adm5120/adm5120_machdep.c#2 integrate .. //depot/projects/mips2-jnpr/src/sys/mips/mips32/idt/idt_machdep.c#2 integrate .. //depot/projects/mips2-jnpr/src/sys/mips/mips32/malta/malta_machdep.c#5 integrate .. //depot/projects/mips2-jnpr/src/sys/mips/mips32/sentry5/s5_machdep.c#2 integrate Differences ... ==== //depot/projects/mips2-jnpr/src/sys/mips/include/md_var.h#7 (text+ko) ==== ==== //depot/projects/mips2-jnpr/src/sys/mips/mips/machdep.c#13 (text+ko) ==== @@ -267,21 +267,17 @@ void mips_proc0_init(void) { - kstack0 = pmap_steal_memory(KSTACK_PAGES * PAGE_SIZE); + proc_linkup(&proc0, &thread0); thread0.td_kstack = kstack0; - thread0.td_pcb = (struct pcb *) - (thread0.td_kstack + KSTACK_PAGES * PAGE_SIZE) - 1; - - thread0.td_frame = &thread0.td_pcb->pcb_regs; - - /* Initialize pcpu info of cpu-zero */ + /* Initialize pcpu info of cpu-zero */ #ifdef SMP pcpu_init(&__pcpu[0], 0, sizeof(struct pcpu)); #else pcpu_init(pcpup, 0, sizeof(struct pcpu)); #endif - - proc_linkup(&proc0, &thread0); + pcpup->pc_curthread = &thread0; + cpu_thread_alloc(curthread); + pcpup->pc_curpcb = curthread->td_pcb; PCPU_SET(curthread, &thread0); PCPU_SET(curpcb, thread0.td_pcb); } ==== //depot/projects/mips2-jnpr/src/sys/mips/mips/pmap.c#16 (text+ko) ==== @@ -1,3 +1,4 @@ + kstack0 = pmap_steal_memory(KSTACK_PAGES * PAGE_SIZE); /* * Copyright (c) 1991 Regents of the University of California. * All rights reserved. ==== //depot/projects/mips2-jnpr/src/sys/mips/mips32/adm5120/adm5120_machdep.c#2 (text+ko) ==== @@ -94,19 +94,10 @@ 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 kdb_init(); #endif ==== //depot/projects/mips2-jnpr/src/sys/mips/mips32/idt/idt_machdep.c#2 (text+ko) ==== @@ -145,19 +145,10 @@ cninit(); 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 kdb_init(); #endif ==== //depot/projects/mips2-jnpr/src/sys/mips/mips32/malta/malta_machdep.c#5 (text+ko) ==== @@ -179,23 +179,10 @@ init_param1(); init_param2(physmem); - mips_cpu_init(); pmap_bootstrap(); - -#if 0 - 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; -#else mips_proc0_init(); -#endif - mutex_init(); - #ifdef DDB kdb_init(); #endif ==== //depot/projects/mips2-jnpr/src/sys/mips/mips32/sentry5/s5_machdep.c#2 (text+ko) ==== @@ -132,19 +132,10 @@ 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 kdb_init(); #endif