Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Mar 2005 08:34:44 GMT
From:      Juli Mallett <jmallett@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 73448 for review
Message-ID:  <200503180834.j2I8YivD074331@repoman.freebsd.org>

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

Change 73448 by jmallett@jmallett_windward on 2005/03/18 08:34:43

	Compile.

Affected files ...

.. //depot/projects/mips/sys/alpha/include/cpu.h#9 edit
.. //depot/projects/mips/sys/geom/geom_fx.c#14 edit
.. //depot/projects/mips/sys/mips/include/cpu.h#18 edit
.. //depot/projects/mips/sys/mips/include/cpufunc.h#18 edit
.. //depot/projects/mips/sys/mips/include/critical.h#5 edit
.. //depot/projects/mips/sys/mips/include/db_machdep.h#9 edit
.. //depot/projects/mips/sys/mips/include/kdb.h#1 add
.. //depot/projects/mips/sys/mips/include/pcb.h#8 edit
.. //depot/projects/mips/sys/mips/mips/cache_r5k_subr.S#4 edit
.. //depot/projects/mips/sys/mips/mips/clock_r4k.c#5 edit
.. //depot/projects/mips/sys/mips/mips/cpu.c#6 edit
.. //depot/projects/mips/sys/mips/mips/locore.S#16 edit
.. //depot/projects/mips/sys/mips/mips/machdep.c#49 edit
.. //depot/projects/mips/sys/mips/mips/pmap.c#40 edit

Differences ...

==== //depot/projects/mips/sys/alpha/include/cpu.h#9 (text+ko) ====


==== //depot/projects/mips/sys/geom/geom_fx.c#14 (text+ko) ====

@@ -182,7 +182,7 @@
 		}
 		break;
 	}
-	g_access_rel(cp, -1, 0, 0);
+	g_access(cp, -1, 0, 0);
 	if (LIST_EMPTY(&gp->provider)) {
 		g_slice_spoiled(cp);
 		return (NULL);

==== //depot/projects/mips/sys/mips/include/cpu.h#18 (text+ko) ====

@@ -79,6 +79,8 @@
 	{ "wall_cmos_clock", CTLTYPE_INT }, \
 }
 
