Commit Graph

784 Commits

Author SHA1 Message Date
soren a255740671 MachForceCacheUpdate and cacheflush_bug have never been used in NetBSD,
so remove references them, and do a little other cleanup.
2000-05-23 04:21:39 +00:00
uch fb077d8092 change TX3922 D-cache mode to write-through. 2000-05-21 11:53:00 +00:00
soren f598aece87 MIPS 'mach halt' does nothing MD, so nuke it. 2000-05-21 05:41:25 +00:00
soren 6aba4259b6 R10K has 64 TLBs. 2000-05-21 04:25:57 +00:00
soren abbe53961a Add R12K PRID. 2000-05-21 04:03:34 +00:00
soren 81fa4aa07f Populate the cputype defopt (not enabled yet). 2000-05-21 03:31:35 +00:00
soren 2779a53005 Include opt_cputype.h. 2000-05-21 03:23:15 +00:00
soren 7ea4a2b744 Fix RCS ID line. 2000-05-21 02:51:58 +00:00
soren b70819c71a Also share BE ldscripts. 2000-05-21 02:50:10 +00:00
soren 135a70e5a6 Make cache printing a little more consistent. 2000-05-17 23:35:44 +00:00
soren 740759113f mips5200_FlushCache(): flush L2 cache too. 2000-05-17 12:44:48 +00:00
nisimura 66ecdc15d3 Remove unused PSL_USERCLR defines for processor status register. 2000-05-15 08:36:32 +00:00
nisimura 8a71a7a50f Backout the previous change which was done mistakenly. 2000-05-15 06:45:44 +00:00
nisimura c7c815f46b Remove #include <machine/psl.h> which is not used. 2000-05-15 06:39:14 +00:00
castor 42ccab0d49 Add fp emulation for sqrt_s and sqrt_d instructions
from Jeff Smith <jeffs@geocast.com>.  These are needed to support
-mips2 compilation.  With this change, on a QED 5231 we now pass the
paranoia tests, and are successfully using userlands built with -mips2.
2000-05-14 06:19:32 +00:00
nisimura df234d8698 Take a straight way for pagemove() PTE manipulation, abandoning to
use MIPS_TBRPL().  When PTEs are modified, both src and dst TLBs
are invalidated.  MIPS3 single TLB entry has paired double PTE
and pagemove() likely walks through multiple pages.  The positive
effect of of MachTLBUpdate() or TBRPL() is unclear.
2000-05-10 08:55:22 +00:00
nisimura de13b44edd Have mips_locoresw[] of 3 entry pointer array for different
implementation of locore routines between MIPS1 and MIPS3.  It's
independent from mips_locore_jumpvec_t which is for cache/TLB
manipulating routines peculiar to processor designs.  mips_locore_jumpvec_t
will be replaced with "processor closures" encapsulating implementation
parameters (cpuinfo) and pointers to conventaion routines (cpuops),
eventually.
2000-05-10 01:34:13 +00:00
shin a7dd7a7c0c bugfix: make sure there is no valid data in data cache, when last
mapping to the physical page is removed (R3000/MIPS1).

delete cache operations in pmap_zero_page_uncached().
2000-05-09 13:40:13 +00:00
nisimura 34a943161d Introduce mips3_TBRPL(); not used in this moment, to be useful to
discard MachTLBUpdate() calls, however, the necessity of TLB entry
modification in such a way is under question because implementation
glitches on ASID management was straightened, those calls can be
sanely removed after all.
2000-05-09 09:50:17 +00:00
nisimura 0cb6da487c Remove unused mapin(pte, v, pfnum, prot) macro. 2000-05-06 05:19:32 +00:00
thorpej 855b79db92 Let each platform typedef the new __cpu_simple_lock_t, which should
be the most efficient type used for the atomic operations in the
simplelock structure, and should also be __volatile.
2000-05-02 04:41:04 +00:00
soren e038e8aac1 No need for flushing the cache after zeroing a page uncached. 2000-04-30 23:30:47 +00:00
simonb 21666d1ea5 Only call uvm_pageidlezero() if uvm.page_idle_zero is set. 2000-04-30 23:01:24 +00:00
simonb 0ba4762798 Define offset for uvm.page_idle_zero. 2000-04-30 22:56:12 +00:00
soren f820567ce2 Allow non-pmax to use COMPAT_ULTRIX. 2000-04-29 21:47:13 +00:00
soren 082109d0e4 Move free page zeroing to before the whichqs spinner. Pointed out by simonb. 2000-04-29 14:44:42 +00:00
thorpej f51470a514 Require that each each MACHINE/MACHINE_ARCH supply a lock.h. This file
contains the values __SIMPLELOCK_LOCKED and __SIMPLELOCK_UNLOCKED, which
replace the old SIMPLELOCK_LOCKED and SIMPLELOCK_UNLOCKED.  These files
are also required to supply inline functions __cpu_simple_lock(),
__cpu_simple_lock_try(), and __cpu_simple_unlock() if locking is to be
supported on that platform (i.e. if MULTIPROCESSOR is defined in the
_KERNEL case).  Change these functions to take an int * (&alp->lock_data)
rather than the struct simplelock * itself.

