dragonfly.git
18 years agoSwitch to building a libgdb and both gdb and kgdb.
Simon Schubert [Tue, 7 Mar 2006 15:48:11 +0000 (15:48 +0000)]
Switch to building a libgdb and both gdb and kgdb.

Gdb -k doesn't work anymore and was replaced by kgdb, which was imported in
large parts from FreeBSD.

Add a kernel variable indicating with thread is dumping.

18 years agoAdd missing argument.
Sascha Wildner [Mon, 6 Mar 2006 03:21:26 +0000 (03:21 +0000)]
Add missing argument.

18 years agoDon't modify p twice betweeen sequence points.
Sascha Wildner [Mon, 6 Mar 2006 03:10:51 +0000 (03:10 +0000)]
Don't modify p twice betweeen sequence points.

18 years agoFix typos:
Sascha Wildner [Mon, 6 Mar 2006 02:54:12 +0000 (02:54 +0000)]
Fix typos:

_ISO_C_VISIBLE -> __ISO_C_VISIBLE

_POSIX_VISIBLE -> __POSIX_VISIBLE

18 years agoRoll 1.5.1 for the slip tag
Matthew Dillon [Sun, 5 Mar 2006 18:44:14 +0000 (18:44 +0000)]
Roll 1.5.1 for the slip tag

18 years agoReplace the global buffer cache hash table with a per-vnode red-black tree.
Matthew Dillon [Sun, 5 Mar 2006 18:38:39 +0000 (18:38 +0000)]
Replace the global buffer cache hash table with a per-vnode red-black tree.
Add a B_HASHED b_flags bit as a sanity check.  Remove the invalhash junk
and replace with assertions in several cases where the buffer must already
not be hashed.  Get rid of incore() and gbincore() and replace with a new
function called findblk().

Merge the new RB management with bgetvp(), the two are now fully integrated.

Previous work has turned reassignbuf() into a mostly degenerate call, simplify
its arguments and functionality to match.  Remove an unnecessary reassignbuf()
call from the NFS code.  Get rid of pbreassignbuf().

Adjust the code in several places where it was assumed that calling
BUF_LOCK() with LK_SLEEPFAIL after previously failing with LK_NOWAIT
would always fail.  This code was used to sleep before a retry.  Instead,
if the second lock unexpectedly succeeds, simply issue an unlock and retry
anyway.

Testing-by: Stefan Krueger <skrueger@meinberlikomm.de>
18 years agoUnlock vnodes prior to issuing VOP_NREMOVE to accomodate filesystem
Matthew Dillon [Sat, 4 Mar 2006 17:39:08 +0000 (17:39 +0000)]
Unlock vnodes prior to issuing VOP_NREMOVE to accomodate filesystem
drivers which do not allow recursive exclusive locks (msdos).

Reported-by: Sascha Wildner <saw@online.de>
18 years agoAdd additional red-black tree functions for fast numeric field lookups.
Matthew Dillon [Fri, 3 Mar 2006 20:25:46 +0000 (20:25 +0000)]
Add additional red-black tree functions for fast numeric field lookups.
Unlike RB_FIND, these functions simply take the appropriate numeric data
type as the search argument rather then an entire dummy structure, and
directly test the numeric data type rather then make a callback.

18 years agovfs_bio_awrite() was unconditionally locking a buffer without checking
Matthew Dillon [Thu, 2 Mar 2006 20:28:49 +0000 (20:28 +0000)]
vfs_bio_awrite() was unconditionally locking a buffer without checking
for races, potentially resulting in the wrong buffer, an invalid buffer,
or a recently replaced buffer being written out.  Change the call semantics
to require a locked buffer to be passed into the function rather then
locking the buffer in the function.

18 years ago.Pq and friends add some unwanted extra whitespace. Use normal
Sascha Wildner [Thu, 2 Mar 2006 19:27:35 +0000 (19:27 +0000)]
.Pq and friends add some unwanted extra whitespace. Use normal
parentheses.

18 years agobuftimespinlock is utterly useless since the spinlock is released
Matthew Dillon [Thu, 2 Mar 2006 19:26:19 +0000 (19:26 +0000)]
buftimespinlock is utterly useless since the spinlock is released
within lockmgr().  The only real problem was with lk_prio, which no longer
exists, so get rid of the spin lock and document the remaining passive
races.

18 years agoPass LK_PCATCH instead of trying to store tsleep flags in the lock
Matthew Dillon [Thu, 2 Mar 2006 19:08:00 +0000 (19:08 +0000)]
Pass LK_PCATCH instead of trying to store tsleep flags in the lock
structure, so multiple entities competing for the same lock do not
use unexpected flags when sleeping.

