Commit Graph

77347 Commits

Author SHA1 Message Date
Peter Wemm
f1b665c8fe Revive backed out pmap related changes from Feb 2002. The highlights are:
- It actually works this time, honest!
- Fine grained TLB shootdowns for SMP on i386.  IPI's are very expensive,
  so try and optimize things where possible.
- Introduce ranged shootdowns that can be done as a single IPI.
- PG_G support for i386
- Specific-cpu targeted shootdowns.  For example, there is no sense in
  globally purging the TLB cache for where we are stealing a page from
  the local unshared process on the local cpu.  Use pm_active to track
  this.
- Add some instrumentation for the tlb shootdown code.
- Rip out SMP code from <machine/cpufunc.h>
- Try and fix some very bogus PG_G and PG_PS interactions that were bad
  enough to cause vm86 bios calls to break.  vm86 depended on our existing
  bugs and this was the cause of the VESA panics last time.
- Fix the silly one-line error that caused the 'panic: bad pte' last time.
- Fix a couple of other silly one-line errors that should have caused more
  pain than they did.

Some more work is needed:
- pmap_{zero,copy}_page[_idle].  These can be done without IPI's if we
  have a hook in cpu_switch.
- The IPI handlers need some cleanup.  I have a bogus %ds load that can
  be avoided.
- APTD handling is rather bogus and appears to be a large source of
  global TLB IPI shootdowns for no really good reason.

I see speedups of between 1.5% and ~4% on buildworlds in a while 1 loop.
I expect to see a bigger difference when there is significant pageout
activity or the system otherwise has memory shortages.

I have backed out a few optimizations that I had been using over the last
few days in order to be a little more conservative.  I'll revisit these
again over the next few days as the dust settles.

New option:  DISABLE_PG_G - In case I missed something.
2002-07-12 07:56:11 +00:00
Tim J. Robbins
90833c99de Complain if more than one file argument is given to unlink(1) like we did
before I made unlink use getopt().
2002-07-12 07:20:20 +00:00
Alfred Perlstein
d11a56617d regen for freebsd4_sendfile(2) compat. 2002-07-12 06:52:44 +00:00
Alfred Perlstein
9c34129662 Create a bug-for-bug FreeBSD4 compatible version of sendfile and move the
fixed sendfile over.  This is needed to preserve binary compatibility from
4.x to 5.x.
2002-07-12 06:51:57 +00:00
Alfred Perlstein
074453c230 Introduce syscall.master option 'COMPAT4' which allows one to wrap
syscalls for FreeBSD 4 compatibility.
Add kernel option COMPAT_FREEBSD4 to enable these syscalls.
2002-07-12 06:38:34 +00:00
Peter Wemm
4a0226c633 Unexpand a couple of 8-space indents that I added in rev 1.285. 2002-07-12 04:58:51 +00:00
Peter Wemm
a7e9138e37 Avoid a vm_page_lookup() - that uses a spinlock protected hash. We can
just use the object's memq for our nefarious purposes.
2002-07-12 04:38:51 +00:00
Alan Cox
7538e5500d o Lock some (unfortunately, not yet all) accesses to the page queues. 2002-07-12 03:17:22 +00:00
Alan Cox
60e15726af o Lock accesses to the page queues. 2002-07-12 02:55:55 +00:00
Kenneth D. Merry
a720097d24 Fix compilation with ENABLE_VFS_IOOPT turned on and ZERO_COPY_SOCKETS
turned off.

Clean up #ifdefs, and remove a bunch of unnecessary includes.

Reviewed by:	bde
Tested by:	netchild
2002-07-12 02:23:55 +00:00
Giorgos Keramidas
b11b570d7b Don't duplicate the description of the sticky bit that is already
part of chmod(2) and sticky(8), but refer to those manpages instead.

