Mike Barcroft [Fri, 8 Mar 2002 03:09:46 +0000 (03:09 +0000)]
Use a integral type that doesn't require <sys/types.h>. This
accomplishes the goal of actually making <grp.h> independent of other
headers for the definition of its types.
Matt Jacob [Thu, 7 Mar 2002 17:32:45 +0000 (17:32 +0000)]
Disable RIO (reduced interrupt operation) for 2200 boards- it seemed like
it worked- but I ran into a case with a 2204 where commands were being lost
right and left. Best be safe.
For target mode, or things called if we call isp_handle_other response- note
that we might have dropped locks by changing the output pointer so we bail
from the loop. It's the responsibility of the entity dropping the lock to
make sure that we let the f/w know we've read thus far into the response
queue (else we begin processing the same entries again- blech!).
Jake Burkholder [Thu, 7 Mar 2002 06:01:40 +0000 (06:01 +0000)]
Implement delivery of tlb shootdown ipis. This is currently more fine grained
than the other implementations; we have complete control over the tlb, so we
only demap specific pages. We take advantage of the ranged tlb flush api
to send one ipi for a range of pages, and due to the pm_active optimization
we rarely send ipis for demaps from user pmaps.
Remove now unused routines to load the tlb; this is only done once outside
of the tlb fault handlers.
Minor cleanups to the smp startup code.
This boots multi user with both cpus active on a dual ultra 60 and on a
dual ultra 2.
Jake Burkholder [Thu, 7 Mar 2002 05:25:15 +0000 (05:25 +0000)]
Modify the tlb demap API to take a pmap instead of a tlb context number.
Due to allocating tlb contexts on the fly, we only ever need to demap the
primary context, non-primary contexts have already been implicitly flushed
by context switching. All we really need to tell is if its a kernel demap
or not, and its easier just to compare against the kernel_pmap which is a
constant.
Jake Burkholder [Thu, 7 Mar 2002 05:15:43 +0000 (05:15 +0000)]
Implement kthread context stealing. This is a bit of a misnomer because
the context is not actually stolen, as it would be for i386. Instead of
deactivating a user vmspace immediately when switching out, and recycling
its tlb context, wait until the next context switch to a different user
vmspace. In this way we can switch from a user process to any number of
kernel threads and back to the same user process again, without losing any
of its mappings in the tlb that would not already be knocked by the automatic
replacement algorithm. This is not expected to have a measurable performance
improvement on the machines we currently run on, but it sounds cool and makes
the sparc64 port SMPng buzz word compliant.
Mike Silbersack [Thu, 7 Mar 2002 04:50:36 +0000 (04:50 +0000)]
Unconditionally limit maxproc so that it is not possible
to exhaust all kmaps. The only reward for setting maxproc
to a value which will cause kmap exhaustion is a panic
during a forkbomb attack.
Matthew Dillon [Thu, 7 Mar 2002 03:54:56 +0000 (03:54 +0000)]
Fix a bug in the vm_map_clean() procedure. msync()ing an area of memory
that has just been mapped MAP_ANON|MAP_NOSYNC and has not yet been accessed
will panic the machine.
Peter Pentchev [Wed, 6 Mar 2002 16:49:02 +0000 (16:49 +0000)]
Unbreak the pam_krb5 build: cast a couple of const pointers
to normal char *. A better fix might be some const'ifying
of the Heimdal code, but this will do to fix the build
for the present.
Rename runq_find() to runq_findproc(), and hide it behind #ifdef DIAGNOSTIC,
as it can have a severe impact on performance under high load, and the bug
it was meant to catch was fixed ages ago.
Bruce Evans [Wed, 6 Mar 2002 11:25:58 +0000 (11:25 +0000)]
Support runtime specification of the history counter type by whatever
generated the gmon data. The support is currently limited to what is
easy to implement and/or needed:
signedess: signed or insigned
size: 8, 16, 32 or 64 bits
format: a binary integer in gprof's format (gprof is not a cross-tool).
High-resolution kernel profiling uses signed 64-bit counters. Normal
kernel profiling and user profiling use unsigned 16-bit counters but
should use 32-bit ones.
Bruce Evans [Wed, 6 Mar 2002 09:47:36 +0000 (09:47 +0000)]
Fixed some misspellings of 2 as sizeof(UNIT) so that they won't break
things when sizeof(UNIT) becomes a runtime parameter. The relevant 2
is the one in profil(2)'s scaling of pc's to bucket numbers:
bucket = (pc - offset) / 2 * profil_scale / 65536
gprof(1) must duplicate this scaling, bug for bug compatibly, so it
must first do an integer division by 2 although this mainly makes
scales larger than 65536 useless. sizeof(UNIT) was already wrong in
gprof4, but there were no problems because the fake profil scale is a
multiple of 2.
There are also some rounding bugs in the scaling, but these are only
problems if profil(2) is used directly to create unusual (and not
useful) scales.
Bruce Evans [Wed, 6 Mar 2002 06:33:33 +0000 (06:33 +0000)]
Fixed a printf format error again. Rev.127 was clobbered in rev.1.128
by removing parentheses. The main bug is in gcc: on machines with
64-bit longs and 64-bit long longs,
(unsigned long long)rdp->total_sectors / ((1024L * 1024L) / DEV_BSIZE))
has type plain unsigned long instead of the correctly promoted type
unsigned long long, so it can not be printfed using %llu format. Even
1ULL / 1L is mispromoted. Anyway, casting the correct operand
automatically avoids the problem. We do not want to to pessimize the
division; we just want to convert to a common maximal type for printing.
Matthew Dillon [Wed, 6 Mar 2002 02:42:56 +0000 (02:42 +0000)]
Add a sequential iteration optimization to vm_object_page_clean(). This
moderately improves msync's and VM object flushing for objects containing
randomly dirtied pages (fsync(), msync(), filesystem update daemon),
and improves cpu use for small-ranged sequential msync()s in the face of
very large mmap()ings from O(N) to O(1) as might be performed by a database.
A sysctl, vm.msync_flush_flag, has been added and defaults to 3 (the two
committed optimizations are turned on by default). 0 will turn off both
optimizations.
This code has already been tested under stable and is one in a series of
memq / vp->v_dirtyblkhd / fsync optimizations to remove O(N^2) restart
conditions that will be coming down the pipe.
Bruce A. Mah [Tue, 5 Mar 2002 22:39:51 +0000 (22:39 +0000)]
New release notes: CPU_ATHLON_SSE_HACK, ufm driver (+ MFC),
awk is BWK awk for sparc64, ctags(1) works for files with C++ comments
(+ MFC), dump(8) -s, last(1) -y, lint update/import from NetBSD.
Switch to OpenPAM. Bump library version. Modules are now versioned, so
applications linked with Linux-PAM will still work.
Remove pam_get_pass(); OpenPAM has pam_get_authtok().
Remove pam_prompt(); OpenPAM has pam_{,v}{error,info,prompt}().
Remove pam_set_item(3) man page as OpenPAM has its own.