dragonfly.git
15 years agoRemove leftover 'is'.
Jeroen Ruigrok/asmodai [Sun, 31 Oct 2004 11:11:54 +0000 (11:11 +0000)]
Remove leftover 'is'.

15 years agoDocument ENOMEM error case, note how strdup() is 1003:2004 sanctioned.
Jeroen Ruigrok/asmodai [Sun, 31 Oct 2004 11:09:44 +0000 (11:09 +0000)]
Document ENOMEM error case, note how strdup() is 1003:2004 sanctioned.

15 years agoAdd iso-C alias and p1003.1-2004 definition.
Jeroen Ruigrok/asmodai [Sun, 31 Oct 2004 10:31:21 +0000 (10:31 +0000)]
Add iso-C alias and p1003.1-2004 definition.

15 years agoWe have to support uncompress by default, because zcat is used e.g.
Joerg Sonnenberger [Sun, 31 Oct 2004 10:26:26 +0000 (10:26 +0000)]
We have to support uncompress by default, because zcat is used e.g.
by the port system for both gzip and compress files. Therefore
replace GZIP_UNCOMPRESS with NO_GZIP_UNCOMPRESS and the reverse meaning.

15 years agoAdd NetBSD 2.0 and DragonFly 1.1.
Jeroen Ruigrok/asmodai [Sun, 31 Oct 2004 10:14:03 +0000 (10:14 +0000)]
Add NetBSD 2.0 and DragonFly 1.1.

15 years agoFix cpdup man page. The option -v[vvv] should be -v[vv].
Liam J. Foy [Sun, 31 Oct 2004 00:43:14 +0000 (00:43 +0000)]
Fix cpdup man page. The option -v[vvv] should be -v[vv].

Submitted by: Sascha Wildner <saw@online.de>

15 years agoBring in Jeff Wheelhouse's CLOG / circular log file support for syslogd,
Matthew Dillon [Sat, 30 Oct 2004 20:26:48 +0000 (20:26 +0000)]
Bring in Jeff Wheelhouse's CLOG / circular log file support for syslogd,
With some formatting changes.

Side note: CLOG's use of mmap within syslogd is very dangerous and could
lead to syslogd seg-faulting out, especially since the control structure
appears to reside at the end of the physical log file.  Users of circular
log files must take care.

Requested-by: The MOB!
15 years agoThe PRId64 check was wrong, causing bootstrapping failures on
Matthew Dillon [Sat, 30 Oct 2004 18:48:31 +0000 (18:48 +0000)]
The PRId64 check was wrong, causing bootstrapping failures on
FreeBSD-4.x boxes.

15 years agoThe last fix wasn't good enough. This one causes the SWIDTH lines to be
Matthew Dillon [Sat, 30 Oct 2004 18:46:07 +0000 (18:46 +0000)]
The last fix wasn't good enough.  This one causes the SWIDTH lines to be
ignored rather then mapped as 0.

15 years agoConditionalize _CTYPE_SW* for bootstrap purposes.
Matthew Dillon [Sat, 30 Oct 2004 18:14:35 +0000 (18:14 +0000)]
Conditionalize _CTYPE_SW* for bootstrap purposes.

Reported-by: esmith <esmith@patmedia.net>
15 years ago- Remove all registers in bin/. This saves us doing it each time we come
Liam J. Foy [Sat, 30 Oct 2004 13:34:50 +0000 (13:34 +0000)]
- Remove all registers in bin/. This saves us doing it each time we come
  across them.

Ok'ed by: Joerg and kernel@

15 years agoAdd omitted space after 'while'.
Jeroen Ruigrok/asmodai [Sat, 30 Oct 2004 12:14:14 +0000 (12:14 +0000)]
Add omitted space after 'while'.

Submitted by: Sascha Wildner
Asked to commit by: joerg

15 years agoRemove the old one-true-awk.
Joerg Sonnenberger [Sat, 30 Oct 2004 11:51:30 +0000 (11:51 +0000)]
Remove the old one-true-awk.

15 years ago-Set WARNS to 6
Liam J. Foy [Fri, 29 Oct 2004 17:09:09 +0000 (17:09 +0000)]
-Set WARNS to 6
-Add -b option. The option will print the time and date of
 last reboot
-Update man page for the -b option
-Add DragonFly tag

Ok'ed by: Joerg
Subitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years agoAdd special case for the german whois nameserver. Without the
Liam J. Foy [Fri, 29 Oct 2004 15:44:41 +0000 (15:44 +0000)]
Add special case for the german whois nameserver. Without the
'-T dn,ace -C US-ASCII' option one does only get:

$ whois nic.de

domain:    nic.de
status:    connect

More information available on:

http://www.denic.de/en/domains/technik/denic_whois-server/index.html