These changes make it possible for userland to use the locking primitives
by including <machine/lock.h>.
2000-04-29 03:31:45 +00:00
soren 2cfb26c801 Zero free pages in the idle loop. 2000-04-28 19:25:55 +00:00
shin a332af2846 delete unused function mips3_TLBReadVPS().
reorder insns to avoid mtc0/mfc0 hazard (for VR4100/R4700/RM52xx).
save/restore PageMask in mips3_TLBRead().
2000-04-21 14:14:55 +00:00
shin e2711a6552 make it compile with -DDEBUG. 2000-04-21 14:10:39 +00:00
nisimura 79733cb614 Effort to have consistent comments, fixing one error. 2000-04-21 02:45:01 +00:00
nisimura 3d5a5b03f5 - Address PR#9907. u_pte[1] wired down is left not global sometimes.
The brokenness is revealed sporadorically by memory usage on runtime.
- Avoid Vr4100 incompatibilty by making sure to retain default pgMask
  value for TLB invalidation routines.
2000-04-21 02:39:55 +00:00
nisimura a01973aecb Change the way how pmap_protect() modifies the protection of KSEG2
space using MIPS_TBRPL() call.  It avoils to 'vistimize' a possibly
useful TLB entry. XXX MachTLBUpdate() will be retired, soon.
2000-04-16 10:16:19 +00:00
nisimura 8feff14832 Fix a typo in the previous change. 2000-04-16 10:08:32 +00:00
nisimura 4edcc4fca2 Change the way to implement zero copy data move in pagemove() using
MIPS_TBRPL().  It saves about 20 instructions to run for each
iteration, and avoids TLB polution.  Currently works for MIPS1 only
configuration.
2000-04-16 09:09:42 +00:00
nisimura 7717409808 Introduce MIPS_TBRPL() which replaces a TLB entry of given vaddr
with new entryHi and entryLo pair iff found in TLB.  Works only
for KSEG2 this moment.  mips3 version will follow.
2000-04-16 09:00:26 +00:00
soda c56a43535d remove following symbols which became unnecessary in recent cpu_intr() change:
mips_hardware_intr
	MIPS3_INTERNAL_TIMER_INTERRUPT
	mips3_intr_cycle_count
	mips3_timer_delta
2000-04-15 22:05:51 +00:00
nisimura e54e10f9ce - Withdraw dealfpu() code which has been never useful so far.
- XXX It was a mistake to add CP1 insn encoding values into cpuregs.h.
  Those will be relocated into mips_opcode.h with some adjustment work.
2000-04-15 06:21:01 +00:00
soren 0ce39b7430 Typo; user stack only needs to start one page below 0x80000000. 2000-04-13 22:02:54 +00:00
nisimura ce0937324b - Move a loop invariant of 'if (CPUISMIPS3)' out of pagemove().
- XXX I'm not sure whether the anticipatory MachTLBUpdate(to, pte) is
  a gain or loss on runtime.  If not a loss, it should be MIPS_TBIS().
2000-04-12 01:37:58 +00:00
nisimura 85f3855a8c - Implement mips3_TBIAP().
- Remove obsoluted routines in locore_mips3.S
- addiu -> addu, andi -> and, ori -> or.
2000-04-12 01:05:34 +00:00
castor 4ebaf4d105 Taken from Jeff Smith <jeffs@geocast.com>:
Fix regress/lib/libc/ieeefp/except for MIPS.  Newer FPE handling code
	did not generate SIGFPE, but always SIGILL.  Add this back to the
	assembly code.  The QED 5231 requests the kernel emulates some of
	the conditions that generate an SIGFPE, but when the emulation code
	did a ctc1 to fsr with an exception the kernel got a FPE in kernel mode.
	Fix this by saving the fp regs earlier, then saving the new FSR in
	the context.  This allows the FSR value to be seen by the SIGFPE
	handler.

	Add fp emulation for 8 mips2 fpu instructions to handle exceptions
	(round.w.fmt, trunc.w.fmt, ceil.w.fmt, floor.w.fmt).  This lets
	perl5 run when compiled -mips2.
2000-04-11 16:28:05 +00:00
nisimura aa4f967e51 Abandon rather random distinctions in andi/addiu coding and make
them consistent with and/addu instrunction mnemonics which produce
exactly same binaries.
2000-04-11 04:53:57 +00:00
nisimura dba7b560cd Load delay slot is automagically adjusted at runtime since MIPS II
architecture.
2000-04-11 04:39:14 +00:00
chs a6d33cc1f2 add a new function vn_marktext() for exec code to let others know
that the vnode is now being used as process text.
2000-04-11 04:37:47 +00:00
nisimura e342080364 Introduce cpu_intr() whose body is now provided by target ports in
their own ways.  Ugly fixup #define in machine/intr.h have gone.
mips_hardware_intr global variable patch work has gone.
2000-04-11 02:30:14 +00:00
nisimura 4f3093c121 Remove various TLB manipulation routines which have been unused
long time, commented out and is unlikely useful; TLBWriteIndexed(),
TLBWriteRandom(), TLBFlush(), TLBFlushPID() and TLBFind().
2000-04-11 01:32:19 +00:00
nisimura 53e7a8c8d5 - Fix a bug in mips1_TBIAP() misbehaving like as mips1_TBIA().
- Adjust comments to reflect what it does.
2000-04-10 11:38:16 +00:00
simonb 3d6b29f228 Use UVM_PGA_ZERO in uvm_pagealloc() calls instead of using pmap_zero_page(). 2000-04-10 08:50:20 +00:00
nisimura ea23dc6364 Make sure ASID management is done in the same way of NetBSD/alpha. Rename
and change 'pmap_alloc_asid()' into 'pmap_asid_alloc()'
2000-04-10 05:34:27 +00:00