Commit Graph

37827 Commits

Author SHA1 Message Date
thorpej dbc7bbee68 Make the previous change `atomic'. 1998-03-19 06:37:26 +00:00
thorpej daade671ae When unsharing or execing, deactivate the old vmspace before reassigning
and activating the new one.  Pointed out by Chris Demetriou.
1998-03-19 04:19:21 +00:00
ross ac5774c288 Fix a 64-bit pointer/int warning. 1998-03-19 03:42:35 +00:00
kml 9433195784 Add support for a '-b' option to provide byte counts in and out,
instead of just packet counts.  On the byte screens, errors and
collisions are not shown, since they are more packet count related.
1998-03-19 02:42:57 +00:00
thorpej 7eed6ad8d8 Bring in bsd.own.mk to get the definition of BSDSRCDIR before checking
to see if it's defined.
1998-03-19 00:08:25 +00:00
thorpej cc934bdb2c Pull in bsd.own.mk to get a number of things right. 1998-03-19 00:07:27 +00:00
thorpej 003c50d1d5 Add a macro to invalidate the TLB for a given pmap/va pair. TLB
invalidation algorithm:

	if (old mapping had PG_ASM set || pmap is active) {
		TIBS(va);
		if (also sync I-stream)
			imb();
	}

The check for "old mapping had PG_ASM" will get all kernel mappings (since
kernel mappings always have PG_ASM set).

This allows us to remove the bogus check for the kernel pmap in
active_pmap() - do so.

Use the new TLB invalidation macro whenever such action is needed.
1998-03-18 23:55:25 +00:00
pk d47d43b956 Use file size from fstat(2) to map the hints file, instead of fiddling
with incremental mmap()'s.  Squashes a bug which caused only the first
page of the hints file to unmapped.
1998-03-18 23:21:46 +00:00
thorpej 15adb17803 Eliminate the last argument from pmap_remove_mapping(); it makes its own
decisions about TLB invalidation.
1998-03-18 23:11:44 +00:00
thorpej 7ee4af11a7 Change active_pmap() to use the CPU mask (XXX and check for kernel pmap
as well, until some other changes are made).  Nuke active_user_pmap(),
and change the places that used it to use active_pmap() instead (as well
as make some DIAGNOSTIC consistency checks).
1998-03-18 22:50:50 +00:00
is ddc5b81d4f 68060 has 8k + 8k caches. 1998-03-18 22:19:40 +00:00
thorpej 605472f676 Optimize out a TLB invalidation in a common case of pmap_enter(): if
the PTE was previously invalid, no TLB invalidation is necessary because:

	(1) when a PTE is invalidated, its entry is flushed from the
	    TLB

	(2) the PALcode won't install an invalid PTE into the TLB.
1998-03-18 22:13:58 +00:00
matthias e14a1c1120 Switch the pc532 to MACHINE_NEW_NONCONTIG and add machine specific bits
for UVM. All of this was mostly done by stealing code from the i386 port.
Prepare for stealing pmap.new.c as well.
1998-03-18 21:59:38 +00:00
thorpej cfdf9a95ad Keep track of which CPUs are using a pmap by setting/clearing bits
in the pmap's CPU mask in pmap_activate()/pmap_deactivate().
1998-03-18 21:57:03 +00:00
matthias 214f303d0e Import from i386 because it contains a nice explanation of our MMU. 1998-03-18 21:52:02 +00:00
tv c70676bb18 PR #2736: wrap the softc in #ifdef _KERNEL so userland can include this
file to get at the ioctl values without barfing on the softc
1998-03-18 21:21:48 +00:00
thorpej 43614761e3 In cpu_exit() deactivate the address space before freeing the vmspace
structure.  We will continue to run on this context (which is the
global Lev1map at this point) right up until we switch to proc0's
context in switch_exit().
1998-03-18 20:38:07 +00:00
thorpej 87eb2cfded Don't call pmap_deactivate() if we jumped into the middle of cpu_switch()
from switch_exit(), since by this time, the vmspace will have already
been deactivated and freed.
1998-03-18 20:36:13 +00:00
tv 902d175a04 PR 5170: don't fclose twice, or call ferror after fclose.
required removing fcloses and/or moving them, nulling the pointers
like they should have been, and adding a terminating null byte and break
in one case (perhaps we never ran into those problems before).
cgetclose() already does a fclose and null of the pointer, so don't
duplicate it when we don't need to.
1998-03-18 20:29:27 +00:00
thorpej b637a998f4 Add ASN housekeeping and a CPU mask to the pmap. 1998-03-18 19:39:23 +00:00
thorpej 961a955498 Move the "are we active" macros out of the header file. 1998-03-18 19:27:46 +00:00
christos d8bd192855 PR/4941: Greg Oster: Don't byte swap; it is not needed. This broke big
endian machines.
1998-03-18 19:22:12 +00:00
thorpej d37acae24c Add a DIAGNOSTIC checks for the kernel pmap in pmap_create_lev1map()
and pmap_destroy_lev1map().  Correct a comment in another DIAGNOSTIC
panic.
1998-03-18 19:21:50 +00:00
thorpej 06b49b8f3e Change a couple of assert()s to DIAGNOSTIC panics. 1998-03-18 19:12:57 +00:00
thorpej 438599b408 Correct a comment in pmap_bootstrap(). 1998-03-18 19:04:42 +00:00
thorpej 56e004c995 Pass the max ASN from the HWRPB to pmap_boostrap(). 1998-03-18 19:02:49 +00:00
thorpej 426d2953f5 Add a macro to test if PG_ASM (Address Space Match) is set in a PTE. 1998-03-18 19:00:15 +00:00
bouyer 67010392f2 Add support for non-native byteorder FFS.
The quota file is still in host byteorder. quotacheck needs to be re-run
when a FS has been moved to an architecture to another. Running quota
on a non-native byteorder ffs is considered a marginal case.
1998-03-18 17:22:38 +00:00
bouyer 8e1f7e498a Add support for non-native byteorder FFS. 1998-03-18 17:19:14 +00:00
bouyer d1c8f32096 Update for new headers. 1998-03-18 17:18:21 +00:00
bouyer a29032bc40 Document the 'FFS_EI' option. 1998-03-18 17:17:06 +00:00
bouyer 3f0a6fcc9b Update for new headers. 1998-03-18 17:11:34 +00:00
bouyer 15c41b2f72 Allow creation of non-native byteorder FFS (via the '-B' option). 1998-03-18 17:10:15 +00:00
bouyer c0892a3052 Add support for non-native byteorder FFS. 1998-03-18 17:07:14 +00:00
bouyer aca8393893 This is now in libutil. 1998-03-18 17:03:30 +00:00
bouyer 6fe0568e9e Add support for non-native byteorder FFS. 1998-03-18 17:03:15 +00:00
bouyer 9aaa32d9a7 Add support for non-native byteorder FFS, and converting byteorder.
Also, be a bit more conservative with the clean flag: don't mark the FS
clean when we know there may still be errors (user anserwed 'n' to
a question, or fsck says "you must rerun fsck").
1998-03-18 17:01:23 +00:00
bouyer 9e33c5ee0d Use libutil rather than ../fsck/bswap.c 1998-03-18 16:57:31 +00:00
bouyer 34ccbd430c Add support for non-native byte order FFS. The dump is in filesystem byte
order, restore already knows how to byteswap dumps.
1998-03-18 16:54:56 +00:00
bouyer 08371645ee Add support for non-native endian FFS.
Clear the clean flag in the SB when an inode has been cleared.
1998-03-18 16:51:31 +00:00
bouyer 29e97528a5 Add support for non-native endian ffs. 1998-03-18 16:50:12 +00:00
bouyer 50660fb787 Add bswap{16,32,64} functions to libutil. Because of this, bump minor. 1998-03-18 16:40:45 +00:00
bouyer 9f50fca1fd Add commented out "options FFS_EI" 1998-03-18 16:34:41 +00:00
bouyer 091dafd39f Add support for reading/writing FFS in non-native byte order, conditioned
to "options FFS_EI". The superblock and inodes (without blk addr) are
byteswapped at disk read/write time, other metadatas are byteswapped
when used (as they are acceeded directly in the buffer cache).
This required the addition of a "um_flags" field to struct ufsmount.
ffs_bswap.c contains superblock and inode byteswap routines also used
by userland utilities.
1998-03-18 15:57:26 +00:00
thorpej 63dfa5e1a1 Minor cosmetic cleanup; no functional change. 1998-03-18 07:18:50 +00:00
thorpej 86d534a7d9 - Make MACHINE_NEW_NONCONTIG non-optional.
- Maintain two copies of the number and size of physical memory segments.
  One copy, mem_clusters[], contains _all_ of physical RAM, for crash dumps.
  The other copy, phys_seg_list[], starts out with all of physical RAM (and
  is used to initialize mem_clusters[]), but is adjusted to be the memory
  actually managed by the VM system.
- Fix computation of physmem; when support for MACHINE_NEW_NONCONTIG was
  added, physmem was accidentally changed to not take into account the memory
  located before the kernel, or the memory taken up by the kernel itself.
1998-03-18 07:16:10 +00:00
thorpej 02fa4134dc - Make MACHINE_NEW_NONCONTIG non-optional.
- G/C some things left over from the old noncontig code.
1998-03-18 07:12:49 +00:00
thorpej c718c9e278 - Make MACHINE_NEW_NONCONTIG non-optional.
- Make initialization of the message buffer a little less magic-looking.
- Maintain two copies of the number and size of physical memory segments.
  One copy, mem_clusters[], contains _all_ of physical RAM, for crash dumps.
  The other copy, phys_seg_list[], starts out with all of physical RAM (and
  is used to initialize mem_clusters[]), but is adjusted to be the memory
  actually managed by the VM system.
- Fix crash dumps with regard to multiple memory segments.
1998-03-18 07:11:22 +00:00
thorpej c0cfbf8d7d Make MACHINE_NEW_NONCONTIG non-optional. 1998-03-18 07:07:11 +00:00
mikel 1dae4d16e9 (8C) -> (8) 1998-03-18 06:42:32 +00:00