Obtained-From: FreeBSD
Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years ago- Remove unnecessary (void) casts
Liam J. Foy [Fri, 29 Oct 2004 15:18:53 +0000 (15:18 +0000)]
- Remove unnecessary (void) casts
- Use mkstemp over mktemp

Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years ago- Bump WARNS to 6
Liam J. Foy [Fri, 29 Oct 2004 15:10:55 +0000 (15:10 +0000)]
- Bump WARNS to 6
- Remove unnecessary (void) casts
- Add $DragonFly$ tag

Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years ago- Add $DragonFly$
Liam J. Foy [Fri, 29 Oct 2004 13:52:53 +0000 (13:52 +0000)]
- Add $DragonFly$
- Add WARNS?= 6
- Static usage()
- Add setlocale() call
- Remove ? case

15 years agoUse rune.h instead of runetype.h.
Jeroen Ruigrok/asmodai [Fri, 29 Oct 2004 06:03:21 +0000 (06:03 +0000)]
Use rune.h instead of runetype.h.
Add swidth definitions and lex code to mklocale.
Update manual page with character set encoding information.
Remove deprecated keyword.

Taken from: FreeBSD
Submitted by: Andreas Hauser

15 years agoAdd more locales:
Jeroen Ruigrok/asmodai [Fri, 29 Oct 2004 05:55:50 +0000 (05:55 +0000)]
Add more locales:

Amharic (Ethiopic), Belarusian, Armenian, Kazakh, Korean, various Chinese
encodings.

Taken from: FreeBSD
Submitted by: Andreas Hauser

15 years agoAdd definitions for _CTYPE_SW[0-4MS].
Jeroen Ruigrok/asmodai [Fri, 29 Oct 2004 05:44:40 +0000 (05:44 +0000)]
Add definitions for _CTYPE_SW[0-4MS].

Taken from: FreeBSD

15 years agounmount was not removing the negative hits associated with a mount point.
Matthew Dillon [Thu, 28 Oct 2004 18:56:52 +0000 (18:56 +0000)]
unmount was not removing the negative hits associated with a mount point.
Assign ncp->nc_mount for all nodes and simplify cache_purgevfs() to handle
all cases.

15 years ago-Setmode will deal with the octals, so we dont need to.
Liam J. Foy [Thu, 28 Oct 2004 16:49:24 +0000 (16:49 +0000)]
-Setmode will deal with the octals, so we dont need to.
-Setmode can also be caused to fail because of malloc().
 We test to see setmode() has failed. If it has we check errno.
 If errno == 0 then we have an invalid file mode. If not malloc
 has failed and we the print the error via err().
-Remove '?' case.
-Fix some data types. This is for the setmode fix above.

3 days with no objections has passed!

15 years ago`proto' field was forgotten in the previous commit.
YONETANI Tomokazu [Thu, 28 Oct 2004 08:47:11 +0000 (08:47 +0000)]
`proto' field was forgotten in the previous commit.

Reported-By: Erik P. Skaalerud <erik (at) pentadon.com>
15 years agoSwitch to libz-based gzip.
Joerg Sonnenberger [Wed, 27 Oct 2004 16:34:32 +0000 (16:34 +0000)]
Switch to libz-based gzip.

15 years agoDefine PRId64 as "lld" for older systems laking support for it.
Joerg Sonnenberger [Wed, 27 Oct 2004 16:31:06 +0000 (16:31 +0000)]
Define PRId64 as "lld" for older systems laking support for it.
This is necessary e.g. for FreeBSD 4.9 to build.

Submitted-by: Matt Dillon
15 years agoSince there isn't an authpf user we'll have to grep for the authpf
David Rhodus [Wed, 27 Oct 2004 16:09:32 +0000 (16:09 +0000)]
Since there isn't an authpf user we'll have to grep for the authpf
group member.

Noted by: walt <wa1ter@myrealbox.com>

15 years agoRemove unused variable.
Matthew Dillon [Wed, 27 Oct 2004 08:57:48 +0000 (08:57 +0000)]
Remove unused variable.

15 years agonull_revoke() needs to return 0.
Matthew Dillon [Wed, 27 Oct 2004 08:52:06 +0000 (08:52 +0000)]
null_revoke() needs to return 0.

15 years agoFix a NULL pointer dereference panic that occurs when the TCP protocol
Matthew Dillon [Wed, 27 Oct 2004 03:43:47 +0000 (03:43 +0000)]
Fix a NULL pointer dereference panic that occurs when the TCP protocol
stack races against userland while closing a tcp connection.  It is
possible for userland to queue a disconnect request but for the protocol
stack to then receive a packet that causes it to call tcp_drop()->tcp_close()
which also disconnects the inpcb from the tcpcb.  When the protocol stack
then processes the disconnect request it hits the panic because the inpcb
no longer has a tcpcb connected to it.

The bug generally only occured on SMP systems where the latency in intra-cpu
communication opens up the window of opportunity for the bug to occur.

Panic-Reported-by: Adam K Kirchhoff <adamk@voicenet.com>
15 years agoAdd a section to UPDATING describing the users and groups that might have
Matthew Dillon [Wed, 27 Oct 2004 02:51:41 +0000 (02:51 +0000)]
Add a section to UPDATING describing the users and groups that might have
to be added.