PR:		docs/35605
Submitted by:	Gary W. Swearingen <swear@blarg.net>
2002-07-12 01:57:44 +00:00
Garance A Drosehn
cc2b61b1dd Call routine to free everything obtained when filling in 'struct printer'.
MFC after:	3 days
2002-07-12 01:53:36 +00:00
Garance A Drosehn
722915cdec Fix set_qstate() so it correctly checks for any error from chmod().
Note that set_qstate() is only called from several 'lpc' commands.

MFC after:	3 days
2002-07-12 01:37:06 +00:00
Garance A Drosehn
4c2a399167 Add a SQS_QCHANGED option to set_qstate(). This will soon be used by 'lpc'.
Reviewed by:	freebsd-print@bostonradio.org
MFC after:	3 days
2002-07-12 01:31:46 +00:00
Giorgos Keramidas
079167d6d7 Various typo fixes.
PR:		docs/39395
Submitted by:	Rich Neswold <rneswold@ameritech.net>
2002-07-12 01:30:18 +00:00
Garance A Drosehn
bae8d45c7f Add two variables to struct jobqueue, and change the way that getq()
calculates how much space to get for that struct, so it will get the
right amount when new variables are added.

MFC after:	3 days
2002-07-12 01:22:57 +00:00
David E. O'Brien
568fc330a7 Yep, revision 1.3 was 1/2assed.
This time use the right attribute for null_format_ok.

Submitted by:	bde
2002-07-12 00:49:52 +00:00
Garance A Drosehn
d6771428c4 Move prototypes for ctl_readcf and ctl_freeinf from ctlinfo.c to ctlinfo.h,
so the routines can be called by an upcoming change for 'lpc topq/bottomq'.

MFC after:	3 days
2002-07-12 00:33:07 +00:00
Don Lewis
0e1eebb846 Defer calling SYSCTL_OUT() until after the locks have been released. 2002-07-11 23:18:43 +00:00
Don Lewis
142b2bd644 Reduce the nesting level of a code block that doesn't need to be in
an else clause.
2002-07-11 23:13:31 +00:00
Garrett Wollman
4f6799e61e A simple implementation of statvfs(3) (one step above the trivial one).
Not yet connected to the build (awaiting documentation).
2002-07-11 22:54:11 +00:00
Alfred Perlstein
39d4ee3fee WARNS=2, de-__P() 2002-07-11 22:50:36 +00:00
Julian Elischer
5e3da64ee9 Remove debugging code that I originally only wanted to be there for a couple of days after merge.
Reminded with pointy stick by: jhb
2002-07-11 22:47:58 +00:00
Alfred Perlstein
1fb354a1b2 WARNS=4, de-__P() 2002-07-11 22:29:11 +00:00
Alfred Perlstein
62947a57cc Update manpages to reference 'timed' rpc functions 2002-07-11 22:25:16 +00:00
Alfred Perlstein
54b60d7e15 Fix indentation broken in previous __P removal.
Grumbled about by: bde
2002-07-11 22:18:26 +00:00
John Baldwin
78dee2638a thread_exit() requires PROC_LOCK to be held, so lock it. 2002-07-11 22:13:33 +00:00
Alfred Perlstein
7fa658d98b WARNS=4, de-__P() 2002-07-11 22:11:20 +00:00
John Baldwin
eb80408cff Add a missing newline during panic printf's for SMP systems that don't
have APICS.  (Like all the !i386 archs).
2002-07-11 21:56:37 +00:00
Juli Mallett
a1baa5130d Remove unused variables due to libufs(3) commit. Clean up extraneous use of
semicolon at closing paren of a function body.
2002-07-11 21:46:12 +00:00
Juli Mallett
d67caa29ef Convert dumpfs(8) to libufs(3), rather than rolling local functions for a
number of things.
2002-07-11 21:44:03 +00:00
Alfred Perlstein
261755738e WARNS=4, de-__P() 2002-07-11 21:40:15 +00:00
Alfred Perlstein
c8c710fd85 de-__P() 2002-07-11 21:28:16 +00:00
Juli Mallett
cf6c0643ee Fill out (zero) and fill in (when doing getino()) the minimum and maximum
inodes in our inoblock (disk->d_ino{min,max}) appropriately.
2002-07-11 21:27:26 +00:00
Alfred Perlstein
d8c965959f WARNS=4, de-__P() 2002-07-11 21:26:41 +00:00
Joerg Wunsch
e97f67f532 Complete rewrite, once again.
This is basically a ``C compilation'' of the former whereis.pl file,
employing the same algorithms, and aiming at being mostly
UI-compatible to the old (legally tainted) 4.3BSD whereis(1).  In
comparision, the 4.4BSD-Lite version is just another variant of
which(1) only, where in particular the option to search for source
directories is sorely missing.

