Commit Graph

8702 Commits

Author SHA1 Message Date
David Greenman 523a02aa7a Don't skip point-to-point interfaces if the netmask==0 (the netmask
should be completely ignored for point-to-point interfaces).
For point-to-point interfaces, route based on the destination address,
not the local address.

Submitted by:	Peter Wemm
1995-06-28 05:31:03 +00:00
David Greenman e9ce2e7d20 Added function prototypes for ip_rsvp_vif_init, ip_rsvp_vif_done, and
ip_rsvp_force_done.
1995-06-28 05:13:02 +00:00
David Greenman 28a3c3c9a6 Killed the "probably_never" ifdef'd code. 1995-06-28 04:51:06 +00:00
David Greenman 338cd8f6be Killed redundant vnode_pager_umount() call. This is already done at
FS unmount time.
1995-06-28 04:46:11 +00:00
David Greenman 53b5ed936e Make path to kernel absolute if it is passed in relative. This fixes
a related bug in some of the new 'foo'boot bootstrap code that has been
added over the past months. This change makes it no longer necessary
for the bootstrap to fix up the path (i.e. it can be removed).
1995-06-28 04:42:25 +00:00
Bruce Evans 943c18018b Fix standards conformance bugs in <signal.h>:
include/signal.h:
There was massive namespace pollution from including <sys/types.h>.
POSIX functions were declared even when _ANSI_SOURCE is defined.

sys.sys/signal.h:
NSIG was declared even if _ANSI_SOURCE or _POSIX_SOURCE is defined.
sig_atomic_t wasn't declared if _POSIX_SOURCE is defined.
Declare a typedef for signal handling functions and use it to
unobfuscate declarations and to avoid half-baked function types
that cause unwanted compiler warnings at certain warning levels.
Fix confusing comment about SA_RESTART.

sys/i386/include/signal.h:
This has to be included to get the declaration of sig_atomic_t even
when _ANSI_SOURCE is defined, so be more careful about polluting
the ANSI namespace.

Uniformize idempotency ifdefs.
1995-06-28 02:14:13 +00:00
Bruce Evans 200db83402 Use the new machine-dependent definitions of _BSD_OFF_T_ and
_BSD_PID_T_ to declare off_t and pid_t.
1995-06-28 01:39:50 +00:00
Bruce Evans e9c2b07f51 Define macros _BSD_OFF_T_ and _BSD_PID_T_ suitable for use instead
of the typedefs off_t and pid_t when use of the latter would cause
namespace pollution.  These macros are used like _BSD_VA_LIST_ and
aren't #undef'ed when the corresponding typedef is declared.
off_t is very machine-dependent and should never have been decided
in <sys/types.h> (its declaration is compiler-dependent).  pid_t
isn't very machine-dependent, but this might change.  `long' is
a wasteful type for it if longs are longer than ints.

Move the definition of _BSD_VA_LIST_ away from the comment that
suggests that it is #undefed when va_list is declared.
1995-06-28 01:39:26 +00:00
Bruce Evans 6acceb40dc Pass the correct nonblocking flag to VOP_CLOSE() in vclean().
VOP_CLOSE() takes `F' (file) flags, not `IO' flags.  At least that's
what close() passes.  I previously fixed ttylclose() to check
FNONBLOCK instead of IO_NDELAY.  This broke the call from vclean()
and cleaning of ptys sometimes deadlocked.
1995-06-27 21:29:08 +00:00
Garrett Wollman 20dc68b204 Delete obsolete #if 0 block. 1995-06-27 20:36:34 +00:00
Guido van Rooij a0aa52a646 reject option in ip_fw used to panic the system. This fixes it.
-Guido
Reviewed by:
Submitted by:
Obtained from:
1995-06-27 17:26:27 +00:00
Doug Rabson a62dc40654 Changes to support version 3 of the NFS protocol.
The version 2 support has been tested (client+server) against FreeBSD-2.0,
IRIX 5.3 and FreeBSD-current (using a loopback mount).  The version 2 support
is stable AFAIK.
The version 3 support has been tested with a loopback mount and minimally
against an IRIX 5.3 server.  It needs more testing and may have problems.
I have patched amd to support the new variable length filehandles although
it will still only use version 2 of the protocol.

Before booting a kernel with these changes, nfs clients will need to at least
build and install /usr/sbin/mount_nfs.  Servers will need to build and
install /usr/sbin/mountd.

NFS diskless support is untested.