Remove the authpf user requirement.  Only an authpf group is required.

Reported-by: esmith <esmith@patmedia.net>
15 years agoFix a seg-fault if -l is used without a /dev prefix, e.g. cu -l cuaa0. Of
Matthew Dillon [Tue, 26 Oct 2004 22:10:13 +0000 (22:10 +0000)]
Fix a seg-fault if -l is used without a /dev prefix, e.g. cu -l cuaa0.  Of
course, this still fails because -l expects a device path, but at least now
it doesn't seg-fault.

Reported-by: Mark Cullen <mark.cullen@dsl.pipex.com>
15 years agoChange the variable from CCVER_DEFAULT to OBJFORMAT_BUILTIN_CCVER_DEFAULT
Joerg Sonnenberger [Tue, 26 Oct 2004 19:14:18 +0000 (19:14 +0000)]
Change the variable from CCVER_DEFAULT to OBJFORMAT_BUILTIN_CCVER_DEFAULT
and BINUTILSVER_DEFAULT to OBJFORMAT_BULTIN_BINUTILSVER_DEFAULT.

Wanted-better-name: Matthew Dillon

15 years agoChange the way binutils versions are handled. Depending on CCVER,
Joerg Sonnenberger [Tue, 26 Oct 2004 19:06:02 +0000 (19:06 +0000)]
Change the way binutils versions are handled. Depending on CCVER,
either BINUTILSVER_GCC2 (CCVER == gcc2), BINUTILSVER_GCC34 (CCVER == gcc34)
or BINUTILSVER_DEFAULT (other values of CCVER) are choosen.

The BINUTILSVER_DEFAULT knop is intended for developers, normal users
should have no reason to set it.

15 years agogcc3 ==> gcc34
Joerg Sonnenberger [Tue, 26 Oct 2004 16:34:37 +0000 (16:34 +0000)]
gcc3 ==> gcc34

15 years agoCheck that the authpf user and group are installed before starting the
David Rhodus [Tue, 26 Oct 2004 16:14:55 +0000 (16:14 +0000)]
Check that the authpf user and group are installed before starting the
installworld process.

15 years agoAdd support to specify the default compiler and binutil version in
Joerg Sonnenberger [Tue, 26 Oct 2004 11:27:46 +0000 (11:27 +0000)]
Add support to specify the default compiler and binutil version in
/etc/make.conf.

Use entries of the form
CCVER_DEFAULT= gcc34
BINUTILSVER_DEFAULT= binutils214
to use gcc34 and the new binutils by default.

Add the DragonFly copyright to objformat.c.

15 years agoAdd gzip based on libz. This is faster for decompression and yields
Joerg Sonnenberger [Tue, 26 Oct 2004 11:19:31 +0000 (11:19 +0000)]
Add gzip based on libz. This is faster for decompression and yields
better compression than GNU gzip (300 KB for the plan9 ISO image).

The optional support for decompression of compress and bzip2 is disabled,
the normal frontends should be used instead. They can be activated by
setting GZIP_UNCOMPRESS and GZIP_UNBZIP2 respectively.

The only missing features from GNU gzip are the omission of zip support
(it could only handle the first entry anyway) and unpack support.

This differs from the NetBSD version in that all compile time warnings
has been fixed.

Obtained-from: NetBSD

15 years agoRemove GNU-CSU Makefile
Joerg Sonnenberger [Tue, 26 Oct 2004 10:40:48 +0000 (10:40 +0000)]
Remove GNU-CSU Makefile

15 years agoRemove the GCC 3.3 library build framework.
Joerg Sonnenberger [Tue, 26 Oct 2004 10:34:14 +0000 (10:34 +0000)]
Remove the GCC 3.3 library build framework.

15 years agoRIP GNU patch.
Joerg Sonnenberger [Tue, 26 Oct 2004 10:33:07 +0000 (10:33 +0000)]
RIP GNU patch.

15 years ago- fix order problem in Makefile, Makefile.${ARCH} has to be included before
Joerg Sonnenberger [Tue, 26 Oct 2004 10:22:11 +0000 (10:22 +0000)]
- fix order problem in Makefile, Makefile.${ARCH} has to be included before
  the init.c rule, otherwise the gdbarch init fails
- fix the one occurence of __FreeBSD__ in gdb sources

15 years agoFix bugs in the vm_map_entry reservation and zalloc code. This code is a bit
Matthew Dillon [Tue, 26 Oct 2004 04:33:11 +0000 (04:33 +0000)]
Fix bugs in the vm_map_entry reservation and zalloc code.  This code is a bit
sticky because zalloc must be able to call kmem_alloc*() in order to extend
mapentzone to allocate a new chunk of vm_map_entry structures, and
kmem_alloc*() *needs* two vm_map_entry structures in order to map the new
data block into the kernel.  To avoid a chicken-and-egg recursion there must
already be some vm_map_entry structures available for kmem_alloc*() to use.