While i was at it, i added two more options which i contemplated doing
long since.  -x will suppress the run of locate(1) to find sources
that could not be found otherwise, potentially saving a lot of time
(but obviously, risking to not find some sources that are well hidden
in the tree).  -q will omit the leading name of the query, so in
particular, you can now do something like:

	cd `whereis -qs ls`

I'd explicitly like to thank johan for his review which was quite a
bit more than an average review, including sending me a lot of diffs.

Reviewed by:	johan
2002-07-11 21:20:54 +00:00
Alfred Perlstein
f251a0df8b WARNS=4 2002-07-11 21:18:55 +00:00
Alfred Perlstein
2f9af24198 WARNS=4 cleanup, de-__P() 2002-07-11 21:16:52 +00:00
Alfred Perlstein
65f507d197 de-__P() 2002-07-11 21:13:37 +00:00
Tom Rhodes
299f15612e Add a bit of information on FFS snapshots to the mount(8) manual page.
PR:		30139
Submitted by:	Chris Knight <chris@aims.com.au?
MFC after:	3 days
2002-07-11 21:12:45 +00:00
Alfred Perlstein
4f5d913371 WARNS?=4 cleanup. 2002-07-11 21:12:18 +00:00
Giorgos Keramidas
1a7a931a26 Add note about the info documentation of diff(1).
It contains a detailed description of the =format option part.

PR:		docs/36464
Submitted by:	Gary W. Swearingen <swear@blarg.net>
2002-07-11 21:11:26 +00:00
Alfred Perlstein
b6528e647b de-__P() 2002-07-11 20:53:56 +00:00
Bruce Evans
35f2bab629 Fixed misspelling of "hint." as "hints." in rp's hints. 2002-07-11 20:47:56 +00:00
Bruce Evans
b147fcf936 Fixed misspelling of "hint." as "hints." in the description of the "hint."
keyword and in the description of rp's hints.

Didn't fix rp's hints being mostly in comments so that they are harder to
use (they don't get linted either way because makeLINT.sh strips them and
there is no compile-time syntax checking of hints anyway).
2002-07-11 20:43:37 +00:00
David E. O'Brien
3cc44e2238 RELENG_4_6 PL 1 libc bits with non-vulnerable resolver.
Security Advisory:	FreeBSD-SA-02:28.resolv
2002-07-11 20:40:24 +00:00
Bruce Evans
6c0b854cf9 Improved wording in the descriptions of hints. In particular, don't start
a new paragraph for describing the hints associated with each card type.

Reviewed by:	ru
2002-07-11 20:24:58 +00:00
Giorgos Keramidas
d2a4ebc11d Mention zegrep and zfgrep too,
and what their equivalent grep options are.

PR:		docs/35603
Submitted by:	"Gary W. Swearingen" <swear@blarg.net>
2002-07-11 20:12:15 +00:00
Robert Drehmel
94fed363fe Use the length modifier 'l' when supplying an argument of
type long to printf(3).
2002-07-11 20:10:07 +00:00
Robert Drehmel
a89c0b2458 - Remove unnecessary inclusion of <utmp.h>.
- Cast a value to time_t before comparing it to another
   time_t to fix a warning.
2002-07-11 20:01:36 +00:00