]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
22 years agoFix one parsing bug introduced by last commit, and correct parsing
Luigi Rizzo [Sat, 10 Aug 2002 15:10:15 +0000 (15:10 +0000)]
Fix one parsing bug introduced by last commit, and correct parsing
and printing of or-blocks in address, ports and options lists.

22 years agoMajor revision of the ipfw manpage, trying to make it up-to-date
Luigi Rizzo [Sat, 10 Aug 2002 15:04:40 +0000 (15:04 +0000)]
Major revision of the ipfw manpage, trying to make it up-to-date
with ipfw2 extensions and give examples of use of the new features.

This is just a preliminary commit, where i simply added the basic
syntax for the extensions, and clean up the page (e.g. by listing
things in alphabetical rather than random order).
I would appreciate feedback and possible corrections/extensions
by interested parties.

Still missing are a more detailed description of stateful rules
(with keepalives), interaction with of stateful rules and natd (don't do
that!), examples of use with the recently introduced rule sets.

There is an issue related to the MFC: RELENG_4 still has ipfw as a
default, and ipfw2 is optional. We have two options here: MFC this
page as ipfw(8) adding a large number of "SORRY NOT IN IPFW" notes,
or create a new ipfw2(8) manpage just for -stable users.  I am all
for the first approach, but of course am listening to your comments.

22 years agoMinor corrections.
Søren Schmidt [Sat, 10 Aug 2002 11:56:03 +0000 (11:56 +0000)]
Minor corrections.

Suggested by: scottl <Scott Long>

22 years agoAdd break's to case blocks.
Mike Heffner [Sat, 10 Aug 2002 08:42:10 +0000 (08:42 +0000)]
Add break's to case blocks.

PR: bin/41511
Submitted by: Daniel Hagan <dhagan@acm.vt.edu>