To ensure that structures are available the vm_map_entry cache maintains
a 'reserve'.  This cache is initially populated from the vm_map_entry's
allocated via zbootinit() in vm_map.c.  However, since this is a per-cpu
cache there are situations where the vm_map subsystem will be used on other
cpus before the cache can be populated on those cpus, but after the static
zbootinit structures have all been used up.  To fix this we statically
allocate two vm_map_entry structures for each cpu which is sufficient for
zalloc to call kmem_alloc*() to allocate the remainder of the reserve.
Having a lot preloaded modules seems to be able to trigger the bug.

Also get rid of gd_vme_kdeficit which was a confusing methodology to
keep track of kernel reservations.  Now we just have gd_vme_avail and
a negative count indicates a deficit (the reserve is being dug into).

From-panic-reported-by: Adam K Kirchhoff <adamk@voicenet.com>
15 years agoDocument bus_dmamem_alloc() a bit more.
Matthew Dillon [Tue, 26 Oct 2004 04:22:32 +0000 (04:22 +0000)]
Document bus_dmamem_alloc() a bit more.

15 years ago- Fix some sentences
Liam J. Foy [Mon, 25 Oct 2004 22:04:18 +0000 (22:04 +0000)]
- Fix some sentences

Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years ago- Remove registers
Liam J. Foy [Mon, 25 Oct 2004 22:01:06 +0000 (22:01 +0000)]
- Remove registers
- Remove unnecessary (void) casts

Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years ago- Remove main() proto
Liam J. Foy [Mon, 25 Oct 2004 21:48:37 +0000 (21:48 +0000)]
- Remove main() proto

Submitted by: Douwe Kiela <virtus@wanadoo.nl>

15 years agoRemove register keyword usage.
David Rhodus [Mon, 25 Oct 2004 19:39:09 +0000 (19:39 +0000)]
Remove register keyword usage.

Add missing $DragonFly$ keyword to the following files:
src/lib/libc/db/btree/bt_utils.c
src/lib/libc/db/hash/hash_log2.c
src/lib/libc/net/getproto.c
src/lib/libc/net/getprotoent.c
src/lib/libc/net/getprotoname.c
src/lib/libc/net/getservbyname.c
src/lib/libc/net/getservbyport.c
src/lib/libc/net/iso_addr.c
src/lib/libc/net/linkaddr.c
src/lib/libc/net/ns_ntoa.c
src/lib/libc/quad/muldi3.c
src/lib/libc/quad/qdivrem.c
src/lib/libc/rpc/authdes_prot.c
src/lib/libc/rpc/key_prot_xdr.c
src/lib/libcompat/4.3/insque.c
src/lib/libcompat/4.3/lsearch.c
src/lib/libcompat/4.3/remque.c
src/lib/libcompat/4.4/cuserid.c
src/lib/libcompat/regexp/regexp.c
src/lib/libcompat/regexp/regsub.c
src/lib/libcr/db/btree/bt_utils.c
src/lib/libcr/db/hash/hash_log2.c
src/lib/libcr/net/getproto.c
src/lib/libcr/net/getprotoent.c
src/lib/libcr/net/getprotoname.c
src/lib/libcr/net/getservbyname.c
src/lib/libcr/net/getservbyport.c
src/lib/libcr/net/iso_addr.c
src/lib/libcr/net/linkaddr.c
src/lib/libcr/net/ns_ntoa.c
src/lib/libcr/quad/muldi3.c
src/lib/libcr/quad/qdivrem.c
src/lib/libcr/rpc/authdes_prot.c
src/lib/libcr/rpc/key_prot_xdr.c
src/lib/libedit/common.c
src/lib/libedit/emacs.c
src/lib/libipx/ipx_ntoa.c
src/lib/libm/common_source/fmod.c
src/lib/libstand/ether.c
src/lib/libstand/fstat.c
src/lib/libstand/gets.c
src/lib/libstand/ioctl.c
src/lib/libstand/netif.c
src/lib/libstand/rarp.c
src/lib/libstand/rpc.c
src/lib/libstand/strcasecmp.c
src/lib/libstand/strtol.c
src/lib/libstand/write.c

15 years agoRemove the vfs page replacement optimization and its ENABLE_VFS_IOOPT option.
Matthew Dillon [Mon, 25 Oct 2004 19:14:34 +0000 (19:14 +0000)]
Remove the vfs page replacement optimization and its ENABLE_VFS_IOOPT option.
This never worked properly... that is, the semantics are broken compared to
a normal read or write in that the read 'buffer' will be modified out from
under the caller if the underlying file is.

What is really needed here is a copy-on-write feature that works in both
directions, similar to how a shared buffer is copied after a fork() if either
the parent or child modify it.  The optimization will eventually rewritten
with that in mind but not right now.

15 years ago-Remove main proto
Liam J. Foy [Mon, 25 Oct 2004 18:25:36 +0000 (18:25 +0000)]
-Remove main proto
-Static usage()
-Add setlocale() call
-Remove '?' case
-Remove unnecessary casts