Obtained from: Rick Macklem <rick@snowhite.cis.uoguelph.ca>
1995-06-27 11:07:30 +00:00
Doug Rabson 82aaeb09ad Change ld.so to correctly load dependant libraries for dlopen and unload them
on dlclose.  Also correctly call constructors and destructors for libraries
linked with /usr/lib/c++rt0.o.
Change interpretation of dlopen manpage to call _init() rather than init()
for dlopened objects.
Change c++rt0.o to avoid using atexit to call destructors, allowing dlclose to
call destructors when an object is unloaded.
Change interface between crt0 and ld.so to allow crt0 to call a function on
exit to call destructors for shared libraries explicitly.

These changes are backwards compatible.  Old binaries will work with the new
ld.so and new binaries will work with the old ld.so.  A version number has
been introduced in the crt0-ld.so interface to allow for future changes.

Reviewed by:	GAWollman, Craig Struble <cstruble@singularity.bevc.blacksburg.va.us>
1995-06-27 09:53:27 +00:00
Garrett Wollman 524743b0fe From Bill Fenner:
> Also, I don't remember if I sent you this; it affects PIM assert processing.

Submitted by:	Bill Fenner <fenner@parc.xerox.com>
1995-06-26 16:15:49 +00:00
Garrett Wollman fba14c2e49 Corrected a bug that caused protocol-4 tunnels (used for multicast
forwarding between networks that aren't directly connected) not to work
by intercepting the wrong protocol number.  This should fix a bug reported
previously by someone I don't remember.
1995-06-26 16:11:51 +00:00
Bill Paul 6c0828a6c6 Do the same sanity checking in _pw_breakout_yp() that we do in
_gr_breakout_yp(): if we encounter a NULL pointer generated as the
result of a badly formatted NIS passwd entry (e.g. missing fields),
we punt and return an error code, thereby silently skipping the
bad entry.
1995-06-26 16:04:57 +00:00
Bill Paul e0ee807b3d Fix for a potential problem reported by a user I bumped into on IRC
last night:

_gr_breakout_yp() doesn't check for badly formatted NIS group entries.
For example, a bogus entry like this:

bootp::user1,user2,user3

will lead to a null pointer dereference and a SEGV (note that the GID
field is missing -- this results in one of the strsep(&result, ":")
returning NULL). The symtpom of this problem is programs dumping
core left and right the moment you add a + entry to /etc/group.
Note that while this is similar to an earlier bug, it's caused by a
different set of circumstances.

The fix is to check for the NULL pointers and have _gr_breakout_yp()
punt and return a failure code if it catches one. This is more or
less the behavior of SunOS: if a bad NIS group entry is encountered,
it's silently ignored. I don't think our standard (non-NIS) group
parsing code behaves the same way. It doesn't crash though, so I'm
citing the 'it ain't broken, don't fix it' rule and leaving it alone.

I'll probably have to add similar checks to _pw_breakout_yp() in
getpwent.c to ward off the same problems. It's rare that bad NIS
map entries like this occur, but we should handle them gracefully
when they do.
1995-06-26 14:59:46 +00:00
Rodney W. Grimes 168b2626e6 Here is a supfile for getting the -stable bits from SUP.FreeBSD.ORG. 1995-06-26 11:41:25 +00:00
Bruce Evans 21bbf8081b `pred1' was documented as `pred'. The problem was not obvious because
`disable pred' is silently ignored.
1995-06-26 08:04:16 +00:00
Bruce Evans 9207f00ac0 The pessimistic rounding in hzto() was too pessimistic for realitimexpire(). 1995-06-26 07:48:50 +00:00
Bruce Evans 4ebf8117df Partially fix `sysctl machdep.console_device'. The fix will be complete
when syscons stops mapping the console to minor MAXCONS.  There is
usually no corresponding device in /dev, and the correct device has
minor 0.

cons.c:
Initialize cn_tty properly, so that CPU_CONSDEV can work.
Comment about too many variants of the console tty pointer.

machdep.c:
Return device NODEV and not error EFAULT when there is no console device.
1995-06-26 07:39:52 +00:00
Satoshi Asami 77370fd9ed Use
ftp://ftp.freebsd.org/pub/FreeBSD/distfiles/

as our distribution point for distfiles and patches.  Other than
cosmetic changes (freebsd.cdrom.com -> ftp.freebsd.org), the
omission of "ports" is important.  I would like to move this
directory completely out of the ports tree (on the ftp site),
so that people who do "get ports.tar.gz" won't get a bogus distfiles
-> ../distfiles symlink (which will make "make fetch" fail).

Sometime around the 2.1 release, the distfiles link will be deleted.
1995-06-26 07:06:59 +00:00
Satoshi Asami b9e48987a7 Use full pathnames for the commands. Everything except gmake and
xmkmf (i.e., everything in the base distribution) should be referred
to by full pathnames.

Suggested by:	rgrimes, originally from one of his customers
1995-06-26 07:01:20 +00:00
Bruce Evans 278e874772 Remove bogus references to /usr/ucb. 1995-06-26 06:40:23 +00:00
Bruce Evans d1e00e9390 Improve the handling of large minor numbers:
cpio/copyout.c:
Don't output a file if the major, minor or totality of its rdev would be
truncated.  Print a message about the skipped files to stderr but don't
report the error in the exit status.  cpio's abysmal error handling doesn't
allow continuing after an error, and the rdev checks had to be misplaced
to avoid the problem of returning an error code from routines that return
void.

pax/pax.h:
Use the system macros for major(), minor() and makedev().

pax already checks _all_ output conversions for overflow.  This has the
undesirable effect that failure to convert relatively useless fields
such as st_dev for regular files causes files not to be output.  pax
doesn't report exactly which fields couldn't be converted.

tar/create.c:
Don't output a file if the major or minor its rdev would be truncated.
Print a message about the skipped files to stderr and report the error
in the exit status.

tar/tar.c:
For not immediately fatal errors, exit with status 1, not the error count
(mod 256).

All:
Minor numbers are limited to 21 bits in pax's ustar format and to 18
bits in archives created by gnu tar (gnu tar wastes 3 bits for padding).
pax's and cpio's ustar format is incompatible with gnu tar's ustar
format for other reasons (see cpio/README).
1995-06-26 06:24:48 +00:00
Bruce Evans 5d2fb2731f Document new config flag for lost output interrupts.
Treat the intitial state device less negatively.  It is essential for
initializing nonstandard flags such as crtscts.

Delete anachronisms.
1995-06-26 06:05:30 +00:00
Torsten Blum 25f85f5172 - change contact address for nic.funet.fi to count@nic.funet.fi
- add nic.funet.fi to the eBones/secure mirror list

Submitted by:	Bror Heinola <count@nic.funet.fi>
1995-06-26 02:24:02 +00:00
Satoshi Asami e8d35b806f Check if uid is 0 before running mtree. If you aren't root, you just
get a message (instead of a bunch of crap from mtree).
1995-06-26 00:30:48 +00:00
Joerg Wunsch f9e1554f6f Include killall. 1995-06-25 18:11:06 +00:00
Joerg Wunsch 1fc7066757 Our Perl oracle hit again: Wolfram Schneider's killall utility.
Kills processes by name instead of by UID.

(Man page by me.)

Submitted by:	wosch@cs.tu-berlin.de (Wolfram Schneider)
1995-06-25 18:08:27 +00:00
Joerg Wunsch 16a7269ee5 When tuneing filesystems with tunefs, it is not obvious what the current
parameters are.  You can use dumpfs, but that's not obvious which settings
are tuneable, and is far from clear to the non-guru (it's like using a
hexdump of a tar archive to get a table-of-contents).

There is also an undocumented option in the man page that can be dangerous.
Suppose your disk driver decides to scramble all writes while you tell
tunefs to update all backup superblocks.

This suggested change adds a '-p' (print) switch to bring it in
line with some SVR4 systems.

(Slightly changed by me, mostly for optics. - joerg)

Submitted by:	peter@haywire.dialix.com
1995-06-25 17:46:13 +00:00
Joerg Wunsch 85cd1fc590 The BT scsi driver has recently had a message changed - it could be
clearer.  The "informational message" almost looks like an instruction to
the user to change settings on the card....

It's cosmetic, but...

Submitted by:	peter@haywire.dialix.com
1995-06-25 17:45:05 +00:00
Søren Schmidt c21dee177f First incarnation of our Linux emulator or rather compatibility code.
This first shot only incorporaties so much functionality that DOOM
can run (the X version), signal handling is VERY weak, so is many
other things. But it meets my milestone number one (you guessed it
- running DOOM).

Uses /compat/linux as prefix for loading shared libs, so it won't
conflict with our own libs.

Kernel must be compiled with "options COMPAT_LINUX" for this to work.
1995-06-25 17:32:43 +00:00
Joerg Wunsch 0f72d204e6 Reset defaults in case of boot() is looping several times (e.g. the
user has entered a bogus kernel name in the first place).

Also fix the broken #ifdef FORCE_COMCONSOLE, it has been disabled by
accident.  (NB: the keyboard probe remains disabled however.)

Few cosmetic fixes (declare functions to be void instead of int),
while i've been at this.

Pointed out by: wosch@cs.tu-berlin.de (Wolfram Schneider), for the init bug
1995-06-25 14:02:57 +00:00
Joerg Wunsch 749adad7a6 The joystick driver appeared in FreeBSD 2.0.5, not in 2.1.
Closes PR #docs/559

Submitted by:	jkh
1995-06-25 13:58:54 +00:00
Joerg Wunsch 973d025839 Add a `reset' command to UserConfig. Our documentation does
explicitly advise the users to reset the machine in case they have
done bogus things (to prevent `dset' from merging the changes into
/kernel), and it's also useful for machines with serial consoles that
are physically in another place.
1995-06-25 13:57:55 +00:00
Satoshi Asami 2e43046bb6 Change "sysctl -nw" to "sysctl -w" to make the output more informative.
Reviewed by:	rgrimes
1995-06-25 09:35:56 +00:00
Satoshi Asami 14e07b2241 Add new option NO_MTREE. If set, bsd.port.mk won't run mtree to
set permissions and ownerships of PREFIX (usually /usr/local).  This
is the default if USE_IMAKE or USE_X11 is set.

