Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 5 Jun 2006 03:28:17 GMT
From:      Peter Wemm <peter@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 98518 for review
Message-ID:  <200606050328.k553SHhn006037@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=98518

Change 98518 by peter@peter_daintree on 2006/06/05 03:27:52

	Clean up some stray loose ends.

Affected files ...

.. //depot/projects/bike_sched/sys/amd64/amd64/vm_machdep.c#3 edit
.. //depot/projects/bike_sched/sys/arm/arm/trap.c#3 edit
.. //depot/projects/bike_sched/sys/arm/arm/vm_machdep.c#2 edit
.. //depot/projects/bike_sched/sys/i386/i386/vm_machdep.c#2 edit
.. //depot/projects/bike_sched/sys/ia64/ia64/trap.c#2 edit
.. //depot/projects/bike_sched/sys/kern/kern_thread.c#3 edit
.. //depot/projects/bike_sched/sys/powerpc/powerpc/trap.c#2 edit
.. //depot/projects/bike_sched/sys/sparc64/sparc64/trap.c#2 edit
.. //depot/projects/bike_sched/sys/sys/proc.h#3 edit

Differences ...

==== //depot/projects/bike_sched/sys/amd64/amd64/vm_machdep.c#3 (text+ko) ====

@@ -244,8 +244,7 @@
  * Initialize machine state (pcb and trap frame) for a new thread about to
  * upcall. Put enough state in the new thread's PCB to get it to go back 
  * userret(), where we can intercept it again to set the return (upcall)
- * Address and stack, along with those from upcals that are from other sources
- * such as those generated in thread_userret() itself.
+ * Address and stack, along with those from upcals that are from other sources.
  */
 void
 cpu_set_upcall(struct thread *td, struct thread *td0)
@@ -302,9 +301,8 @@
 }
 
 /*
- * Set that machine state for performing an upcall that has to
- * be done in thread_userret() so that those upcalls generated
- * in thread_userret() itself can be done as well.
+ * Modify the machine state created by cpu_set_upcall() to arrange
+ * for the new thread to make a specific call as its first act.
  */
 void
 cpu_set_upcall_kse(struct thread *td, void (*entry)(void *), void *arg,

==== //depot/projects/bike_sched/sys/arm/arm/trap.c#3 (text+ko) ====

@@ -729,8 +729,6 @@
 		td->td_frame = tf;
 		if (td->td_ucred != td->td_proc->p_ucred)
 			cred_update_thread(td);
-		if (td->td_proc->p_flag & P_SA)
-			thread_user_enter(td);
 	}
 	fault_pc = tf->tf_pc;
 	if (td->td_md.md_spinlock_count == 0) {
@@ -1002,8 +1000,6 @@
 	td->td_frame = frame;
 	
 	td->td_pticks = 0;
-	if (td->td_proc->p_flag & P_SA)
-		thread_user_enter(td);
 	/*
       	 * Make sure the program counter is correctly aligned so we
 	 * don't take an alignment fault trying to read the opcode.

==== //depot/projects/bike_sched/sys/arm/arm/vm_machdep.c#2 (text+ko) ====

@@ -256,8 +256,7 @@
  * Initialize machine state (pcb and trap frame) for a new thread about to
  * upcall. Put enough state in the new thread's PCB to get it to go back 
  * userret(), where we can intercept it again to set the return (upcall)
- * Address and stack, along with those from upcals that are from other sources
- * such as those generated in thread_userret() itself.
+ * Address and stack, along with those from upcals that are from other sources.
  */
 void
 cpu_set_upcall(struct thread *td, struct thread *td0)
@@ -283,9 +282,8 @@
 }
 
 /*
- * Set that machine state for performing an upcall that has to
- * be done in thread_userret() so that those upcalls generated
- * in thread_userret() itself can be done as well.
+ * Modify the machine state created by cpu_set_upcall() to arrange
+ * for the new thread to make a specific call as its first act.
  */
 void
 cpu_set_upcall_kse(struct thread *td, void (*entry)(void *), void *arg,

==== //depot/projects/bike_sched/sys/i386/i386/vm_machdep.c#2 (text+ko) ====

@@ -370,8 +370,7 @@
  * Initialize machine state (pcb and trap frame) for a new thread about to
  * upcall. Put enough state in the new thread's PCB to get it to go back 
  * userret(), where we can intercept it again to set the return (upcall)
- * Address and stack, along with those from upcals that are from other sources
- * such as those generated in thread_userret() itself.
+ * Address and stack, along with those from upcals that are from other sources.
  */
 void
 cpu_set_upcall(struct thread *td, struct thread *td0)
@@ -439,9 +438,8 @@
 }
 
 /*
- * Set that machine state for performing an upcall that has to
- * be done in thread_userret() so that those upcalls generated
- * in thread_userret() itself can be done as well.
+ * Modify the machine state created by cpu_set_upcall() to arrange
+ * for the new thread to make a specific call as its first act.
  */
 void
 cpu_set_upcall_kse(struct thread *td, void (*entry)(void *), void *arg,

==== //depot/projects/bike_sched/sys/ia64/ia64/trap.c#2 (text+ko) ====

@@ -955,8 +955,6 @@
 	td->td_pticks = 0;
 	if (td->td_ucred != p->p_ucred)
 		cred_update_thread(td);
-	if (p->p_flag & P_SA)
-		thread_user_enter(td);
 
 	if (p->p_sysent->sv_prepsyscall) {
 		/* (*p->p_sysent->sv_prepsyscall)(tf, args, &code, &params); */

==== //depot/projects/bike_sched/sys/kern/kern_thread.c#3 (text+ko) ====

@@ -314,7 +314,6 @@
  * exit1()
  * kse_exit()
  * thr_exit()
- * thread_user_enter()
  * thread_suspend_check()
  */
 void
@@ -392,7 +391,6 @@
  			 * exit1() - clears threading flags before coming here
  			 * kse_exit() - treats last thread specially
  			 * thr_exit() - treats last thread specially
- 			 * thread_user_enter() - only if more exist
  			 * thread_suspend_check() - only if more exist
 			 */
 			panic ("thread_exit: Last thread exiting on its own");

==== //depot/projects/bike_sched/sys/powerpc/powerpc/trap.c#2 (text+ko) ====

@@ -348,9 +348,6 @@
 
 	PCPU_LAZY_INC(cnt.v_syscall);
 
-	if (p->p_flag & P_SA)
-		thread_user_enter(td);
-
 	code = frame->fixreg[0];
 	params = (caddr_t)(frame->fixreg + FIRSTARG);
 	n = NARGREG;

==== //depot/projects/bike_sched/sys/sparc64/sparc64/trap.c#2 (text+ko) ====

@@ -529,8 +529,6 @@
 	td->td_frame = tf;
 	if (td->td_ucred != p->p_ucred)
 		cred_update_thread(td);
-	if (p->p_flag & P_SA)
-		thread_user_enter(td);
 	code = tf->tf_global[1];
 
 	/*

==== //depot/projects/bike_sched/sys/sys/proc.h#3 (text+ko) ====

@@ -805,8 +805,6 @@
 void	thread_unsuspend(struct proc *p);
 void	thread_unsuspend_one(struct thread *td);
 void	thread_unthread(struct thread *td);
-int	thread_userret(struct thread *td, struct trapframe *frame);
-void	thread_user_enter(struct thread *td);
 void	thread_wait(struct proc *p);
 struct thread	*thread_find(struct proc *p, lwpid_t tid);
 void	thr_exit1(void);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200606050328.k553SHhn006037>