15 years agoTest commit! Thanks eirikn!
Liam J. Foy [Mon, 25 Oct 2004 17:09:40 +0000 (17:09 +0000)]
Test commit! Thanks eirikn!

15 years agoSync with FreeBSD-current:
Hidetoshi Shimokawa [Mon, 25 Oct 2004 13:53:27 +0000 (13:53 +0000)]
Sync with FreeBSD-current:
- Split dcons core and OS dependent part.
- Use dcons buffer passed by loader(8).
- Invalidate dcons buffer on shutdown.

15 years agoPreserve dcons(4) buffer passed by loader(8).
Hidetoshi Shimokawa [Mon, 25 Oct 2004 13:48:42 +0000 (13:48 +0000)]
Preserve dcons(4) buffer passed by loader(8).

15 years agoGood bye, GNU awk. RIP
Joerg Sonnenberger [Mon, 25 Oct 2004 13:35:42 +0000 (13:35 +0000)]
Good bye, GNU awk. RIP

15 years agoFix a compiler warning by pre-declaring struct vnode;
Matthew Dillon [Mon, 25 Oct 2004 08:57:50 +0000 (08:57 +0000)]
Fix a compiler warning by pre-declaring struct vnode;

15 years agoSynchronize bug fixes from FreeBSD/RELENG_4.
Matthew Dillon [Sun, 24 Oct 2004 22:43:58 +0000 (22:43 +0000)]
Synchronize bug fixes from FreeBSD/RELENG_4.

15 years agoAdd a default for X_WINDOW_SYSTEM in the dfports override case.
Matthew Dillon [Sun, 24 Oct 2004 22:40:41 +0000 (22:40 +0000)]
Add a default for X_WINDOW_SYSTEM in the dfports override case.

Reported-by: Adam K Kirchhoff <adamk@voicenet.com>
15 years agoChange DFD to DFB to remain consistent.
Scott Ullrich [Sun, 24 Oct 2004 20:05:07 +0000 (20:05 +0000)]
Change DFD to DFB to remain consistent.

Noticed-by: Sean Kelley <sean.kuxi _AT_ gmail.com>

15 years agoMerge from vendor branch GDB:
Joerg Sonnenberger [Sun, 24 Oct 2004 19:56:26 +0000 (19:56 +0000)]
Merge from vendor branch GDB:
Import GDB 6.2.1 as obtained from ftp.gnu.org without the files in
README.DELETED.

15 years agoImport GDB 6.2.1 as obtained from ftp.gnu.org without the files in
Joerg Sonnenberger [Sun, 24 Oct 2004 19:56:26 +0000 (19:56 +0000)]
Import GDB 6.2.1 as obtained from ftp.gnu.org without the files in
README.DELETED.

15 years agoComplete doc infrastructure.
Joerg Sonnenberger [Sun, 24 Oct 2004 19:17:21 +0000 (19:17 +0000)]
Complete doc infrastructure.

15 years agoAdd the info pages for GDB 6. The inc-hist.texinfo and rluser.texinfo are
Joerg Sonnenberger [Sun, 24 Oct 2004 19:05:39 +0000 (19:05 +0000)]
Add the info pages for GDB 6. The inc-hist.texinfo and rluser.texinfo are
copies from the gdb-6.2.1/readline/doc, this way it is easier to specify the
delete list. The corresponding files from readline-5.0 give problems, so I
can't use them without figuring out what is wrong.

15 years agoSynchronize a few libi386 issues from FreeBSD. Fix a bounce buffer bug,
Matthew Dillon [Sun, 24 Oct 2004 18:36:05 +0000 (18:36 +0000)]
Synchronize a few libi386 issues from FreeBSD.  Fix a bounce buffer bug,
a possible stack overflow in an OemId copy, an EBDA search bug, and ignore
devices with invalid sector size specifications in lsdev.

Taken-from: FreeBSD

15 years agoHide prototype for tilde_expand, it's incorrect now.
Joerg Sonnenberger [Sun, 24 Oct 2004 18:12:11 +0000 (18:12 +0000)]
Hide prototype for tilde_expand, it's incorrect now.

Submitted-by: Simon 'corecode' Schubert
15 years agoForced commit to add missing annotations.
Joerg Sonnenberger [Sun, 24 Oct 2004 18:05:10 +0000 (18:05 +0000)]
Forced commit to add missing annotations.

Obtained-from: devel/gdb6, FreeBSD ports collection

15 years agoBuild framework for GDB 6.2.1.
Joerg Sonnenberger [Sat, 23 Oct 2004 17:02:38 +0000 (17:02 +0000)]
Build framework for GDB 6.2.1.

15 years agoMerge from vendor branch READLINE:
Joerg Sonnenberger [Sat, 23 Oct 2004 16:58:53 +0000 (16:58 +0000)]
Merge from vendor branch READLINE:
Import GNU readline 5.0.

Submitted-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
15 years agoImport GNU readline 5.0.
Joerg Sonnenberger [Sat, 23 Oct 2004 16:58:53 +0000 (16:58 +0000)]
Import GNU readline 5.0.