This should be useful for machines like thud, where we want to keep
the /usr/local subtree writable to a group ("ports" in our case).  Anybody
who installs stuff in /usr/local should have this set in the environment.

Note this won't affect anything the pkg_* suite does.
1995-06-25 06:30:51 +00:00
Bruce Evans 33dc7e1b84 Reduce timeout frequency from `hz' to 0 if no ports are open or to 1 if
no ports are active, provided there are no polled ports and no
`LOSESOUTINTS' ports.  Do a little more in the interrupt handler instead.
This is a little less efficient if there are are many active ports but
a little more efficient otherwise.  Polled ports are ones with no irq
specified (as before).  `LOSESOUTINTS' ports are ones with 0x08 set in
their config flags.  Unless this flag is set, it will now take up to one
second to recover from lost output interrupts, if any.  Some 8250s and
16450s lose output interrupts.

Improve output buffering: copy the clist buffer to 2 linear buffers if
necessary and possible instead of to 1.  Handle an arbitrary queue of
buffers in the interrupt handler.  Check for waking up sleepers after
copying characters out of the clist buffer instead of before.

Delay translation of TIOCM_DTR to MCR_DTR etc. so that the top level
routines are more machine independent.

Fix bogus device register in unused code.
1995-06-25 04:51:01 +00:00
Bruce Evans cc490fc73e Update a comment to match the 1993/12/03 change to `np' and fix some
punctuation.
1995-06-25 04:08:29 +00:00
Bruce Evans 20d4de8fd4 Optionally set the dump device. 1995-06-25 04:01:32 +00:00
Bruce Evans facd9d3003 usr/ucb -> usr/bin and usr/msgs -> var/msgs. 1995-06-25 03:52:30 +00:00
Bruce Evans d6c492bb18 41 headers must be implicitly included and one more (<sys/param.h>) must
be explicitly included before kvm_getprocs() can be used.
1995-06-25 03:35:49 +00:00
Joerg Wunsch d0be0c2b72 Update the man page for kvm_getprocs.3 to reflect our sysctl-based
kvm mechanism.