Only NFS really uses PCATCH with lockmgr locks.

18 years agoFix initialisation of wide char support in FILE. Problem reported
Joerg Sonnenberger [Thu, 2 Mar 2006 18:05:30 +0000 (18:05 +0000)]
Fix initialisation of wide char support in FILE. Problem reported
on #dragonflybsd.

18 years agoMerge in security fix from FreeBSD.
David Rhodus [Wed, 1 Mar 2006 15:09:35 +0000 (15:09 +0000)]
Merge in security fix from FreeBSD.

simon       2006-03-01 14:21:56 UTC

 FreeBSD src repository (doc,ports committer)

 Modified files:        (Branch: RELENG_4)
   sys/nfs              nfs_socket.c
 Log:
 Correct a remote kernel panic when processing zero-length RPC records
 via TCP.

 Security:       FreeBSD-SA-06:10.nfs
 Approved by:    cperciva

 Revision  Changes    Path
 1.60.2.7  +1 -1      src/sys/nfs/nfs_socket.c

18 years agoRemove extra .Cm
Sascha Wildner [Wed, 1 Mar 2006 14:00:10 +0000 (14:00 +0000)]
Remove extra .Cm

18 years agoPull in a number of fixes from FreeBSD to fix at least the worst
Sascha Wildner [Wed, 1 Mar 2006 13:50:09 +0000 (13:50 +0000)]
Pull in a number of fixes from FreeBSD to fix at least the worst
issues:

rev. 1.43:
Kludge around troff bugs to get a reasonable print format despite the
necessity to shrink quoted text to fit on the page.

rev. 1.44:
A gross patch to tidy up the formatting.

rev. 1.47:
mdoc(7) police: Scheduled sweep.

rev. 1.49:
Insert device foo for a few drivers that don't have it.  Replace the
NetBSD config syntax with the FreeBSD syntax.

rev. 1.50:
Use a real (and compact) list for a filename list; this helps groff
split the lines in more reasonable places too, both in tty/ps output.

18 years agoRETURN VALUES is for function return values only. FreeBSD has an own
Sascha Wildner [Wed, 1 Mar 2006 08:08:45 +0000 (08:08 +0000)]
RETURN VALUES is for function return values only. FreeBSD has an own
EXIT STATUS section for exit codes returned to the shell. Until we do
as well, stuff it into DIAGNOSTICS as mdoc(7) advises.

18 years agoERRORS is errno related only. Move documentation to DIAGNOSTICS.
Sascha Wildner [Wed, 1 Mar 2006 08:01:09 +0000 (08:01 +0000)]
ERRORS is errno related only. Move documentation to DIAGNOSTICS.

18 years agodvp must be unlocked prior to issuing a VOP operation to avoid obtaining
Matthew Dillon [Wed, 1 Mar 2006 00:21:58 +0000 (00:21 +0000)]
dvp must be unlocked prior to issuing a VOP operation to avoid obtaining
a recursive exclusive lock.  Some filesystem drivers (e.g. msdos) do not
allow recursive locks.

Reported-by: Sascha Wildner <swildner@crater.dragonflybsd.org>
18 years agoA thread may be freed from a different cpu then it was assigned to,
Matthew Dillon [Wed, 1 Mar 2006 00:17:55 +0000 (00:17 +0000)]
A thread may be freed from a different cpu then it was assigned to,
remove the thread from the correct cpu's gd_tdallq.  This fixes an issue
with corruption of the gd_tdallq.

18 years agoFix section order (missed in my last commit).
Sascha Wildner [Wed, 1 Mar 2006 00:00:46 +0000 (00:00 +0000)]
Fix section order (missed in my last commit).

18 years agoAdd documentation for CAPS system calls.
Sascha Wildner [Tue, 28 Feb 2006 22:40:49 +0000 (22:40 +0000)]
Add documentation for CAPS system calls.

18 years agoProperly check for buffered data in ukbd_check_char(). This fixes issues
Matthew Dillon [Tue, 28 Feb 2006 18:48:01 +0000 (18:48 +0000)]
Properly check for buffered data in ukbd_check_char().  This fixes issues
with key codes getting mixed up between muxed keyboards.