Submitted-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
15 years agoImport GNU readline 5.0. vendor/READLINE
Joerg Sonnenberger [Sat, 23 Oct 2004 16:58:53 +0000 (16:58 +0000)]
Import GNU readline 5.0.

Submitted-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
15 years agoFix the references to libz sources scattered over the tree, make them
Joerg Sonnenberger [Sat, 23 Oct 2004 15:58:18 +0000 (15:58 +0000)]
Fix the references to libz sources scattered over the tree, make them
include a Makefile fragment from lib/libz.

15 years agoAdd eui64.5.
Hidetoshi Shimokawa [Sat, 23 Oct 2004 15:36:43 +0000 (15:36 +0000)]
Add eui64.5.

15 years agoWelcome GNU bc to the Attic.
Joerg Sonnenberger [Sat, 23 Oct 2004 14:24:41 +0000 (14:24 +0000)]
Welcome GNU bc to the Attic.

15 years agoI have to specify SCRIPTSNAME too, otherwise bsd.prog.mk strips the extension.
Joerg Sonnenberger [Sat, 23 Oct 2004 14:14:46 +0000 (14:14 +0000)]
I have to specify SCRIPTSNAME too, otherwise bsd.prog.mk strips the extension.

15 years agoUse SCRIPTS instead of a beforeinstall target, it's cleaner.
Joerg Sonnenberger [Sat, 23 Oct 2004 14:07:31 +0000 (14:07 +0000)]
Use SCRIPTS instead of a beforeinstall target, it's cleaner.

15 years agoRemove the GCC 3.3 build system.
Joerg Sonnenberger [Sat, 23 Oct 2004 14:06:08 +0000 (14:06 +0000)]
Remove the GCC 3.3 build system.

15 years agoMerge from vendor branch ZLIB:
Joerg Sonnenberger [Sat, 23 Oct 2004 13:49:54 +0000 (13:49 +0000)]
Merge from vendor branch ZLIB:
Import zlib-1.2.2 using new-style contrib handling.

Important changes since 1.1.4 include:
- New and improved inflate code, which is about 20% faster.
- New and improved crc32(), which is about 50% faster.

15 years agoImport zlib-1.2.2 using new-style contrib handling.
Joerg Sonnenberger [Sat, 23 Oct 2004 13:49:54 +0000 (13:49 +0000)]
Import zlib-1.2.2 using new-style contrib handling.

Important changes since 1.1.4 include:
- New and improved inflate code, which is about 20% faster.
- New and improved crc32(), which is about 50% faster.

15 years agoImport zlib-1.2.2 using new-style contrib handling.
Joerg Sonnenberger [Sat, 23 Oct 2004 13:49:54 +0000 (13:49 +0000)]
Import zlib-1.2.2 using new-style contrib handling.

Important changes since 1.1.4 include:
- New and improved inflate code, which is about 20% faster.
- New and improved crc32(), which is about 50% faster.

15 years agostyle(9) cleanup.
Eirik Nygaard [Sat, 23 Oct 2004 13:33:36 +0000 (13:33 +0000)]
style(9) cleanup.
Submitted by: Ulf Lilleengen <lulf@kerneled.org>

15 years agoGCC 3.4 doesn't check for NULL format-strings for __attribute__((printf))
Joerg Sonnenberger [Sat, 23 Oct 2004 13:10:45 +0000 (13:10 +0000)]
GCC 3.4 doesn't check for NULL format-strings for __attribute__((printf))
by default. Therefore the __printflike macro has to include a nonnull
attribute too, which printf0like doesn't need. This makes the macros
work as expected again.

15 years agoAdd some more functions for -liberty and make the library WARNS=6 clean.
Joerg Sonnenberger [Sat, 23 Oct 2004 12:15:21 +0000 (12:15 +0000)]
Add some more functions for -liberty and make the library WARNS=6 clean.

As replacement of the missing documentation:
- buildargv, freeargv and dupargv help with managing argv lists as NULL
  terminated lists of strings
- hex_p and hex_value help with the detection and evaluation of hex digests,
  they might be replaced by an inline version later
- concat and reconcat can be used to concat an arbitrary number of strings
- xatexit, xexit and xstrerror just call the corresponding normal functions,
  they already provide the GNU functionality
- xcalloc, xmalloc, xmemdup, xrealloc and xstrdup work as expected but
  terminate the program if the memory allocation can not be fullfilled

15 years agoGenerate the BRANCH field from the current tag, use CURRENT if the current
Matthew Dillon [Fri, 22 Oct 2004 23:43:25 +0000 (23:43 +0000)]
Generate the BRANCH field from the current tag, use CURRENT if the current
tag is the HEAD.  This probably needs more work when we get to the next
release to strip the release portion of the tag since the release is already
generated (or perhaps we will auto-generate the release portion as well).