+#define	cpu_spinwait()		/* nothing */
+
 static __inline u_int64_t
 get_cyclecount(void)
 {

==== //depot/projects/mips/sys/mips/include/cpufunc.h#18 (text+ko) ====

@@ -160,7 +160,7 @@
 #define	intr_restore(s)	mips_wr_status((s))
 
 static __inline void
-mips_break(void)
+breakpoint(void)
 {
 	__asm __volatile ("break");
 }

==== //depot/projects/mips/sys/mips/include/critical.h#5 (text+ko) ====

@@ -33,7 +33,7 @@
  *	related support functions residing
  *	in <arch>/<arch>/critical.c	- prototyped
  *
- * $P4: //depot/projects/mips/sys/mips/include/critical.h#4 $
+ * $P4: //depot/projects/mips/sys/mips/include/critical.h#5 $
  */
 
 #ifndef _MACHINE_CRITICAL_H_
@@ -57,11 +57,8 @@
  *	of td_critnest, prior to it being incremented to 1.
  */
 static __inline void
-cpu_critical_enter(void)
+cpu_critical_enter(struct thread *td)
 {
-	struct thread *td;
-
-	td = curthread;
 	td->td_md.md_savecrit = intr_disable();
 }
 
@@ -73,11 +70,8 @@
  *	exiting the last critical section.
  */
 static __inline void
-cpu_critical_exit(void)
+cpu_critical_exit(struct thread *td)
 {
-	struct thread *td;
-
-	td = curthread;
 	intr_restore(td->td_md.md_savecrit);
 }
 

==== //depot/projects/mips/sys/mips/include/db_machdep.h#9 (text+ko) ====

@@ -82,7 +82,6 @@
  */
 void 	kdb_kbd_trap(db_regs_t *);
 void 	db_set_ddb_regs(int type, struct trapframe *);
-int 	kdb_trap(int type, struct trapframe *);
 int	kdbpeek(db_addr_t);
 
 #define	DB_SMALL_VALUE_MAX	(0x7fffffff)

==== //depot/projects/mips/sys/mips/include/pcb.h#8 (text+ko) ====

@@ -42,6 +42,7 @@
 #ifdef _KERNEL
 #define	PCB_FSR(pcb)	(0)
 
+void	makectx(struct trapframe *, struct pcb *);
 int	savectx(struct pcb *pcb);
 #endif
 

==== //depot/projects/mips/sys/mips/mips/cache_r5k_subr.S#4 (text+ko) ====

@@ -41,14 +41,14 @@
  */
 LEAF(r5k_enable_sdcache)
 	lw	t2, mips_sdcache_size
-	la	t1, MIPS_KSEG0_START
+	dla	t1, MIPS_KSEG0_START
 
 	beq	t2, zero, 3f		# if no sdcache, we can bail now
 	nop
 
 	add	t2, t1, t2
 
-	la	v0, 1f
+	dla	v0, 1f
 	or	v0, MIPS_KSEG1_START
 
 	j	v0			# run the rest from uncached space

==== //depot/projects/mips/sys/mips/mips/clock_r4k.c#5 (text+ko) ====

@@ -28,6 +28,7 @@
 #include <sys/param.h>
 #include <sys/systm.h>
 #include <sys/proc.h>
+#include <sys/module.h>
 #include <sys/bus.h>
 #include <sys/kernel.h>
 #include <sys/rman.h>

==== //depot/projects/mips/sys/mips/mips/cpu.c#6 (text+ko) ====

@@ -25,8 +25,10 @@
  * $FreeBSD$
  */
 
+#define	__RMAN_RESOURCE_VISIBLE
 #include <sys/param.h>
 #include <sys/systm.h>
+#include <sys/module.h>
 #include <sys/bus.h>
 #include <sys/kernel.h>
 #include <sys/rman.h>

==== //depot/projects/mips/sys/mips/mips/locore.S#16 (text+ko) ====

@@ -89,10 +89,10 @@
 	sw	t1, fpu_id
 
 	/* Set up the GP. */
-	la	gp, _gp
+	dla	gp, _gp
 
 	/* Set up our temporary stack. */
-	la	sp, topstack
+	dla	sp, topstack
 
 	/* Call the platform-specific startup code. */
 	jal	platform_start

==== //depot/projects/mips/sys/mips/mips/machdep.c#49 (text+ko) ====

@@ -135,17 +135,26 @@
 }
 
 void
-Debugger(const char *msg)
+dumpsys(struct dumperinfo *dip)
 {
-	printf("Debugger(%s)\n", msg);
-	mips_break();
 }
 
+/*
+ * Construct a PCB from a trapframe. This is called from kdb_trap() where
+ * we want to start a backtrace from the function that caused us to enter
+ * the debugger. We have the context in the trapframe, but base the trace
+ * on the PCB. The PCB doesn't have to be perfect, as long as it contains
+ * enough for a backtrace.
+ */
 void
-dumpsys(struct dumperinfo *dip)
+makectx(struct trapframe *tf, struct pcb *pcb)
 {
+	pcb->pcb_regs[11] = tf->tf_regs[TF_SR];
+	pcb->pcb_regs[10] = tf->tf_regs[TF_RA];
+	pcb->pcb_regs[8] = tf->tf_regs[TF_SP];
 }
 
+
 int
 get_mcontext(struct thread *td, mcontext_t *mcp, int clear_ret)
 {

==== //depot/projects/mips/sys/mips/mips/pmap.c#40 (text+ko) ====

@@ -101,6 +101,7 @@
 
 #include <sys/user.h>
 
+#include <machine/cache.h>
 #include <machine/locore.h>
 #include <machine/md_var.h>
 #include <machine/tlb.h>



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