22 years ago o Remove the setting and clearing of the PG_MAPPED flag. (This flag is
Alan Cox [Sat, 10 Aug 2002 07:40:30 +0000 (07:40 +0000)]
 o Remove the setting and clearing of the PG_MAPPED flag.  (This flag is
   obsolete.)

22 years ago o Remove the setting and clearing of the PG_MAPPED flag. (This flag is
Alan Cox [Sat, 10 Aug 2002 07:11:16 +0000 (07:11 +0000)]
 o Remove the setting and clearing of the PG_MAPPED flag.  (This flag is
   obsolete.)

22 years agoWhen we allocate our bus address via the kludge that we have in the
Warner Losh [Sat, 10 Aug 2002 06:37:32 +0000 (06:37 +0000)]
When we allocate our bus address via the kludge that we have in the
code to do it when the bios doesn't do it for us, flag it.  Then, when
we dealloc, do an equal kludge to get rid of the address.  This should
address the can't get IRQ and panic bug in a more graceful way.

# really should write a dealloc routine and just call it instead, since
# this might not fix things in the kldunload case.

22 years agoconfirmed OZ6912 and 6972 share same pci ID
Warner Losh [Sat, 10 Aug 2002 06:35:03 +0000 (06:35 +0000)]
confirmed OZ6912 and 6972 share same pci ID

22 years agotruss hasn't been ported to ia64 yet.
Jake Burkholder [Sat, 10 Aug 2002 06:10:17 +0000 (06:10 +0000)]
truss hasn't been ported to ia64 yet.

Noticed by: ru

22 years agoxlint seems to build fine on sparc64.
Jake Burkholder [Sat, 10 Aug 2002 05:44:44 +0000 (05:44 +0000)]
xlint seems to build fine on sparc64.

22 years agoPut getconf in the right place.
Jake Burkholder [Sat, 10 Aug 2002 05:43:40 +0000 (05:43 +0000)]
Put getconf in the right place.

22 years agoOne bugfix and one new feature.
Luigi Rizzo [Sat, 10 Aug 2002 04:37:32 +0000 (04:37 +0000)]
One bugfix and one new feature.

The bugfix (ipfw2.c) makes the handling of port numbers with
a dash in the name, e.g. ftp-data, consistent with old ipfw:
use \\ before the - to consider it as part of the name and not
a range separator.

The new feature (all this description will go in the manpage):

each rule now belongs to one of 32 different sets, which can
be optionally specified in the following form:

ipfw add 100 set 23 allow ip from any to any

If "set N" is not specified, the rule belongs to set 0.

Individual sets can be disabled, enabled, and deleted with the commands:

ipfw disable set N
ipfw enable set N
ipfw delete set N

Enabling/disabling of a set is atomic. Rules belonging to a disabled
set are skipped during packet matching, and they are not listed
unless you use the '-S' flag in the show/list commands.
Note that dynamic rules, once created, are always active until
they expire or their parent rule is deleted.
Set 31 is reserved for the default rule and cannot be disabled.

All sets are enabled by default. The enable/disable status of the sets
can be shown with the command

ipfw show sets

Hopefully, this feature will make life easier to those who want to
have atomic ruleset addition/deletion/tests. Examples:

To add a set of rules atomically:

ipfw disable set 18
ipfw add ... set 18 ... # repeat as needed
ipfw enable set 18

To delete a set of rules atomically

ipfw disable set 18
ipfw delete set 18
ipfw enable set 18

To test a ruleset and disable it and regain control if something
goes wrong:

ipfw disable set 18
ipfw add ... set 18 ...         # repeat as needed
ipfw enable set 18 ; echo "done "; sleep 30 && ipfw disable set 18

    here if everything goes well, you press control-C before
    the "sleep" terminates, and your ruleset will be left
    active. Otherwise, e.g. if you cannot access your box,
    the ruleset will be disabled after the sleep terminates.

I think there is only one more thing that one might want, namely
a command to assign all rules in set X to set Y, so one can
test a ruleset using the above mechanisms, and once it is
considered acceptable, make it part of an existing ruleset.

22 years agoAdd ia64 to platforms supported by em(4).
Bruce A. Mah [Sat, 10 Aug 2002 03:39:05 +0000 (03:39 +0000)]
Add ia64 to platforms supported by em(4).

22 years agoMy quad cpu itanium2 box has its cpu's numbered with a lid starting
Peter Wemm [Sat, 10 Aug 2002 03:36:42 +0000 (03:36 +0000)]
My quad cpu itanium2 box has its cpu's numbered with a lid starting
at 192.  Masking off bottom 4 bits is not very good here.

22 years agoNew release notes: No more TurboChannel Alpha support, drivers.flp.
Bruce A. Mah [Sat, 10 Aug 2002 03:35:58 +0000 (03:35 +0000)]
New release notes:  No more TurboChannel Alpha support, drivers.flp.

Modified release notes:  em(4) has been reported to work on ia64,
OpenSSL 0.9.6g, tweak cross-building note and note MFC.

Remove an obsolete release note about DEC 3000 support on floppies.

22 years agoFix the broken "avoid unaligned data" fix. The problem is that the builtin
Peter Wemm [Sat, 10 Aug 2002 03:00:55 +0000 (03:00 +0000)]
Fix the broken "avoid unaligned data" fix.  The problem is that the builtin
gcc memcpy "knows" about types that are supposed to be actually already
aligned and triggers alignment errors doing the memcpy itself.
"Fix" this by changing it to a bcopy().  In this case, we had:
  struct timeval *tp;
  struct timeval tv1;
  memcpy(&tv1,tp,sizeof(tv1));
.. and since gcc *knows* that a pointer to a timeval is longword aligned
and that tv1 is longword aligned, then it can use an inline that assumes
alignment.  The following works too:
  cp = (char *)tp;
  memcpy(&tv1,cp,sizeof(tv1));
Simply casting (char *)tp  for the memcpy doesn't work. :-(
This affected different 64 bit platforms in different ways and depends
a lot on gcc as well.  I've seen this on alpha and ia64 at least, although
alpha isn't doing it right now.

22 years agoResolve conflicts.
Jacques Vidrine [Sat, 10 Aug 2002 01:50:50 +0000 (01:50 +0000)]
Resolve conflicts.

22 years agoThis commit was generated by cvs2svn to compensate for changes in r101618,
Jacques Vidrine [Sat, 10 Aug 2002 01:48:01 +0000 (01:48 +0000)]
This commit was generated by cvs2svn to compensate for changes in r101618,
which included commits to RCS files with non-trunk default branches.

22 years agoImport of OpenSSL 0.9.6g.
Jacques Vidrine [Sat, 10 Aug 2002 01:48:01 +0000 (01:48 +0000)]
Import of OpenSSL 0.9.6g.

22 years agoThis commit was generated by cvs2svn to compensate for changes in r101615,
Jacques Vidrine [Sat, 10 Aug 2002 01:46:10 +0000 (01:46 +0000)]
This commit was generated by cvs2svn to compensate for changes in r101615,
which included commits to RCS files with non-trunk default branches.

22 years agoImport of OpenSSL 0.9.6f.
Jacques Vidrine [Sat, 10 Aug 2002 01:46:10 +0000 (01:46 +0000)]
Import of OpenSSL 0.9.6f.

22 years agoThis commit was generated by cvs2svn to compensate for changes in r101613,
Jacques Vidrine [Sat, 10 Aug 2002 01:40:00 +0000 (01:40 +0000)]
This commit was generated by cvs2svn to compensate for changes in r101613,
which included commits to RCS files with non-trunk default branches.

22 years agoImport of OpenSSL 0.9.6f.
Jacques Vidrine [Sat, 10 Aug 2002 01:40:00 +0000 (01:40 +0000)]
Import of OpenSSL 0.9.6f.

22 years agoPermit the creation of just cd0 if desired. Previously it always
Ian Dowse [Sat, 10 Aug 2002 00:20:32 +0000 (00:20 +0000)]
Permit the creation of just cd0 if desired. Previously it always
created cd1 as well due to an off-by-one error left over from
revision 1.249.

PR: conf/20436
Submitted by: Andre Albsmeier <andre.albsmeier@mchp.siemens.de>
MFC after: 1 week

22 years agoUse the correct loop variable so that we print all IO addresses and
Ian Dowse [Fri, 9 Aug 2002 22:04:54 +0000 (22:04 +0000)]
Use the correct loop variable so that we print all IO addresses and
not just 8 copies of the first one.

PR: bin/18157
Submitted by: German Tischler <tanis@gaspode.franken.de>

22 years agoNew release notes: ata(4)/burncd(8) support DVD+RW drives, atapicam.
Bruce A. Mah [Fri, 9 Aug 2002 21:14:55 +0000 (21:14 +0000)]
New release notes:  ata(4)/burncd(8) support DVD+RW drives, atapicam.

MFCs noted:  ucom(4)/uplcom(4)/uvscom(4), uvisor, IPFW2 (with some
wording tweaks), texinfo 4.2.

22 years agoRemove trailing whitespace.
Tony Finch [Fri, 9 Aug 2002 20:58:54 +0000 (20:58 +0000)]
Remove trailing whitespace.

22 years agoAdd the ability to use ATAPI devices via CAM.
Søren Schmidt [Fri, 9 Aug 2002 20:54:06 +0000 (20:54 +0000)]
Add the ability to use ATAPI devices via CAM.

The CAM<>ATAPI layer was submitted by "Thomas Quinot <thomas@cuivre.fr.eu.org>"
changes form the version on the net by me (formatting, ability to be used
alone without the ATAPI native device driver, proper speed reporting...)

See /sys/conf/NOTES for usage.

Submitted by: Thomas Quinot <thomas@cuivre.fr.eu.org>

22 years agoRemove some Dijkstra quotes from fortunes that are duplicated in fortunes2.
Tony Finch [Fri, 9 Aug 2002 20:37:01 +0000 (20:37 +0000)]
Remove some Dijkstra quotes from fortunes that are duplicated in fortunes2.
Move the single remaining one across to fortunes2 to join its friends.
Spell his name consistently. Remove a couple of other duplicate fortunes.

22 years agoAdd help about hint.acpi.0.disable.
Mitsuru IWASAKI [Fri, 9 Aug 2002 20:07:51 +0000 (20:07 +0000)]
Add help about hint.acpi.0.disable.

22 years agoRe-sort.
Tony Finch [Fri, 9 Aug 2002 19:54:11 +0000 (19:54 +0000)]
Re-sort.

22 years agoRemove spurious quotes.
Tony Finch [Fri, 9 Aug 2002 19:31:27 +0000 (19:31 +0000)]
Remove spurious quotes.

22 years agoCorrectly sort previous addition.
Tony Finch [Fri, 9 Aug 2002 19:30:20 +0000 (19:30 +0000)]
Correctly sort previous addition.

22 years agoSome more advice from Dijkstra.
Tony Finch [Fri, 9 Aug 2002 19:08:02 +0000 (19:08 +0000)]
Some more advice from Dijkstra.

22 years agoFix a couple of typos in a Dijkstra quote.
Tony Finch [Fri, 9 Aug 2002 19:00:10 +0000 (19:00 +0000)]
Fix a couple of typos in a Dijkstra quote.

22 years agoMake the othermta script DTRT when an mta startup script is not specified.
Gordon Tetlow [Fri, 9 Aug 2002 17:45:04 +0000 (17:45 +0000)]
Make the othermta script DTRT when an mta startup script is not specified.

Submitted by: Mike Makonnen <makonnen@pacbell.net>

22 years agoCorrect comment. We use rpcbind now, not portmap
Gordon Tetlow [Fri, 9 Aug 2002 17:34:13 +0000 (17:34 +0000)]
Correct comment. We use rpcbind now, not portmap

Submitted by: Mike Makonnen <makonnen@pacbell.net>

22 years agoCorrect comment
Gordon Tetlow [Fri, 9 Aug 2002 17:33:07 +0000 (17:33 +0000)]
Correct comment

Submitted by: Mike Makonnen <makonnen@pacbell.net>

22 years agoFixup preen.c to match its new residence.
Poul-Henning Kamp [Fri, 9 Aug 2002 16:25:32 +0000 (16:25 +0000)]
Fixup preen.c to match its new residence.

The blockcheck() function is still pulled from fsck_ffs, it probably should
live in libufs.

22 years agoIPv6 support for rcp.
Hajimu UMEMOTO [Fri, 9 Aug 2002 16:12:08 +0000 (16:12 +0000)]
IPv6 support for rcp.
You cannot specify a raw IPv6 address for now.

MFC after: 1 week

22 years agoThe boottime variable in sys/kern/kern_tc.c is a struct timeval, not a
Thomas Moestl [Fri, 9 Aug 2002 15:47:43 +0000 (15:47 +0000)]
The boottime variable in sys/kern/kern_tc.c is a struct timeval, not a
time_t, so do not use the latter as type when retrieving the variable
via libkvm. This should fix vmstat on sparc64.

22 years agoMake ppp(4) devices clonable and unloadable.
Brooks Davis [Fri, 9 Aug 2002 15:30:48 +0000 (15:30 +0000)]
Make ppp(4) devices clonable and unloadable.

22 years agoUpdate ELAST.
Poul-Henning Kamp [Fri, 9 Aug 2002 14:54:33 +0000 (14:54 +0000)]
Update ELAST.

22 years agopreen.c was a stragler after the fsck/fsck_ffs divorce.
Poul-Henning Kamp [Fri, 9 Aug 2002 14:41:37 +0000 (14:41 +0000)]
preen.c was a stragler after the fsck/fsck_ffs divorce.
fsck_ffs did not need it, but quotacheck did include it from fsck_ffs.

A repocopy has now moved the fsck_ffs/preen.c file to quotacheck/preen.c

quotacheck and fsck should probably use the same checkfstab() function
and it should possibly live in libufs.

Trouble is: they have diverged in the meantime.

At least now fsck_ffs is not in the equation anymore.

Sponsored by: DARPA & NAI Labs.

22 years agoUpdate with new error return code.
Poul-Henning Kamp [Fri, 9 Aug 2002 13:22:21 +0000 (13:22 +0000)]
Update with new error return code.

Reminded by: rwatson

22 years agoWhile we're at it, add range checks similar to those in previous commit to
Jacques Vidrine [Fri, 9 Aug 2002 12:58:11 +0000 (12:58 +0000)]
While we're at it, add range checks similar to those in previous commit to
getsockname() and getpeername(), too.

22 years agomdoc(7) police: spelling.
Ruslan Ermilov [Fri, 9 Aug 2002 12:08:47 +0000 (12:08 +0000)]
mdoc(7) police: spelling.

22 years agomdoc(7) police: tidy up the formatting.
Ruslan Ermilov [Fri, 9 Aug 2002 12:07:17 +0000 (12:07 +0000)]
mdoc(7) police: tidy up the formatting.

22 years agomdoc(7) police: punctuation.
Ruslan Ermilov [Fri, 9 Aug 2002 11:36:48 +0000 (11:36 +0000)]
mdoc(7) police: punctuation.

22 years agomdoc(7) police: sort xrefs.
Ruslan Ermilov [Fri, 9 Aug 2002 11:33:23 +0000 (11:33 +0000)]
mdoc(7) police: sort xrefs.

22 years agomdoc(7) police: punctuation.
Ruslan Ermilov [Fri, 9 Aug 2002 11:24:21 +0000 (11:24 +0000)]
mdoc(7) police: punctuation.

22 years agomdoc(7) police: whitespace nits.
Ruslan Ermilov [Fri, 9 Aug 2002 11:17:56 +0000 (11:17 +0000)]
mdoc(7) police: whitespace nits.

22 years agomdoc(7) police: laundry.
Ruslan Ermilov [Fri, 9 Aug 2002 11:15:49 +0000 (11:15 +0000)]
mdoc(7) police: laundry.

22 years agomdoc(7) police: laundry.
Ruslan Ermilov [Fri, 9 Aug 2002 11:06:03 +0000 (11:06 +0000)]
mdoc(7) police: laundry.

22 years agomdoc(7) police: tidying.
Ruslan Ermilov [Fri, 9 Aug 2002 10:59:20 +0000 (10:59 +0000)]
mdoc(7) police: tidying.

22 years agomdoc(7) police: whitespace nits.
Ruslan Ermilov [Fri, 9 Aug 2002 10:49:50 +0000 (10:49 +0000)]
mdoc(7) police: whitespace nits.

22 years agomdoc(7) police: tidy up, bump document date on behalf of the -n option.
Ruslan Ermilov [Fri, 9 Aug 2002 10:46:00 +0000 (10:46 +0000)]
mdoc(7) police: tidy up, bump document date on behalf of the -n option.

22 years agomdoc(7) police: grammar.
Ruslan Ermilov [Fri, 9 Aug 2002 10:38:34 +0000 (10:38 +0000)]
mdoc(7) police: grammar.

22 years agomdoc(7) police: kill hard sentence breaks and one double space.
Ruslan Ermilov [Fri, 9 Aug 2002 10:34:57 +0000 (10:34 +0000)]
mdoc(7) police: kill hard sentence breaks and one double space.

22 years agoMake sure we set errno sensibly in case of failure.
Poul-Henning Kamp [Fri, 9 Aug 2002 10:16:24 +0000 (10:16 +0000)]
Make sure we set errno sensibly in case of failure.

Spotted by: ache

22 years agoIntroduce a new error return code:
Poul-Henning Kamp [Fri, 9 Aug 2002 10:15:48 +0000 (10:15 +0000)]
Introduce a new error return code:
#define EDOFUS          88              /* Programming error */
This can be used to signal error situations which indicate that the
program logic or assumptions is deficient.

22 years agoAdd safeguards to never use errno == 0 as setrunelocale() error return code
Andrey A. Chernov [Fri, 9 Aug 2002 08:22:29 +0000 (08:22 +0000)]
Add safeguards to never use errno == 0 as setrunelocale() error return code

22 years agoRemove a stray ';'.
John Hay [Fri, 9 Aug 2002 08:22:02 +0000 (08:22 +0000)]
Remove a stray ';'.

22 years agoRemove a '-' that is not needed.
John Hay [Fri, 9 Aug 2002 08:18:15 +0000 (08:18 +0000)]
Remove a '-' that is not needed.

Submitted by: ru

22 years agoAdd a third floppy to releases. It will only be built if there is a
John Hay [Fri, 9 Aug 2002 07:45:42 +0000 (07:45 +0000)]
Add a third floppy to releases. It will only be built if there is a
release/${TARGET}/drivers.conf file which list drivers that have to
go into the third floppy.

Also shuffle i386/drivers.conf so that the floppies don't overflow
anymore. Anybody with real/better usage statistics is welcome to
shuffle it differently.

Reviewed by: ru

22 years agoTeach sysinstall that documents on the boot floppy might not be gzipped.
John Hay [Fri, 9 Aug 2002 07:44:43 +0000 (07:44 +0000)]
Teach sysinstall that documents on the boot floppy might not be gzipped.

Reviewed by: ru

22 years agoFix wrong member variable ordering of struct acpi_bif.
Mitsuru IWASAKI [Fri, 9 Aug 2002 07:08:53 +0000 (07:08 +0000)]
Fix wrong member variable ordering of struct acpi_bif.

22 years agoRestore autoloading of ACPI module.
David E. O'Brien [Fri, 9 Aug 2002 06:07:33 +0000 (06:07 +0000)]
Restore autoloading of ACPI module.

Document the approved ways of disabling it.
Submitted by: Daniel O'Connor <doconnor@gsoft.com.au>

22 years agoAdd additional range checks for copyout targets.
Robert Watson [Fri, 9 Aug 2002 05:50:32 +0000 (05:50 +0000)]
Add additional range checks for copyout targets.

Submitted by: Silvio Cesare <silvio@qualys.com>

22 years agoDon't auto load ACPI -- it causes trouble with my laptop and is TOTALLY
David E. O'Brien [Fri, 9 Aug 2002 05:21:01 +0000 (05:21 +0000)]
Don't auto load ACPI -- it causes trouble with my laptop and is TOTALLY
undocumented how to control its loading and queries to freebsd-current
go unanswered.

22 years agoUpdate TE policy and MAC text conversion routines to support partial
Robert Watson [Fri, 9 Aug 2002 03:09:38 +0000 (03:09 +0000)]
Update TE policy and MAC text conversion routines to support partial
label updates.  Biba and MLS already supported this.  This permits the
userland library to submit relative updates on MAC labels, rather
than submitting an entire label to replace the current label.  This
also requires changes to the MAC modules, which are forthcoming.

Obtained from: TrustedBSD Project
Sponsored by: DARPA, NAI Labs

22 years agoX-ref mac.3.
Robert Watson [Fri, 9 Aug 2002 03:03:08 +0000 (03:03 +0000)]
X-ref mac.3.

22 years agoApply the envp fix to the other call to main() as well.
Gregory Neil Shapiro [Fri, 9 Aug 2002 02:39:38 +0000 (02:39 +0000)]
Apply the envp fix to the other call to main() as well.

Submitted by: Peter Edwards <pmedwards@eircom.net>

22 years agouse the new interface to ether_input(), with eh = NULL and
Luigi Rizzo [Fri, 9 Aug 2002 01:48:28 +0000 (01:48 +0000)]
use the new interface to ether_input(), with eh = NULL and
the MAC header in the mbuf.

MFC after: 3 days

22 years agoImprove the code for detecting UID ranges so that usernames such
Ian Dowse [Fri, 9 Aug 2002 01:21:03 +0000 (01:21 +0000)]
Improve the code for detecting UID ranges so that usernames such
as "2-xhibit" are not considered as a range. Fix a problem where
the code would forget to increment argv.

PR: misc/15658

22 years agoAdd a new flag (-l) that suppresses quota checks on NFS filesystems.
Ian Dowse [Fri, 9 Aug 2002 00:53:00 +0000 (00:53 +0000)]
Add a new flag (-l) that suppresses quota checks on NFS filesystems.

PR: bin/12939
Submitted by: Neil Blakey-Milner <nbm@rucus.ru.ac.za>

22 years agoFix a few compiler warnings, sort options and make the usage()
Ian Dowse [Fri, 9 Aug 2002 00:43:36 +0000 (00:43 +0000)]
Fix a few compiler warnings, sort options and make the usage()
output match the synopsis.

22 years ago o Use pmap_page_is_mapped() in vm_page_protect() rather than the PG_MAPPED
Alan Cox [Thu, 8 Aug 2002 19:12:36 +0000 (19:12 +0000)]
 o Use pmap_page_is_mapped() in vm_page_protect() rather than the PG_MAPPED
   flag.  (This is the only place in the entire kernel where the PG_MAPPED
   flag is tested.  It will be removed soon.)

22 years agoAdd support for SX cards using TBI such as Netgear GA621.
Doug Ambrisko [Thu, 8 Aug 2002 18:33:28 +0000 (18:33 +0000)]
Add support for SX cards using TBI such as Netgear GA621.

Sponsored by: Vernier Networks.
MFC after: 1 week

22 years agoAdd support for SX cards using TBI such as Netgear GA621
Doug Ambrisko [Thu, 8 Aug 2002 18:30:39 +0000 (18:30 +0000)]
Add support for SX cards using TBI such as Netgear GA621

Sponsored by: Vernier Networks.
MFC after: 1 week

22 years agoRework storing files thoroughly. This includes:
Yaroslav Tykhiy [Thu, 8 Aug 2002 17:53:52 +0000 (17:53 +0000)]
Rework storing files thoroughly. This includes:

o Remove the race between stat(2) & fopen(3) when creating
  a unique file.

o Improve bound checking when generating a unique name from
  a given pathname.

o Ignore REST marker on APPE.  No RFC specifies this case,
  but the idea of resuming APPE's implies this.

o By default, deny upload resumes and appends by anonymous users.
  Previously these commands were translated to STOU silently,
  which led to broken files on server without any notification
  to the user.

o Add an option, -m, to allow anonymous users to modify
  existing files (e.g., to resume uploads) if filesystem
  permissions permit.

Portions obrainded from: OpenBSD
MFC after: 3 weeks

22 years agoUse '_end' symbol instead of 'end' to initialize minbrk and curbrk
Alexander Kabaev [Thu, 8 Aug 2002 17:28:07 +0000 (17:28 +0000)]
Use '_end' symbol instead of 'end' to initialize minbrk and curbrk
variables. Both symbols are set to the same value by the linker,
and _end symbol has less chances to clash with application defined
global symbols.

alpha, ia64 and sparc64 ports already use _end, i386 is now
consistent with them.

Reviewed by: bde
Approved by: obrien
Reported by: pirzyk

22 years agoDon't acquire the writer lock in rtld_exit when clearing the shared
John Polstra [Thu, 8 Aug 2002 15:53:23 +0000 (15:53 +0000)]
Don't acquire the writer lock in rtld_exit when clearing the shared
objects' reference counts.  This function is called by the atexit
mechanism at program shutdown.  I don't think the locking is necessary
here.  It caused OpenOffice builds to hang more often than not.
Credit to Martin Blapp and Matt Dillon for helping to diagnose this
problem and for testing the fix.

22 years agoDon't bogusly depend on pcic. pccard should be enough.
Warner Losh [Thu, 8 Aug 2002 15:52:55 +0000 (15:52 +0000)]
Don't bogusly depend on pcic.  pccard should be enough.

Noticed by: jhay
Forgotten  about for two years by: imp

22 years agoThe intent in rev. 1.299 was to make the CPUTYPE assignment type check
Ruslan Ermilov [Thu, 8 Aug 2002 15:43:23 +0000 (15:43 +0000)]
The intent in rev. 1.299 was to make the CPUTYPE assignment type check
bother "only those who attempts to set it to a different value".  This
got broken in rev. 1.300 (that fixed another race).

Reported by: ache

22 years agoOnly my brain can fart while fixing a previous brain fart.
Bosko Milekic [Thu, 8 Aug 2002 13:31:57 +0000 (13:31 +0000)]
Only my brain can fart while fixing a previous brain fart.

22 years agoYIKES, I take the pointy-hat for a really big braino here. I
Bosko Milekic [Thu, 8 Aug 2002 13:29:32 +0000 (13:29 +0000)]
YIKES, I take the pointy-hat for a really big braino here.  I
appologize to those of you who may have been seeing crashes in
code that uses sendfile(2) or other types of external buffers
with mbufs.

Pointed out by, and provided trace:
    Niels Chr. Bank-Pedersen <ncbp at bank-pedersen.dk>

22 years agoDue to layering problems, remove the MAC checks from vn_rdwr() -- this
Robert Watson [Thu, 8 Aug 2002 12:45:30 +0000 (12:45 +0000)]
Due to layering problems, remove the MAC checks from vn_rdwr() -- this
VOP wrapper is called from within file systems so can result in odd
loopback effects when MAC enforcement is use with the active (as
opposed to saved) credential.  These checks will be moved elsewhere.

Obtained from: TrustedBSD Project
Sponsored by: DARPA, NAI Labs

22 years agoUse the hw.usb sysctl tree instead of debug.usb.
Josef Karthauser [Thu, 8 Aug 2002 12:05:51 +0000 (12:05 +0000)]
Use the hw.usb sysctl tree instead of debug.usb.

Requested by: imp

22 years agoAdd DVD+RW support to the ATA driver and burncd. This also closes
Søren Schmidt [Thu, 8 Aug 2002 07:59:24 +0000 (07:59 +0000)]
Add DVD+RW support to the ATA driver and burncd. This also closes
PR40430 by "Peter Haight <peterh@sapros.com>" that has semilar patches
included and which I merged with my own work.

HW sponsored by: FreeBSD Foundation & FreeBSD Mall Inc

Enjoy!

22 years agoDo some work on keeping better track of stopped/continued state.
Julian Elischer [Thu, 8 Aug 2002 06:18:41 +0000 (06:18 +0000)]
Do some work on keeping better track of stopped/continued state.
I'm not sure what happenned to the original setting of the P_CONTINUED
flag. it appears to have been lost in the paper shuffling...

Submitted by: David Xu <bsddiy@yahoo.com>

22 years agoEAK! two status flags in teh proc structure were defined to the
Julian Elischer [Thu, 8 Aug 2002 06:09:32 +0000 (06:09 +0000)]
EAK! two status flags in teh proc structure were defined to the
same value!

Picked up by: David Xu <bsddiy@yahoo.com>

22 years agoRewrite locale loading procedures, so any load failure will not affect
Andrey A. Chernov [Thu, 8 Aug 2002 05:51:54 +0000 (05:51 +0000)]
Rewrite locale loading procedures, so any load failure will not affect
currently cached data.  It allows a number of nice things, like: removing
fallback code from single locale loading, remove memory leak when LC_CTYPE
data loaded again and again, efficient cache use, not only for
setlocale(locale1); setlocale(locale1), but for setlocale(locale1);
setlocale("C"); setlocale(locale1) too (i.e.  data file loaded only once).

22 years agoImplement POSIX.1-2001 (XSI)'s ulimit(3).
Mike Barcroft [Thu, 8 Aug 2002 04:50:36 +0000 (04:50 +0000)]
Implement POSIX.1-2001 (XSI)'s ulimit(3).

Submitted by: Kyle Martin <mkm@ieee.org>

22 years agoSet errno to ENOMEM for strdup too (due to malloc errno bug)
Andrey A. Chernov [Wed, 7 Aug 2002 23:52:28 +0000 (23:52 +0000)]
Set errno to ENOMEM for strdup too (due to malloc errno bug)

22 years agoFixes for the D-Link DFE-580 card.
Doug Ambrisko [Wed, 7 Aug 2002 22:31:27 +0000 (22:31 +0000)]
Fixes for the D-Link DFE-580 card.

This is pretty much fixes any issue I can find:
     -  Watchdog timeouts were due to starting the TX DMA engine
        before we had a packet ready for it.  So the first packet
        sent never got out only if we sent more then one packet
        at a time did the others make it out and not blow up.
        Of course reseting the chip then caused us not to transmit
        the first packet again ie. catch-22.  This required logic changes.
     -  Combine interrupts on TX packets being queued up.
     -  Don't keep running around the RX ring since we might get
        out of sync so only go around once per receive
     -  Let the RX engine recover via the poll interface which is
        similar to the TX interface.  This way the chip wakes
        up with no effort when we read enough packets.
     -  Do better hand-shaking on RX & TX packets so they don't
        start of to soon.
     -  Force a duplex setting when the link comes up after
        an ste_init or it will default to half-duplex and be
        really slow.  This only happens on subsequent ste_init.
        The first one worked.
     -  Don't call stat_update for every overflow.  We only monitor
        the collisions so the tick interval is good enough for that.
        Just read in the collision stats to minimize bus reads.
     -  Don't read the miibus every tick since it uses delays and
        delays are not good for performance.
     -  Tie link events directly to the miibus code so the port
        gets set correctly if someone changes the port settings.
     -  Reduce the extreme number of {R,T}FD's.  They would consume
        130K of kernel memory for each NIC.
     -  Set the TX_THRESH to wait for the DMA engine to complete
        before running the TX FIFO.  This hurts peak TX performance
        but under bi-directional load the DMA engine can't keep up
        with the FIFO.  Testing shows that we end up in the case
        anyways (a la dc(4) issues but worse since the RX engine hogs
everything).
     -  When stopping the card do a reset since the reset verifies the
card has stopped.  Otherwise on heavy RX load the RX DMA engine
is still stuffing packets into memory.  If that happens after
we free the DMA area memory bits get scribled in memory and
bad things happen.

This card still has seemingly unfixable issues under heavy RX load in
which the card takes over the PCI bus.

Sponsored by: Vernier Networks
MFC after: 1 week

22 years agoOnly attach one PHY device to a controller. NetBSD has similar code.
Doug Ambrisko [Wed, 7 Aug 2002 22:18:33 +0000 (22:18 +0000)]
Only attach one PHY device to a controller.  NetBSD has similar code.
The D-Link DFE-580 card will otherwise show 2 miibuses for each controller
and therefore 2 ukphy's.

Sponsored by: Vernier Networks
MFC after: 1 week

22 years ago - Adjust locking markup to match the proc markup.
Jeff Roberson [Wed, 7 Aug 2002 22:05:34 +0000 (22:05 +0000)]
 - Adjust locking markup to match the proc markup.
 - Add a comment about the current, unfinished, state of vnode locking.

Suggested by: bde

22 years agoAlways set errno to ENOMEM after malloc failed (as workaround).
Andrey A. Chernov [Wed, 7 Aug 2002 22:03:46 +0000 (22:03 +0000)]
Always set errno to ENOMEM after malloc failed (as workaround).
Our malloc sometimes forget to set errno, f.e. for size overflow case.

22 years agoReset __mb_cur_max to 1 when "C" or "POSIX" locales loaded after multibyte one
Andrey A. Chernov [Wed, 7 Aug 2002 20:49:25 +0000 (20:49 +0000)]
Reset __mb_cur_max to 1 when "C" or "POSIX" locales loaded after multibyte one