15 years agoFix bugs in the last commit. Some islink checks and a fd->fdval change was
Matthew Dillon [Fri, 22 Oct 2004 22:34:10 +0000 (22:34 +0000)]
Fix bugs in the last commit.  Some islink checks and a fd->fdval change was
missing causing failures with symlinks.

15 years agoThis is a really nice rewrite of rc.firewall that cleans it up and adds
Matthew Dillon [Fri, 22 Oct 2004 20:26:11 +0000 (20:26 +0000)]
This is a really nice rewrite of rc.firewall that cleans it up and adds
additional firewall_* rc.conf variables, with appropriate defaults, for
quick and easy rc-based firewall configuration.  More sophisticated
configurations should continue to use the ipfw.conf mechanism.

The default client firewall is now similar to the description in the
'man firewall' manual page, allowing certain basic services ports
through and those ICMP messages required for proper network and protocol
management.

Submitted-by: Andreas Hauser <andy@splashground.de>
15 years agoThe old lookup() API is extremely complex. Even though it will be ripped out
Matthew Dillon [Fri, 22 Oct 2004 18:03:50 +0000 (18:03 +0000)]
The old lookup() API is extremely complex.  Even though it will be ripped out
soon, I'm documenting the procedure so I don't have to keep running through
it to figure out what is going on.  Do a better job describing the new
vgone() API (the old API required the vnode to be in a very weird state.
The new API requires the vnode to be VX locked and refd and returns with the
vnode in the same state).

15 years agoMake an existing vnode lock assertion a bit more verbose.
Matthew Dillon [Fri, 22 Oct 2004 18:00:26 +0000 (18:00 +0000)]
Make an existing vnode lock assertion a bit more verbose.

15 years agoFix a final bug in the vfs cache cleaning code. An incorrect assertion was
Matthew Dillon [Fri, 22 Oct 2004 17:59:59 +0000 (17:59 +0000)]
Fix a final bug in the vfs cache cleaning code.  An incorrect assertion was
causing occassional panics.

15 years agoCorrect use of the flags argument to the recvmsg system call.
Jeffrey Hsu [Fri, 22 Oct 2004 13:42:14 +0000 (13:42 +0000)]
Correct use of the flags argument to the recvmsg system call.

15 years agoSet the file modes for those rc files which are unconditionally replaced by
Matthew Dillon [Thu, 21 Oct 2004 18:49:51 +0000 (18:49 +0000)]
Set the file modes for those rc files which are unconditionally replaced by
'make upgrade' to be read-only to prevent accidental editing by the
sysop.  A sysop can of course decide to modify them anyway, but make upgrade
currently overwrites them so it isn't a good idea.

Issue-noticed-by: <justin@shiningsilence.com>
15 years agoChange the default handling for kernels built with debugging info (DEBUG=-g).
Matthew Dillon [Wed, 20 Oct 2004 23:03:05 +0000 (23:03 +0000)]
Change the default handling for kernels built with debugging info (DEBUG=-g).
Since GENERIC includes this make option, this applies to most kernels.

Previously, installed kernels were stripped of their debug information and
installed modules were not.  With this commit, the debug info is left intact
in the installed kernel and debug information is stripped from all backup
copies that are made (kernel.old, modules.old).  Developers using DEBUG=-g
(which is most) may actually see root disk space go down due to the stripping
of kernel.old and modules.old (-~30MB), even though /kernel will be +~13MB
larger.

Two new makeoptions are available for specification in your kernel config or
when you run the buildkernel/nativekernel/installkernel target to make.

INSTALLSTRIPPED=1

    The installed kernel and modules will be stripped of debug info.  This
    option effectively reverts you to the pre-commit state of things.

INSTALLSTRIPPEDMODULES=1

    The installed modules will be stripped of debug info.  The kernel will
    be left with debug info intact.

What this means is that developres will no longer have to stuff a debug
kernel off somewhere to use later instead of a crash, savecore will copy
a debuggable kernel into /var/crash instead of a stripped kernel, and
snapshot and release CD's will have debug kernels and working crash dumps
right out of the box.  The memory impact of the debug kernel is zero since
the debug info is not loaded, and the run-time impact of this change is
also zero.

The intention is multi-fold:

    * To make it easier for inexperienced users to provide meaningful debug
      info to developers when posting bug reports, especially during release
      cycles.

    * To not have to make copies of debug kernels for debugging purposes.
      Such copies often get out of sync with the actually running kernel
      and savecore does not know about them.

    * To make the debugging environment more uniform, less confusing, and
      easier to use.

15 years agoFix a boot panic with the amd device. We inherited some busdma code from
Matthew Dillon [Wed, 20 Oct 2004 18:12:54 +0000 (18:12 +0000)]
Fix a boot panic with the amd device.  We inherited some busdma code from
FreeBSD which now requires that bus_dmamap_create() be called, and the
amd device was not doing that.

Reported-by: "Robin P. Blanchard" <robin.blanchard@gactr.uga.edu>
15 years agoThe last commit failed to adjust the alignment like it said it did.
Matthew Dillon [Wed, 20 Oct 2004 09:17:22 +0000 (09:17 +0000)]
The last commit failed to adjust the alignment like it said it did.