Submitted by:	(Vic Abell) <abe@cc.purdue.edu>
1995-06-24 18:53:09 +00:00
Bill Paul 14eb79c475 Argh!! Got the arguments in the printf() backwards. 1995-06-24 18:12:17 +00:00
Bill Paul 1724847d45 Whoops: getnewpasswd() always says "Changing local password for foo".
Change things slightly so this message says "local" or "YP" as needed
so we can use it for both NIS and local password changes without
confusing people.
1995-06-24 18:08:25 +00:00
Bill Paul a7aa6bd1ea getnewyppasswd() in yp_passwd.c doesn't generate correct encrypted
password strings when DES isn't used; somehow the encrypted password
is corrupted and it winds up containing control chars, which yppasswdd
subsequently rejects. This breaks yppasswd on non-DES FreeBSD systems
using NIS.

Fix: scrap getnewyppasswd() entirely and use getnewpasswd() from
local_password.c, since it already works properly and is virtually
identical to getnewyppasswd() anyway. (Wish I'd noticed this sooner.)

This fixes a problem just reported on comp.unix.bsd.freebsd.misc.
1995-06-24 17:47:51 +00:00
Andrey A. Chernov 2f22cc074c Back out prev. NetBSD fix, it cause skipping some error constructions,
don't delete initial space from line instead
1995-06-24 17:34:15 +00:00
Andrey A. Chernov 33e5f8f7b0 Don't make error on ^<spaces>\n
Obtained from: NetBSD
1995-06-24 17:23:31 +00:00
Joerg Wunsch 29eaad36e5 Make parsetime.c more consistent by using the (already declared) enum
type instead of int all over the place.  (Cosmetic, enhances
debugging.)

Point out that a date specification _must_ follow the time of day
spec, in the man page.  This clarifies the last point PR # of bin/483:
"at doesn't seem to ..." (the remainder has already been fixed with
version 1.3 of parsetime.c).
1995-06-24 17:15:56 +00:00