Taken-from: FreeBSD / ukbd.c 1.53
Reported-by: "Norbert Koch" <NKoch@demig.de>
18 years agoDo not set the pcb_ext field until the private TSS has been completely
Matthew Dillon [Tue, 28 Feb 2006 18:30:22 +0000 (18:30 +0000)]
Do not set the pcb_ext field until the private TSS has been completely
initialized, otherwise an interrupt can come along and preempt, then
attempt to restore using the incompletely initialized TSS.

Do not free the pcb_ext data until after we have switched back to
the common TSS, otherwise a blockage in kmem_free() may cause a
premature thread switch with the now invalid private TSS.

Do not depend on need_user_resched() to set a private TSS prior to returning
from a system call, it may optimize itself into a NOP and not actually set
the private TSS prior to our return to userland.  Instead, active the
new private TSS manually by doing a forced thread switch to ourselves.

Reported-by: Sascha Wildner <saw@online.de>
18 years agoUse \(xx style escape sequences for some special characters so that
Sascha Wildner [Tue, 28 Feb 2006 02:25:11 +0000 (02:25 +0000)]
Use \(xx style escape sequences for some special characters so that
the correct glyphs are used for output devices like ps or utf8.

18 years agoFix file sizes > 2GB on isofs. This has already been fixed in the other BSDs.
Simon Schubert [Mon, 27 Feb 2006 02:50:48 +0000 (02:50 +0000)]
Fix file sizes > 2GB on isofs.  This has already been fixed in the other BSDs.

Submitted-by: Csaba Henk
18 years agoUpdate the DEBUG KERNELS section to reflect reality.
Sascha Wildner [Sun, 26 Feb 2006 23:27:08 +0000 (23:27 +0000)]
Update the DEBUG KERNELS section to reflect reality.

Submitted-by: Francis Gudin <fgudin@nerim.net>
18 years agonvi's "memory use after free" bug exists in following call path:
Matthew Dillon [Sun, 26 Feb 2006 17:18:06 +0000 (17:18 +0000)]
nvi's "memory use after free" bug exists in following call path:
v_switch()->ex_edit()->set_alt_name().  Patch the bug.

Obtained-from: OpenBSD
Submitted-by: "Sepherosa Ziehau" <sepherosa@gmail.com>
18 years agoWe don't support BUS_DMASYNC_PREREAD|BUS_DMASYNC_PREWRITE and
Sascha Wildner [Sun, 26 Feb 2006 09:07:35 +0000 (09:07 +0000)]
We don't support BUS_DMASYNC_PREREAD|BUS_DMASYNC_PREWRITE and
BUS_DMASYNC_POSTREAD|BUS_DMASYNC_POSTWRITE.

Requested-by: sephe
18 years agoOops, overlooked some spl*() references in my last commit.
Sascha Wildner [Sat, 25 Feb 2006 19:35:46 +0000 (19:35 +0000)]
Oops, overlooked some spl*() references in my last commit.

18 years agoRemove SPLASSERT(9) and spl(9) man pages and fix a few references.
Sascha Wildner [Sat, 25 Feb 2006 19:14:53 +0000 (19:14 +0000)]
Remove SPLASSERT(9) and spl(9) man pages and fix a few references.

18 years agoReplace .Fx with .Dx where necessary.
Sascha Wildner [Sat, 25 Feb 2006 11:38:57 +0000 (11:38 +0000)]
Replace .Fx with .Dx where necessary.

18 years agoRemove empty line to silence troff warning.
Sascha Wildner [Sat, 25 Feb 2006 11:26:13 +0000 (11:26 +0000)]
Remove empty line to silence troff warning.

18 years agoBring in the ndis(4) man page from FreeBSD (with minor modifications).
Sascha Wildner [Sat, 25 Feb 2006 10:20:10 +0000 (10:20 +0000)]
Bring in the ndis(4) man page from FreeBSD (with minor modifications).

18 years agoSync pciconf(8)'s database with FreeBSD-CURRENT's rev. 1.34.
Sascha Wildner [Thu, 23 Feb 2006 10:19:04 +0000 (10:19 +0000)]
Sync pciconf(8)'s database with FreeBSD-CURRENT's rev. 1.34.

18 years agoChange the server side NFS write gather delay from 10ms to 20ms. This
Matthew Dillon [Tue, 21 Feb 2006 19:00:19 +0000 (19:00 +0000)]
Change the server side NFS write gather delay from 10ms to 20ms.  This
avoids a boundary condition with the 100hz system clock and should slightly
improve write gather performance.

Use getmicrouptime() instead of getmicrotime() to record access cache
timestamps.  This prevents the client-side NFS attribute cache from
getting confused if the system time steps backwards.

18 years agobioops.io_start() was being called in a situation where the buffer could
Matthew Dillon [Tue, 21 Feb 2006 18:46:56 +0000 (18:46 +0000)]
bioops.io_start() was being called in a situation where the buffer could
be brelse()'d afterwords instead of I/O being initiated.  When this occurs,
the buffer may contain softupdates-modified data which is never reverted,
resulting in serious filesystem corruption.  When io_start is called on a
buffer, I/O MUST be initiated and terminated with a biodone() or the buffer's
data may not be properly reverted.

Solve the problem by moving the io_start() call a little further on in the
code, after the potential brelse().

There is a possibility that this bug is responsible for the 'dirbad' panics
often reported in DragonFly and FreeBSD circles.

18 years agoReduce the default NFSv3 access cache timeout from 60 seconds to 10 seconds.
Matthew Dillon [Tue, 21 Feb 2006 17:52:52 +0000 (17:52 +0000)]
Reduce the default NFSv3 access cache timeout from 60 seconds to 10 seconds.
The user can still adjust the timeout via vfs.nfs.access_cache_timeout.

Change the dynamic attribute cache timeout heuristic to be the approximate
number of seconds since the file was last modified divided by 60.  It used
to be divided by 10.

18 years agoReformulate some code which was #if 0'd out in the last patch. When
Matthew Dillon [Tue, 21 Feb 2006 17:36:38 +0000 (17:36 +0000)]
Reformulate some code which was #if 0'd out in the last patch.  When
reporting the 'busy buffer' problem, ignore dirty buffers for vnodes
which do not have any I/O in progress.

18 years agoFix a bunch of race cases in the NFS callout timer code, in the handling
Matthew Dillon [Tue, 21 Feb 2006 04:47:56 +0000 (04:47 +0000)]
Fix a bunch of race cases in the NFS callout timer code, in the handling
of the NFS request queue and, in the handling of R_SENT.

The NFS stack can block in the callout timer code's request queue loop,
possibly resulting in another process ripping the current request in the
TAILQ_FOREACH scan out from under the loop.

R_MASKTIMER was being cleared too early, potentially allowing the callout
timer code to modify a request at the same time mainline code was working
on the same request synchronously.

The R_SENT bit would sometimes get set after the request had completed, or
get set twice, causing nmp->nm_sent to 'stick' and never return to 0.  This
in turn would stop the NFS retry code dead in its tracks and cause the NFS
mount to hang.

Reported-by: Stefan Krueger <skrueger@meinberlikomm.de>
Testing-by: Stefan Krueger <skrueger@meinberlikomm.de>
Also-thanks-to: Peter Holms filesystem and load testing suite (stress2).

18 years ago* Remove unused SC_RENDER_DEBUG option.
Sascha Wildner [Sun, 19 Feb 2006 09:16:26 +0000 (09:16 +0000)]
* Remove unused SC_RENDER_DEBUG option.

* While I'm in LINT, add VGA_DEBUG and VESA_DEBUG.
  Also, set SC_DEBUG_LEVEL to 5 (the maximum value used).

18 years agopam_unix.so needs -lutil. Fixes qpopper issues as seen by Adrian Nida.
Joerg Sonnenberger [Sat, 18 Feb 2006 19:40:10 +0000 (19:40 +0000)]
pam_unix.so needs -lutil. Fixes qpopper issues as seen by Adrian Nida.

18 years agoSync vfscanf with FreeBSD, which makes it almost symmetrical to
Joerg Sonnenberger [Sat, 18 Feb 2006 17:55:52 +0000 (17:55 +0000)]
Sync vfscanf with FreeBSD, which makes it almost symmetrical to
printf. Most importantly "%lld", "%zd" and friends now work.

18 years agoRetire lib/msun. It was replaced by NetBSD's libm.
Sascha Wildner [Fri, 17 Feb 2006 22:11:31 +0000 (22:11 +0000)]
Retire lib/msun. It was replaced by NetBSD's libm.

18 years agoSweep-fix man page section order to match mdoc(7), part 5/5.
Sascha Wildner [Fri, 17 Feb 2006 19:40:31 +0000 (19:40 +0000)]
Sweep-fix man page section order to match mdoc(7), part 5/5.

Note: I haven't touched the few man pages that are still using
      the old man(7) macros. They will be converted to mdoc later.

18 years agoSweep-fix man page section order to match mdoc(7), part 4/5.
Sascha Wildner [Fri, 17 Feb 2006 19:39:18 +0000 (19:39 +0000)]
Sweep-fix man page section order to match mdoc(7), part 4/5.

Note: I haven't touched the few man pages that are still using
      the old man(7) macros. They will be converted to mdoc later.

18 years agoSweep-fix man page section order to match mdoc(7), part 3/5.
Sascha Wildner [Fri, 17 Feb 2006 19:37:10 +0000 (19:37 +0000)]
Sweep-fix man page section order to match mdoc(7), part 3/5.

Note: I haven't touched the few man pages that are still using
      the old man(7) macros. They will be converted to mdoc later.

18 years agoSweep-fix man page section order to match mdoc(7), part 2/5.
Sascha Wildner [Fri, 17 Feb 2006 19:35:07 +0000 (19:35 +0000)]
Sweep-fix man page section order to match mdoc(7), part 2/5.

Note: I haven't touched the few man pages that are still using
      the old man(7) macros. They will be converted to mdoc later.

18 years agoSweep-fix man page section order to match mdoc(7), part 1/5.
Sascha Wildner [Fri, 17 Feb 2006 19:33:33 +0000 (19:33 +0000)]
Sweep-fix man page section order to match mdoc(7), part 1/5.

Note: I haven't touched the few man pages that are still using
      the old man(7) macros. They will be converted to mdoc later.

18 years agoMake the entire BUF/BIO system BIO-centric instead of BUF-centric. Vnode
Matthew Dillon [Fri, 17 Feb 2006 19:18:08 +0000 (19:18 +0000)]
Make the entire BUF/BIO system BIO-centric instead of BUF-centric.  Vnode
and device strategy routines now take a BIO and must pass that BIO to
biodone().  All code which previously managed a BUF undergoing I/O now
manages a BIO.

The new BIO-centric algorithms allow BIOs to be stacked, where each layer
represents a block translation, completion callback, or caller or device
private data.  This information is no longer overloaded within the BUF.
Translation layer linkages remain intact as a 'cache' after I/O has completed.

The VOP and DEV strategy routines no longer make assumptions as to which
translated block number applies to them.  The use the block number in the
BIO specifically passed to them.

Change the 'untranslated' constant to NOOFFSET (for bio_offset), and
(daddr_t)-1 (for bio_blkno).  Rip out all code that previously set the
translated block number to the untranslated block number to indicate
that the translation had not been made.

Rip out all the cluster linkage fields for clustered VFS and clustered
paging operations.  Clustering now occurs in a private BIO layer using
private fields within the BIO.

Reformulate the vn_strategy() and dev_dstrategy() abstraction(s).  These
routines no longer assume that bp->b_vp == the vp of the VOP operation, and
the dev_t is no longer stored in the struct buf.  Instead, only the vp passed
to vn_strategy() (and related *_strategy() routines for VFS ops), and
the dev_t passed to dev_dstrateg() (and related *_strategy() routines for
device ops) is used by the VFS or DEV code.  This will allow an arbitrary
number of translation layers in the future.

Create an independant per-BIO tracking entity, struct bio_track, which
is used to determine when I/O is in-progress on the associated device
or vnode.

NOTE: Unlike FreeBSD's BIO work, our struct BUF is still used to hold
the fields describing the data buffer, resid, and error state.

Major-testing-by: Stefan Krueger
18 years agoProperly assert the state of the MP lock in the async syscall message
Matthew Dillon [Fri, 17 Feb 2006 06:01:24 +0000 (06:01 +0000)]
Properly assert the state of the MP lock in the async syscall message
waiting code.

Reported-by: Stefan Krueger <skrueger@meinberlikomm.de>
18 years agoFix patch handling in kernel sources.
Simon Schubert [Wed, 15 Feb 2006 17:13:33 +0000 (17:13 +0000)]
Fix patch handling in kernel sources.

Noticed-by: YONETANI Tomokazu <qhwt+dfly@les.ath.cx>
18 years agoConsolidate patches into the sources of top, which were imported from
Simon Schubert [Wed, 15 Feb 2006 12:54:36 +0000 (12:54 +0000)]
Consolidate patches into the sources of top, which were imported from
FreeBSD and are not pristine anyways.

18 years agoGet rid of seriously out of date example code.
Matthew Dillon [Mon, 13 Feb 2006 19:29:09 +0000 (19:29 +0000)]
Get rid of seriously out of date example code.

18 years agoAdjust build infrastructure for OpenSSH-4.3p2
Simon Schubert [Mon, 13 Feb 2006 14:47:58 +0000 (14:47 +0000)]
Adjust build infrastructure for OpenSSH-4.3p2

18 years agoUpdate our READMEs
Simon Schubert [Mon, 13 Feb 2006 14:47:04 +0000 (14:47 +0000)]
Update our READMEs

18 years agoMerge from vendor branch OPENSSH:
Simon Schubert [Mon, 13 Feb 2006 14:25:42 +0000 (14:25 +0000)]
Merge from vendor branch OPENSSH:
Import OpenSSH 4.3p2 modulo unneeded files

18 years agoImport OpenSSH 4.3p2 modulo unneeded files
Simon Schubert [Mon, 13 Feb 2006 14:25:42 +0000 (14:25 +0000)]
Import OpenSSH 4.3p2 modulo unneeded files

18 years agoRemove no_obj patches from SRCS
Simon Schubert [Mon, 13 Feb 2006 14:21:46 +0000 (14:21 +0000)]
Remove no_obj patches from SRCS

18 years agoMove patch handling out of .if defined(PROG)
Simon Schubert [Mon, 13 Feb 2006 14:21:25 +0000 (14:21 +0000)]
Move patch handling out of .if defined(PROG)

18 years agoPull patch handling into its own file so that patches with
Simon Schubert [Mon, 13 Feb 2006 13:27:20 +0000 (13:27 +0000)]
Pull patch handling into its own file so that patches with
subdir components work correctly.

Reviewed-by: guys from #dragonflybsd
18 years agoBring in a bunch of malloc features from OpenBSD and fundamentally change
Matthew Dillon [Sun, 12 Feb 2006 21:19:07 +0000 (21:19 +0000)]
Bring in a bunch of malloc features from OpenBSD and fundamentally change
the core allocation code to use mmap() instead of brk/sbrk().  Most of the
new options are off by default, see the new manual page for more information.

* guard pages and chunk randomization
* free page protection
* malloc stats(dump)
* pointer guard
* no longer uses brk/sbrk
* updated man page

Submitted-by: "Kevin L. Kane" <kevin.kane@gmail.com>
Porting-work-by: "Kevin L. Kane" <kevin.kane@gmail.com>
18 years agoMake warn() a weak reference.
Matthew Dillon [Sun, 12 Feb 2006 21:14:11 +0000 (21:14 +0000)]
Make warn() a weak reference.

Submitted-by: "Kevin L. Kane" <kevin.kane@gmail.com>
18 years agoRemove serialization calls that are no longer correct, fixing a panic
Matthew Dillon [Sun, 12 Feb 2006 19:53:56 +0000 (19:53 +0000)]
Remove serialization calls that are no longer correct, fixing a panic
with SLIP connections.

18 years agoRemove unnecessary .Pp following .Sh (forgotten in my last commit).
Sascha Wildner [Sat, 11 Feb 2006 21:32:41 +0000 (21:32 +0000)]
Remove unnecessary .Pp following .Sh (forgotten in my last commit).

18 years agoAllways pass -n to echo so that wmake -n will do the right thing.
Simon Schubert [Sat, 11 Feb 2006 10:42:12 +0000 (10:42 +0000)]
Allways pass -n to echo so that wmake -n will do the right thing.
Note that this only works because of the special behaviour of sh's
echo builtin.

18 years agoAdd a fix for CAN-2005-3001, via pkgsrc from Ubunto.
Joerg Sonnenberger [Sat, 11 Feb 2006 01:21:27 +0000 (01:21 +0000)]
Add a fix for CAN-2005-3001, via pkgsrc from Ubunto.

This is a very low impact problem, since the change of an index being
larger than 500 KB is almost zero and the code has problems either way.

18 years agoRemove .Pp directly following .Sh or .Ss (not necessary, see mdoc(7)).
Sascha Wildner [Fri, 10 Feb 2006 19:01:10 +0000 (19:01 +0000)]
Remove .Pp directly following .Sh or .Ss (not necessary, see mdoc(7)).

18 years agoFix comments.
Sascha Wildner [Fri, 10 Feb 2006 18:53:18 +0000 (18:53 +0000)]
Fix comments.

18 years agoRemove the VBWAIT flag test, it will soon go away.
Matthew Dillon [Wed, 8 Feb 2006 08:34:13 +0000 (08:34 +0000)]
Remove the VBWAIT flag test, it will soon go away.

18 years agoMove serializer locking from pppoutput() to pppwrite(), which was
YONETANI Tomokazu [Mon, 6 Feb 2006 01:49:37 +0000 (01:49 +0000)]
Move serializer locking from pppoutput() to pppwrite(), which was
the only caller without serializer locked.

Problem-Reported-by: Eric J. Christeson <eric.j.christeson at gmail.com>
18 years agoSUSv3 states that the type builtin should return a value > 0 if the completion
Eirik Nygaard [Sat, 4 Feb 2006 14:12:20 +0000 (14:12 +0000)]
SUSv3 states that the type builtin should return a value > 0 if the completion
was not successful.

18 years agoMake patch break hardlinks even if not making backups.
Simon Schubert [Fri, 3 Feb 2006 21:20:29 +0000 (21:20 +0000)]
Make patch break hardlinks even if not making backups.

18 years agoUse errx(), no errno is set in this case.
Eirik Nygaard [Thu, 2 Feb 2006 17:00:29 +0000 (17:00 +0000)]
Use errx(), no errno is set in this case.

18 years agoSet proper termio flags for the sysmouse tty
Simon Schubert [Wed, 1 Feb 2006 20:43:42 +0000 (20:43 +0000)]
Set proper termio flags for the sysmouse tty

18 years agoBring in the parallel route table code and clean up ARP. The
Matthew Dillon [Tue, 31 Jan 2006 19:05:45 +0000 (19:05 +0000)]
Bring in the parallel route table code and clean up ARP.  The
route table is now replicated across all cpus (ncpus, not ncpus2).
Note that cloned routes are not replicated.

This removes one of the few remaining obstacles to being able
to run the network protocol stacks without the BGL.

Primary-Design-by: Jeffrey Hsu
Work-by: Jeffrey Hsu and Matthew Dillon
18 years agoRemove extra 'the'.
Sascha Wildner [Tue, 31 Jan 2006 10:30:45 +0000 (10:30 +0000)]
Remove extra 'the'.

Noticed-by: Trevor Kendall <trevorjk@gmail.com>
18 years agoFix spelling mistake.
Sascha Wildner [Tue, 31 Jan 2006 09:45:30 +0000 (09:45 +0000)]
Fix spelling mistake.

Noticed-by: Trevor Kendall <trevorjk@gmail.com>
18 years agoPull the fix from procfs_vnops.c:1.27 also to linprocfs
Simon Schubert [Tue, 31 Jan 2006 02:15:10 +0000 (02:15 +0000)]
Pull the fix from procfs_vnops.c:1.27 also to linprocfs

18 years agocrit_exit() is called where crit_enter() is supposed to be.
YONETANI Tomokazu [Mon, 30 Jan 2006 14:16:16 +0000 (14:16 +0000)]
crit_exit() is called where crit_enter() is supposed to be.

18 years agoSync nv with FreeBSD and update the binary driver to 1.0-0310.
Simon Schubert [Sun, 29 Jan 2006 22:10:11 +0000 (22:10 +0000)]
Sync nv with FreeBSD and update the binary driver to 1.0-0310.
This fixes device timeout issues with my NForce4 chipset.

Obtained-from: FreeBSD

18 years ago- Add NVIDIA nForce MCP12 support
Sepherosa Ziehau [Sun, 29 Jan 2006 08:25:33 +0000 (08:25 +0000)]
- Add NVIDIA nForce MCP12 support
- Add NVIDIA nForce MCP13 support

Reported-and-Tested-by: corecode
18 years agoLobotomize libcaps so it compiles again and can be used by the code
Matthew Dillon [Sat, 28 Jan 2006 18:07:45 +0000 (18:07 +0000)]
Lobotomize libcaps so it compiles again and can be used by the code
in src/test.

18 years agoInitialize intrcnt[] with 0 before using it, because hw.intrcnt
YONETANI Tomokazu [Sat, 28 Jan 2006 17:18:48 +0000 (17:18 +0000)]
Initialize intrcnt[] with 0 before using it, because hw.intrcnt
may return fewer elements than hw.intrnames.

18 years agoPass serializer to bus_setup_intr()
Sepherosa Ziehau [Sat, 28 Jan 2006 15:07:52 +0000 (15:07 +0000)]
Pass serializer to bus_setup_intr()

Reported-and-Tested-by: swildner
18 years agoIn ep_if_start(), restore 'm' after it is used to traverse mbufs, or following
Sepherosa Ziehau [Sat, 28 Jan 2006 14:05:57 +0000 (14:05 +0000)]
In ep_if_start(), restore 'm' after it is used to traverse mbufs, or following
code's assumption is broken.

Reported-and-Tested-by: swildner
18 years agoAdjust X11BASE so that ssh/sshd find xauth with pkgsrc.
Simon Schubert [Thu, 26 Jan 2006 17:48:35 +0000 (17:48 +0000)]
Adjust X11BASE so that ssh/sshd find xauth with pkgsrc.

18 years agoAdd a missing #include <sys/lock.h> to fix a UP kernel build problem.
Matthew Dillon [Thu, 26 Jan 2006 08:19:48 +0000 (08:19 +0000)]
Add a missing #include <sys/lock.h> to fix a UP kernel build problem.

Reported-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
18 years agoTest commit of new file.
Justin C. Sherrill [Thu, 26 Jan 2006 04:42:12 +0000 (04:42 +0000)]
Test commit of new file.

18 years agoThe random number generator was not generating sufficient entropy by
Matthew Dillon [Wed, 25 Jan 2006 19:56:31 +0000 (19:56 +0000)]
The random number generator was not generating sufficient entropy by
default, resulting in weak random numbers for a short period of time after
a machine is first booted.

* Change the entropy default for all interrupts except the clock interrupt
  from off to on.

* Greatly reduce the overhead of the interrupt entropy code so even high
  performance interrupts can call it.

* Instead of calculating the entropy at the time of the interrupt,
  introduce a new rate-limited kernel thread which the interrupt code can
  simply schedule.  The new thread will be responsible for adding the
  entropy.

  This thread will rate-limit based on the amount of entropy that has been
  built up.  The more entropy we have, the lower the thread's frequency of
  operation.  Currently the limit is set to 25 hz.

* Use the TSC in addition to the normal time calculation when introducing
  entropy.

Note that during tests it was found that a new ssh connection tends to
'eat' all available entropy.  This isn't actually true, it's really the
entropy calculation itself which is not quite correct, but I am duely noting
the issue here.

Reported-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
18 years agoMerge OpenBSD r1.104:
Joerg Sonnenberger [Wed, 25 Jan 2006 02:47:09 +0000 (02:47 +0000)]
Merge OpenBSD r1.104:
  fix a bug in the fragment cache (used for 'scrub fragment crop/drop-ovl',
  but not 'fragment reassemble'), which can cause some fragments to get
  inserted into the cache twice, thereby violating an invariant, and panic-
  ing the system subsequently. ok deraadt@

Reminded-by: Daniel Hartmeier
18 years agoWhen using visibility macros, sys/cdefs.h must be included first.
Joerg Sonnenberger [Tue, 24 Jan 2006 21:43:33 +0000 (21:43 +0000)]
When using visibility macros, sys/cdefs.h must be included first.

18 years agoSync BSD family tree with FreeBSD.
Sascha Wildner [Mon, 23 Jan 2006 02:56:43 +0000 (02:56 +0000)]
Sync BSD family tree with FreeBSD.

18 years agoRemove ports(7) man page since we're using pkgsrc now.
Sascha Wildner [Sun, 22 Jan 2006 14:50:26 +0000 (14:50 +0000)]
Remove ports(7) man page since we're using pkgsrc now.

18 years ago* Move function types to a separate line.
Sascha Wildner [Sun, 22 Jan 2006 14:03:51 +0000 (14:03 +0000)]
* Move function types to a separate line.

* Ansify function definitions.

* Remove (void) casts for discarded return values.

In collaboration with: Alexey Slynko <slynko@tronet.ru>

18 years agoAdd ansification to silence -Wold-style-definition warnings.
Sascha Wildner [Sun, 22 Jan 2006 13:38:50 +0000 (13:38 +0000)]
Add ansification to silence -Wold-style-definition warnings.

Submitted-by: Alexey Slynko <slynko@tronet.ru>
18 years agoAdd some casts to silence warnings.
Sascha Wildner [Sun, 22 Jan 2006 04:44:18 +0000 (04:44 +0000)]
Add some casts to silence warnings.

Submitted-by: Alexey Slynko <slynko@tronet.ru>
18 years agoRemove unused variables.
Sascha Wildner [Sun, 22 Jan 2006 04:31:22 +0000 (04:31 +0000)]
Remove unused variables.

Submitted-by: Alexey Slynko <slynko@tronet.ru>
18 years agoInitialize variable.
Sascha Wildner [Sun, 22 Jan 2006 04:30:27 +0000 (04:30 +0000)]
Initialize variable.

Submitted-by: Alexey Slynko <slynko@tronet.ru>
18 years agoAdd missing header for isab_attach prototype.
Sascha Wildner [Sun, 22 Jan 2006 04:10:32 +0000 (04:10 +0000)]
Add missing header for isab_attach prototype.

Submitted-by: Alexey Slynko <slynko@tronet.ru>