Noticed-by: Hidetoshi Shimokawa <simokawa@freebsd.org>
15 years agoOld API compatibility: The directory vnode passed to VOP_LOOKUP() must be
Matthew Dillon [Wed, 20 Oct 2004 09:00:35 +0000 (09:00 +0000)]
Old API compatibility: The directory vnode passed to VOP_LOOKUP() must be
unlocked if this is not the last component of the path, unless we are looking
up '.' in which case it must be locked because the return vnode must be
locked.  (echo "kill" > /proc/<pid>/ctl was panicing the system).

Panic-reported-by: =?ISO-8859-1?Q?Christer_=D6berg?= <christer.oberg@ornsat.com>
15 years agoSeparate out the length checks from IP dispatch and also do them along
Jeffrey Hsu [Wed, 20 Oct 2004 05:00:36 +0000 (05:00 +0000)]
Separate out the length checks from IP dispatch and also do them along
the IPSEC path to the protocol processing routines.

Reported by:  Andrew Atrens <atrens@nortelnetworks.com>

15 years agoFix an assertion, vgone() now requires that the vnode be VX locked and refd.
Matthew Dillon [Tue, 19 Oct 2004 09:29:46 +0000 (09:29 +0000)]
Fix an assertion, vgone() now requires that the vnode be VX locked and refd.

Replace the pfshead based sequential linked list with a simple hash table,
otherwise linprocfs will bog down when the system has a huge number of
processes.

Assertion-Reported-by: Frank Denis <dragonfly@pureftpd.org>
15 years agoFix bugs in the limiting code for negative-hit namecache entries. The system
Matthew Dillon [Tue, 19 Oct 2004 05:55:34 +0000 (05:55 +0000)]
Fix bugs in the limiting code for negative-hit namecache entries.  The system
was allowing too many negative entries to build up.  Since these entries by
definition do not have associated vnodes the vnode code is not responsible
for limiting the number of negative entries.  Since vnodes associated
with non-leaf namecache entries are held, the build-up of negative entries
prevented directory vnodes from being recycled and caused vnlru_proc to fail.

To fix this we check for and cleanup negative entries in both the old API
cache_enter() and the new API cache_nlookup().  Rather then just removing one
when we exceed the limit we remove 10 and we create a 90%/100% hysteresis
to avoid a non-optimal following cleanup call on every cache lookup.

Reported-by: Pawel Biernacki <kaktus@DragonFlyBSD.pl>,
     Chris Pressey <cpressey@catseye.mine.nu>
Testing-by: same
15 years agoMFC FreeBSD if_em.c 1.48 and 1.49.
Matthew Dillon [Tue, 19 Oct 2004 05:47:52 +0000 (05:47 +0000)]
MFC FreeBSD if_em.c 1.48 and 1.49.

Remove an unnecessary bus_dmamap_create and destroy for the rx and tx
descriptor rings.  No bounce buffers are ever needed since bus_dmamem_alloc()
allocates the correct type of memory and never needs a bounce buffer.

Use an alignment of 1 instead of PAGE_SIZE for the rx and tx buffer tags.
Since the e1000 DMA engines hava no constraints on the alignment of buffer
transfers, there is no reason to tell busdma that there is.  This saves a
minimum of 1 malloc call per packet and avoids needless boucning.

Use BUS_DMA_WAITOK when allocating the receive descriptor ring.  It's really
silly to use BUS_DMA_NOWAIT here, it isn't all that much memory.

A simple cached NFS test did not result in any noticeable improvement in
cpu or packet efficiency but Scott's commit message indicated a significant
improvement in a larger FreeBSD machine setup, probably oweing more to the
locks eliminated in FreeBSD (which does not apply to DragonFly).

Suggested-by: David Rhodus
Obtained from: Sandvine, Inc.  via FreeBSD  if_em.c 1.48 and 1.49 (scottl)

15 years ago* pid should be pid_t not int
Eirik Nygaard [Mon, 18 Oct 2004 18:43:37 +0000 (18:43 +0000)]
* pid should be pid_t not int
* make static functions
* bump WARNS to 6
* constify some args

Submitted by: "Liam J. Foy" <liamfoy@sepulcrum.org>

15 years ago* static functions
Eirik Nygaard [Mon, 18 Oct 2004 18:42:01 +0000 (18:42 +0000)]
* static functions
* remove main prototype
* setmode returns void *
* getmode returns mode_t
* fix setmode if an error occurs. Previous code would print invalid file mode if
  malloc had failed and the file mode was correct.
* remove '?' case

Submitted by: "Liam J. Foy" <liamfoy@sepulcrum.org>

15 years ago * Fix spelling.
Eirik Nygaard [Mon, 18 Oct 2004 17:54:35 +0000 (17:54 +0000)]
 * Fix spelling.
 * Capitalize C. [1]

Suggested by: Sascha Wildner <saw@online.de> [1]