]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
23 years ago- Rename the lcall system call handler from Xsyscall to Xlcall_syscall
Jake Burkholder [Sun, 25 Feb 2001 02:53:06 +0000 (02:53 +0000)]
- Rename the lcall system call handler from Xsyscall to Xlcall_syscall
  to be more like Xint0x80_syscall and less like c function syscall().
- Reduce code duplication between the int0x80 and lcall handlers by
  shuffling the elfags into the right place, saving the sizeof the
  instruction in tf_err and jumping into the common int0x80 code.

Reviewed by: peter

23 years agoAdd "ELFOSABI_NONE" which is the symbol used in a copy of the old ELF spec,
David E. O'Brien [Sat, 24 Feb 2001 22:23:12 +0000 (22:23 +0000)]
Add "ELFOSABI_NONE" which is the symbol used in a copy of the old ELF spec,
as an alias for "ELFOSABI_SYSV".

23 years agoMFS: bring the consistent `compat_3_brand' support into -CURRENT
David E. O'Brien [Sat, 24 Feb 2001 22:20:11 +0000 (22:20 +0000)]
MFS: bring the consistent `compat_3_brand' support into -CURRENT
     (the work was first done in the RELENG_4 branch near a release
 during a MFC to make the code cleaner and more consistent)

23 years agoGrrr, s/INVARIANTS_SUPPORT/INVARIANT_SUPPORT/.
John Baldwin [Sat, 24 Feb 2001 21:29:32 +0000 (21:29 +0000)]
Grrr, s/INVARIANTS_SUPPORT/INVARIANT_SUPPORT/.

23 years ago- Axe RETIP() as it was very i386 specific and unwieldy. Instead, use the
John Baldwin [Sat, 24 Feb 2001 19:36:13 +0000 (19:36 +0000)]
- Axe RETIP() as it was very i386 specific and unwieldy.  Instead, use the
  passed in filename and line number in the KTR tracepoint message.
- Even though it is #if 0'd code, change the code to detect that a process
  is an interrupt thread to check p->p_ithd against NULL rather than
  checking non-existant process flags from BSD/OS.
- Use '%p' to print pointers in KTR log messages instead of assuming
  sizeof(int) == sizeof(void *).
- Don't set p_mtxname to NULL when releasing a mutex.  It doesn't hurt
  to leave it set (we don't clear w_mesg for example) and at least at
  one time in the past, there used to be race conditions in the kernel
  that would result in setting this to NULL causing the kernel to
  dereference NULL.
- Make the _mtx_assert() function be compiled in if INVARIANTS_SUPPORT is
  defined rather than if INVARIANTS is defined so that a KLD compiled
  with INVARIANTS that uses mtx_assert() can be used with a kernel that
  just has INVARIANT_SUPPORT compiled in.

23 years agoIn the SCSI_NO_SENSE_STRINGS case, properly fill the table with the
Justin T. Gibbs [Sat, 24 Feb 2001 19:24:36 +0000 (19:24 +0000)]
In the SCSI_NO_SENSE_STRINGS case, properly fill the table with the
asc and ascq pair rather than asc, asc.

PR: 25291
Submitted by: Stephen Ferrari <sferrari@yahoo.com>

23 years agosched_swi -> swi_sched
John Baldwin [Sat, 24 Feb 2001 19:09:37 +0000 (19:09 +0000)]
sched_swi -> swi_sched

23 years agoDon't include machine/mutex.h and relocate sys/mutex.h's include to be
John Baldwin [Sat, 24 Feb 2001 19:09:16 +0000 (19:09 +0000)]
Don't include machine/mutex.h and relocate sys/mutex.h's include to be
closer to alphabetical order and identical to that of the alpha.

23 years agoAdd back in INVARIANT_SUPPORT and expand the comments in NOTES about it
John Baldwin [Sat, 24 Feb 2001 19:03:18 +0000 (19:03 +0000)]
Add back in INVARIANT_SUPPORT and expand the comments in NOTES about it
to include the reasoning Eivind justifiably thwapped me over the head with.

23 years agoClockframes have a trapframe stored in a cf_tf member, not ct_tf.
John Baldwin [Sat, 24 Feb 2001 18:57:34 +0000 (18:57 +0000)]
Clockframes have a trapframe stored in a cf_tf member, not ct_tf.

23 years agoProperly orient the buttons for yes/no and no/yes so that POLA is
Jordan K. Hubbard [Sat, 24 Feb 2001 18:52:56 +0000 (18:52 +0000)]
Properly orient the buttons for yes/no and no/yes so that POLA is
observed.  This fixes the "no/yes box jumps buttons around" problem.

PR: gnu/24487
Submitted by: Gerhard Sittig <Gerhard.Sittig@gmx.net>

23 years agoWhitespace nits.
John Baldwin [Sat, 24 Feb 2001 18:41:38 +0000 (18:41 +0000)]
Whitespace nits.

23 years agoPass in process to mark ast on to aston().
John Baldwin [Sat, 24 Feb 2001 18:41:17 +0000 (18:41 +0000)]
Pass in process to mark ast on to aston().

23 years agoMake md/mdconfig do kld.
Poul-Henning Kamp [Sat, 24 Feb 2001 16:26:41 +0000 (16:26 +0000)]
Make md/mdconfig do kld.

Submitted by: dcs

23 years agoIntroduce API for sequential reads/writes (build/dissect) of mbuf chains.
Boris Popov [Sat, 24 Feb 2001 15:44:30 +0000 (15:44 +0000)]
Introduce API for sequential reads/writes (build/dissect) of mbuf chains.

Reviewed by: Ian Dowse <iedowse@maths.tcd.ie>,
Bosko Milekic <bmilekic@technokratis.com>,
Julian Elischer <julian@elischer.org> and arch@/net@
Obtained from: smbfs

23 years agoAdd knowledge of the netgraph spinlocks into the Witness code.
Julian Elischer [Sat, 24 Feb 2001 14:29:47 +0000 (14:29 +0000)]
Add knowledge of the netgraph spinlocks into the Witness code.
Well, at least I think that's how it's done.

23 years agoAdd two missed modifiers into usage message (`-G' and `-x').
Maxim Sobolev [Sat, 24 Feb 2001 14:10:31 +0000 (14:10 +0000)]
Add two missed modifiers into usage message (`-G' and `-x').

23 years ago- Assert that the proc to return is not NULL in runq_choose the
Jake Burkholder [Sat, 24 Feb 2001 14:06:36 +0000 (14:06 +0000)]
- Assert that the proc to return is not NULL in runq_choose the
  same as runq_remove.
- bzero the whole struct runq in runq_init just in case its not
  statically allocated.

23 years agoFix visibility of empty variable -- it should be static.
Alexey Zelkin [Sat, 24 Feb 2001 13:13:48 +0000 (13:13 +0000)]
Fix visibility of empty variable -- it should be static.

Submitted by: bde and Hartmut Brandt <brandt@fokus.gmd.de> (via PR)
PR: bin/25308

23 years agoBump FreeBSD version to correspond to addition of CPUTYPE make variable.
Kris Kennaway [Sat, 24 Feb 2001 10:44:03 +0000 (10:44 +0000)]
Bump FreeBSD version to correspond to addition of CPUTYPE make variable.

23 years agomdoc(7) police: restore correct order of references in the SEE ALSO.
Ruslan Ermilov [Sat, 24 Feb 2001 10:30:27 +0000 (10:30 +0000)]
mdoc(7) police: restore correct order of references in the SEE ALSO.

23 years agoRestrict -a to root only.
Ruslan Ermilov [Sat, 24 Feb 2001 10:16:54 +0000 (10:16 +0000)]
Restrict -a to root only.

PR: bin/25337

23 years agoIt turns out the kernel console works fine and thus doesn't need quite this
John Baldwin [Sat, 24 Feb 2001 03:40:23 +0000 (03:40 +0000)]
It turns out the kernel console works fine and thus doesn't need quite this
much extra testing.

23 years agoI thought it was a new CPU :)
Seigo Tanimura [Sat, 24 Feb 2001 02:59:32 +0000 (02:59 +0000)]
I thought it was a new CPU :)

s/i585/i586/

23 years agotry hard to make sure this does not get build as a shared library
Assar Westerlund [Sat, 24 Feb 2001 02:10:32 +0000 (02:10 +0000)]
try hard to make sure this does not get build as a shared library

23 years agoAdd an EV_SET() convenience macro for initializing struct kevent prior
Jonathan Lemon [Sat, 24 Feb 2001 01:44:03 +0000 (01:44 +0000)]
Add an EV_SET() convenience macro for initializing struct kevent prior
to the call to kevent().

Update the copyright notices as well.

23 years agoIntroduce a NOTE_LOWAT flag for use with the read/write filters, which
Jonathan Lemon [Sat, 24 Feb 2001 01:41:31 +0000 (01:41 +0000)]
Introduce a NOTE_LOWAT flag for use with the read/write filters, which
allow the watermark to be passed in via the data field during the EV_ADD
operation.

Hook this up to the socket read/write filters; if specified, it overrides
the so_{rcv|snd}.sb_lowat values in the filter.

Inspired by: "Ronald F. Guilmette" <rfg@monkeys.com>

23 years agoWhen returning EV_EOF for the socket read/write filters, also return
Jonathan Lemon [Sat, 24 Feb 2001 01:33:12 +0000 (01:33 +0000)]
When returning EV_EOF for the socket read/write filters, also return
the current socket error in fflags.  This may be useful for determining
why a connect() request fails.

Inspired by:  "Jonathan Graehl" <jonathan@graehl.org>

23 years agoForce TERM to be dumb when building termcap. ex in batch mode seems
Warner Losh [Sat, 24 Feb 2001 00:02:55 +0000 (00:02 +0000)]
Force TERM to be dumb when building termcap.  ex in batch mode seems
to care about the terminal setting.  In emacs, make buildworld was
broken because it sets TERM to emacs, which caused ex to fail.

23 years agoStricter style(9) conformance - remove unnecessary blank lines in previous
Peter Wemm [Fri, 23 Feb 2001 23:05:46 +0000 (23:05 +0000)]
Stricter style(9) conformance - remove unnecessary blank lines in previous
commit.

23 years agoCorrect CS20 section.
Wilko Bulte [Fri, 23 Feb 2001 22:08:35 +0000 (22:08 +0000)]
Correct CS20 section.

Reviewed by: Peter Petrakis <peter.petrakis@api-networks.com>

23 years agoispell-ify..
Wilko Bulte [Fri, 23 Feb 2001 21:47:30 +0000 (21:47 +0000)]
ispell-ify..

23 years agoWhen converting soft error into a hard error, drop the connection. The
Jonathan Lemon [Fri, 23 Feb 2001 21:07:06 +0000 (21:07 +0000)]
When converting soft error into a hard error, drop the connection.  The
error will be passed up to the user, who will close the connection, so
it does not appear to make a sense to leave the connection open.

This also fixes a bug with kqueue, where the filter does not set EOF
on the connection, because the connection is still open.

Also remove calls to so{rw}wakeup, as we aren't doing anything with
them at the moment anyway.

Reviewed by: alfred, jesper

23 years agoAllow ICMP unreachables which map into PRC_UNREACH_ADMIN_PROHIB to
Jonathan Lemon [Fri, 23 Feb 2001 20:51:46 +0000 (20:51 +0000)]
Allow ICMP unreachables which map into PRC_UNREACH_ADMIN_PROHIB to
reset TCP connections which are in the SYN_SENT state, if the sequence
number in the echoed ICMP reply is correct.  This behavior can be
controlled by the sysctl net.inet.tcp.icmp_may_rst.

Currently, only subtypes 2,3,10,11,12 are treated as such
(port, protocol and administrative unreachables).

Assocaiate an error code with these resets which is reported to the
user application: ENETRESET.

Disallow resetting TCP sessions which are not in a SYN_SENT state.

Reviewed by: jesper, -net

23 years agoFix typo in comment (knode -> knote).
Jonathan Lemon [Fri, 23 Feb 2001 20:32:42 +0000 (20:32 +0000)]
Fix typo in comment (knode -> knote).

23 years agoAdd a NOTE_REVOKE flag for vnodes, which is triggered from within vclean().
Jonathan Lemon [Fri, 23 Feb 2001 20:06:01 +0000 (20:06 +0000)]
Add a NOTE_REVOKE flag for vnodes, which is triggered from within vclean().
Use this to tell a filter attached to a vnode that the underlying vnode is
no longer valid, by returning EV_EOF.

PR: kern/25309, kern/25206

23 years agoFix typo that was causing a compiler warning.
Bill Paul [Fri, 23 Feb 2001 20:04:20 +0000 (20:04 +0000)]
Fix typo that was causing a compiler warning.

Submitted by: Alfred Perlstein

23 years agoTest out the kernel console just before launching the AP's.
John Baldwin [Fri, 23 Feb 2001 19:44:25 +0000 (19:44 +0000)]
Test out the kernel console just before launching the AP's.

23 years agoUse correct list pointer when detaching knote from list.
Jonathan Lemon [Fri, 23 Feb 2001 19:20:21 +0000 (19:20 +0000)]
Use correct list pointer when detaching knote from list.

23 years agoRemove directive to install top as group kmem. Remove directive to
Robert Watson [Fri, 23 Feb 2001 18:55:43 +0000 (18:55 +0000)]
Remove directive to install top as group kmem.  Remove directive to
install top with setgid bit.

23 years agoAdapt the top utility to not use kmem_read to retrieve variables now
Robert Watson [Fri, 23 Feb 2001 18:52:37 +0000 (18:52 +0000)]
Adapt the top utility to not use kmem_read to retrieve variables now
available via sysctl().  As a result, top should now be able to run without
setgid kmem.

Submitted by: Thomas Moestl <tmoestl@gmx.net>
Reviewed by: freebsd-audit

23 years agoAdapt libkvm_getswapinfo() to make use of recently committed vm and swap
Robert Watson [Fri, 23 Feb 2001 18:49:16 +0000 (18:49 +0000)]
Adapt libkvm_getswapinfo() to make use of recently committed vm and swap
sysctls exporting swap information.  When running on a live kernel,
the sysctl's will now be used instead of kvm_read, allowing consumers of
this interface to run without privilege (setgid kmem).  Retain the
ability to run on coredumps, or on a kernel using kmem if explicitly
pointed at one.

A side effect of this change is that kvm_getswapinfo() is faster now in
the general case. If the SWIF_DUMP_TREE flag is given (pstat -ss does
this), the radix tree walker, which still uses kvm_read in any case, is
invoked, and therefore does require privilege.

Submitted by: Thomas Moestl <tmoestl@gmx.net>
Reviewed by: freebsd-audit

23 years agoIntroduce per-swap area accounting in the VM system, and export
Robert Watson [Fri, 23 Feb 2001 18:46:21 +0000 (18:46 +0000)]
Introduce per-swap area accounting in the VM system, and export
this information via the vm.nswapdev sysctl (number of swap areas)
and vm.swapdevX nodes (where X is the device), which contain the MIBs
dev, blocks, used, and flags.  These changes are required to allow
top and other userland swap-monitoring utilities to run without
setgid kmem.

Submitted by: Thomas Moestl <tmoestl@gmx.net>
Reviewed by: freebsd-audit

23 years agoFix release. Just as in other kerberos5 libraries, we need to include
John Baldwin [Fri, 23 Feb 2001 18:31:26 +0000 (18:31 +0000)]
Fix release.  Just as in other kerberos5 libraries, we need to include
${.OBJDIR} in the includes list and generate a couple of headers from their
.et sources for beforedepend and all.

23 years agoCorrectly handle the race itself, too (don't leave it locked).
Brian Feldman [Fri, 23 Feb 2001 17:55:01 +0000 (17:55 +0000)]
Correctly handle the race itself, too (don't leave it locked).
This is about to be replaced anyway by initialization explicitly
instead of lazily, and reducing the complexity of it.  As it is
now, this will work fine, however.

23 years agoShuffle sysctls a bit (thankyou whoever made them dynamic for modules)
Julian Elischer [Fri, 23 Feb 2001 16:34:22 +0000 (16:34 +0000)]
Shuffle sysctls a bit (thankyou whoever made them dynamic for modules)
and add a sysctl to pppoe to activate non standard ethertypes
so that idiot ISPs (apparently in France) who use
equipment from idiot suppliers (rumour says 3com)
who use nonstandard ethertypes can still connect.

 "yep, sure we do pppoe, we use a different identifier to that dictated in
 the standard, but sure it's pppoe!"

sysctl -w net.graph.stupid_isp=1 enables the changeover.

23 years agoImplement the following options and primaries:
Akinori MUSHA [Fri, 23 Feb 2001 16:20:55 +0000 (16:20 +0000)]
Implement the following options and primaries:

     -E      Interpret regular expressions followed by -regex and -iregex op-
             tions as extended (modern) regular expressions rather than basic
             regular expressions (BRE's).  The re_format(7) manual page fully
             describes both formats.

     -iname pattern
             Like -name, but the match is case insensitive.

     -ipath pattern
             Like -path, but the match is case insensitive.

     -regex pattern
             True if the whole path of the file matches pattern using regular
             expression.  To match a file named ``./foo/xyzzy'', you can use
             the regular expression ``.*/[xyz]*'' or ``.*/foo/.*'', but not
             ``xyzzy'' or ``/foo/''.

     -iregex pattern
             Like -regex, but the match is case insensitive.

These are meant to be compatible with other find(1) implementations
such as GNU's or NetBSD's except regexp library differences.

Reviewed by: sobomax, dcs, and some other people on -current

23 years agoMake ``groff -man'' work again for both man(7) and mdoc(7) manpages.
Ruslan Ermilov [Fri, 23 Feb 2001 09:35:33 +0000 (09:35 +0000)]
Make ``groff -man'' work again for both man(7) and mdoc(7) manpages.
The new Groff release will support this feature.

Requested by: peter

23 years agoFree lock before calling panic so that subsequent attempt to write out
Kirk McKusick [Fri, 23 Feb 2001 09:01:31 +0000 (09:01 +0000)]
Free lock before calling panic so that subsequent attempt to write out
buffers does not re-panic with `locking against myself'. This change
should not affect normal operations of soft updates in any way.

23 years agoAdditional enhancments to allow IBM Etherjet cards to be probed,
Warner Losh [Fri, 23 Feb 2001 08:08:21 +0000 (08:08 +0000)]
Additional enhancments to allow IBM Etherjet cards to be probed,
attached and ifconfigable.  The card doesn't interrupt yet.

Also, move towards bus space by introducing new macros/inline
functions which make such a move much easier than before.

These inline functions are setup now to work around an IBM EtherJet
pccard cardbus bridge incompatibility.  The card works in 8 bit mode,
but not in 16-bit mode when it is connected to a cardbus bridge for
reasons unknown.  The Linux driver also has a similar workaround in
it.

Future work will include making the above workaround runtime
conditional rather than compile time conditional, as well as fixing
the interrupts in pccards and converting it to bus space.

23 years agoUse the right names to call pthread_mutex_{,un}lock so that things
Brian Feldman [Fri, 23 Feb 2001 06:26:22 +0000 (06:26 +0000)]
Use the right names to call pthread_mutex_{,un}lock so that things
work in both the libc only and libc/libc_r case.

23 years agoFix a longstanding bug- we had the sense of what bit 14
Matt Jacob [Fri, 23 Feb 2001 05:35:50 +0000 (05:35 +0000)]
Fix a longstanding bug- we had the sense of what bit 14
for the ICB firmware options meant- *I* had taken it to
mean that if you set it, Node Name would be ignored and
derived from Port Name. Actually, it meant the opposite.
As a consequence- change ICBOPT_USE_PORTNAME to the
define ICBOPT_BOTH_WWNS- makes more sense.

Fix wrong input bitmap for MBOX_DUMP_RAM command. Call
ISP_DUMPREGS if we get a f/w crash. Add ISPCTL_RUN_MBOXCMD
control command (so outer layers can run a mailbox command
directly) and add a ISPASYNC_UNHANDLED_RESPONSE hook so
outer layers can understand response queue entries we
might not know about.

23 years agoFix the problems I (and others, undoubtedly) have been having for a
Brian Feldman [Fri, 23 Feb 2001 04:59:12 +0000 (04:59 +0000)]
Fix the problems I (and others, undoubtedly) have been having for a
while with threaded software in -CURRENT acting very "weird".  It has
seemed, for example, in Mozilla that threads attempting to do host
lookups have been locking up.  That's exactly the case.

There was a race condition in the implementation of the initialization
of the mutex used to protect FILE operations, first of all: multiple
instances of FLOCKFILE() in libc could occur on the same FILE at
the same time and cause strange behavior by overwriting eachothers'
creation of the mutex and the rest of the file lock.

Secondly, it's not appropriate to test the "validity" of the file
descriptor referenced by the FILE; if the code is calling FLOCKFILE()
or FUNLOCKFILE(), it wants the FILE to be locked or unlocked, not
to be locked or unlocked on the condition that _file is >= 0.  This
also could quite easily cause leaks by failing to perform the lock or
unlock operation when it actually is needed.

Mozilla now works again on -CURRENT when linked to libc_r.so.5 and
libc.so.5.

23 years agoFlip the default for CVS_RSH to "ssh". I am tired of getting asked this
Peter Wemm [Fri, 23 Feb 2001 04:52:30 +0000 (04:52 +0000)]
Flip the default for CVS_RSH to "ssh".  I am tired of getting asked this
all the time, and IMHO it is long overdue.

23 years agoIf the symbolic links @ or machine exist, do not depend on them.
Warner Losh [Fri, 23 Feb 2001 04:49:31 +0000 (04:49 +0000)]
If the symbolic links @ or machine exist, do not depend on them.

This fixes the problem where if src/sys or src/sys/$MACHINE_ARCH/include
changed at all, all the modules would be rebuilt.

Reviewed by: bde

23 years agoDisplay the Joliet Extension 'level' in the log message.
Alfred Perlstein [Fri, 23 Feb 2001 03:43:05 +0000 (03:43 +0000)]
Display the Joliet Extension 'level' in the log message.

PR: kern/24998

23 years agoRemove the camcontrol rescan $device insert events for the aic driver,
Peter Wemm [Fri, 23 Feb 2001 02:45:15 +0000 (02:45 +0000)]
Remove the camcontrol rescan $device insert events for the aic driver,
which does it itself now.  Although CAM should do the rescan itself
if the initial boot-time rescan has already been done.

23 years agoSigh, nobody ever got back to me about this. So, here it is..
Peter Wemm [Fri, 23 Feb 2001 02:32:31 +0000 (02:32 +0000)]
Sigh, nobody ever got back to me about this.  So, here it is..
Implement auto scsi scan at insert time for the aic driver.

23 years agoActivate USER_LDT by default. The new thread libraries are going to
Peter Wemm [Fri, 23 Feb 2001 01:25:02 +0000 (01:25 +0000)]
Activate USER_LDT by default.  The new thread libraries are going to
depend on this.  The linux ABI emulator tries to use it for some linux
binaries too.  VM86 had a bigger cost than this and it was made default
a while ago.

Reviewed by: jhb, imp

23 years agoTypo: "interrupt" -> "harvest_interrupt"
Brian Feldman [Fri, 23 Feb 2001 01:12:44 +0000 (01:12 +0000)]
Typo: "interrupt" -> "harvest_interrupt"

23 years agoRemove undefined and unreferenced doreti_syscall_ret globl. While I'm
John Baldwin [Fri, 23 Feb 2001 00:41:05 +0000 (00:41 +0000)]
Remove undefined and unreferenced doreti_syscall_ret globl.  While I'm
here, adjust comment block above doreti.  We don't have the old MP lock
anymore.

23 years agoMove the 'dont forget "make depend"' to be the last thing that people see,
Peter Wemm [Fri, 23 Feb 2001 00:22:04 +0000 (00:22 +0000)]
Move the 'dont forget "make depend"' to be the last thing that people see,
after the warnings.

23 years agoChange the 120 second timeout to 180 seconds to reflect the real default
Brian Somers [Thu, 22 Feb 2001 23:28:12 +0000 (23:28 +0000)]
Change the 120 second timeout to 180 seconds to reflect the real default

23 years agoMACHINE_ARCH is the target arch to crossbuild to, not TARGET_ARCH.
John Baldwin [Thu, 22 Feb 2001 22:58:24 +0000 (22:58 +0000)]
MACHINE_ARCH is the target arch to crossbuild to, not TARGET_ARCH.

Requested by: marcel

23 years agoElminate common declaration.
Paul Saab [Thu, 22 Feb 2001 21:53:39 +0000 (21:53 +0000)]
Elminate common declaration.

Reviewed by: peter

23 years agoRedo the security update done in rev 1.54 of src/sys/netinet/tcp_subr.c
Jesper Skriver [Thu, 22 Feb 2001 21:23:45 +0000 (21:23 +0000)]
Redo the security update done in rev 1.54 of src/sys/netinet/tcp_subr.c
and 1.84 of src/sys/netinet/udp_usrreq.c

The changes broken down:

- remove 0 as a wildcard for addresses and port numbers in
  src/sys/netinet/in_pcb.c:in_pcbnotify()
- add src/sys/netinet/in_pcb.c:in_pcbnotifyall() used to notify
  all sessions with the specific remote address.
- change
  - src/sys/netinet/udp_usrreq.c:udp_ctlinput()
  - src/sys/netinet/tcp_subr.c:tcp_ctlinput()
  to use in_pcbnotifyall() to notify multiple sessions, instead of
  using in_pcbnotify() with 0 as src address and as port numbers.
- remove check for src port == 0 in
  - src/sys/netinet/tcp_subr.c:tcp_ctlinput()
  - src/sys/netinet/udp_usrreq.c:udp_ctlinput()
  as they are no longer needed.
- move handling of redirects and host dead from in_pcbnotify() to
  udp_ctlinput() and tcp_ctlinput(), so they will call
  in_pcbnotifyall() to notify all sessions with the specific
  remote address.

Approved by: jlemon
Inspired by:    NetBSD

23 years agoStreamline updating of switchtime (don't copy code from kern_sync.c).
Tor Egge [Thu, 22 Feb 2001 20:16:51 +0000 (20:16 +0000)]
Streamline updating of switchtime (don't copy code from kern_sync.c).

Submitted by: jhb

23 years agoBackout previous commit. sched_lock is held, thus interrupts are prevented
Tor Egge [Thu, 22 Feb 2001 20:12:52 +0000 (20:12 +0000)]
Backout previous commit.  sched_lock is held, thus interrupts are prevented
here.

Submitted by: jhb

23 years agoProtect update of the per processor switchtime variable against
Tor Egge [Thu, 22 Feb 2001 19:50:37 +0000 (19:50 +0000)]
Protect update of the per processor switchtime variable against
interrupts.

Protect usage of the per processor switchtime variable against
interrupts in calcru().

This seem to eliminate the "microuptime() went backwards" warnings.

23 years agoNeed one additional make.conf knob, SENDMAIL_ADDITIONAL_MC to satisfy bug
Gregory Neil Shapiro [Thu, 22 Feb 2001 19:44:16 +0000 (19:44 +0000)]
Need one additional make.conf knob, SENDMAIL_ADDITIONAL_MC to satisfy bug
report.  It allows building multiple .cf files at build time.

PR: bin/19897

23 years agoThe p_md.md_regs member of proc is used in signal handling to reference
John Baldwin [Thu, 22 Feb 2001 19:35:20 +0000 (19:35 +0000)]
The p_md.md_regs member of proc is used in signal handling to reference
the the original trapframe of the syscall, trap, or interrupt that entered
the kernel.  Before SMPng, ast's were handled via a psuedo trap at the
end of doerti.  With the SMPng commit, ast's were broken out into a
separate ast() function that was called from doreti to match the behavior
of other architectures.  Unfortunately, when this was done, the
p_md.md_regs member of curproc was not updateda in ast(), thus when
signals are handled by userret() after an interrupt that returns to
userland, we end up using a stale trapframe that will result in the
registers from the old trapframe overwriting the real trapframe and
smashing all the registers right before we return to usermode.  The saved
%cs:%eip from where we were in usermode are saved in the trapframe for
example.

23 years agoAdd a note indicating that SENDMAIL_MC should include the path. This is
Gregory Neil Shapiro [Thu, 22 Feb 2001 19:34:13 +0000 (19:34 +0000)]
Add a note indicating that SENDMAIL_MC should include the path.  This is
necessary if you expect to be able to use this setting in both /etc/mail
and etc/sendmail.

23 years agoApply patch to allow TX underrun handling without issuing a complete
Bill Paul [Thu, 22 Feb 2001 19:26:55 +0000 (19:26 +0000)]
Apply patch to allow TX underrun handling without issuing a complete
chip reset. Just temporarily turn off the transmitter instead.

Submitted by: Stephen McKay <mckay@freebsd.org>

23 years agosome reasoning why we separated ping(8) and ping6(8)
Hajimu UMEMOTO [Thu, 22 Feb 2001 19:00:51 +0000 (19:00 +0000)]
some reasoning why we separated ping(8) and ping6(8)
comments/additions/corrections are welcome.

Obtained from: KAME

23 years agoSince the PC is a pointer to a code address, change the second parameter of
John Baldwin [Thu, 22 Feb 2001 18:07:31 +0000 (18:07 +0000)]
Since the PC is a pointer to a code address, change the second parameter of
addupc_task() and addupc_intr() to be a uintptr_t instead of a u_long.

23 years ago- Change ast() to take a pointer to a trapframe like other architectures.
John Baldwin [Thu, 22 Feb 2001 18:05:15 +0000 (18:05 +0000)]
- Change ast() to take a pointer to a trapframe like other architectures.
- Don't use an atomic operation to update cnt.v_soft in ast().  This is
  the only place the variable is written to, and sched_lock is always
  held when it is written, so it is already protected and the mutex release
  of sched_lock asserts a memory barrier that ensures the value will be
  updated in a timely fashion.

23 years agoReturn to the code as distributed by sendmail.org. This eliminates a
Gregory Neil Shapiro [Thu, 22 Feb 2001 17:47:24 +0000 (17:47 +0000)]
Return to the code as distributed by sendmail.org.  This eliminates a
warning on Alphas.  It is still not the perfect solution for machines
which sizeof(u_long) != sizeof(void *) but it is as close as we are going
to get for now and consistent with the rest of the code.  8.12 has solved
this problem by providing a portable snprintf() which understands %p.

PR: bin/14142

23 years agoAdd a 'splitter' node to separate a bidirectional
Julian Elischer [Thu, 22 Feb 2001 17:14:36 +0000 (17:14 +0000)]
Add a 'splitter' node to separate a bidirectional
packet flow into two unidirectional flows.

Part of a suite of nodes developed for packet flow control.
More to follow as I have time to port them to 5.x or
as others do so. The ipfw node will be the hardest..

Submitted by: "Vitaly V. Belekhov" <vitaly@riss-telecom.ru>

23 years agoThe ia64 hasn't needed machine/ipl.h included in sys/systm.h for a while
John Baldwin [Thu, 22 Feb 2001 17:14:24 +0000 (17:14 +0000)]
The ia64 hasn't needed machine/ipl.h included in sys/systm.h for a while
now.

23 years agoAxe pcb_schednest as it is no longer used.
John Baldwin [Thu, 22 Feb 2001 17:09:50 +0000 (17:09 +0000)]
Axe pcb_schednest as it is no longer used.

23 years agoRename switch_trampoline() to fork_trampoline() on the alpha and ia64.
John Baldwin [Thu, 22 Feb 2001 16:56:53 +0000 (16:56 +0000)]
Rename switch_trampoline() to fork_trampoline() on the alpha and ia64.

Suggested by: dfr

23 years agoDon't set the sched_lock lesting level for new processes as it is no
John Baldwin [Thu, 22 Feb 2001 16:53:23 +0000 (16:53 +0000)]
Don't set the sched_lock lesting level for new processes as it is no
longer used.

23 years agoCatch comments up to child_return() -> fork_return() as well.
John Baldwin [Thu, 22 Feb 2001 16:49:36 +0000 (16:49 +0000)]
Catch comments up to child_return() -> fork_return() as well.

23 years agoSynch up with the other architectures:
John Baldwin [Thu, 22 Feb 2001 16:27:03 +0000 (16:27 +0000)]
Synch up with the other architectures:
- Remove unneeded spl()'s around mi_switch() in userret().
- Don't hold sched_lock across addupc_task().
- Remove the MD function child_return() now that the MI function
  fork_return() is used instead.
- Use TRAPF_USERMODE() instead of dinking with the trapframe directly to
  check for ast's in kernel mode.
- Check astpending(curproc) and resched_wanted() in ast() and return if
  neither is true.
- Use astoff() rather than setting the non-existent per-cpu variable
  astpending to 0 to clear an ast.

23 years ago- Use TRAPF_PC() on the alpha to acess the PC in the trap frame.
John Baldwin [Thu, 22 Feb 2001 16:23:12 +0000 (16:23 +0000)]
- Use TRAPF_PC() on the alpha to acess the PC in the trap frame.
- Don't hold sched_lock around addupc_task() as this apparently breaks
  profiling badly due to sched_lock being held across copyin().

Reported by: bde (2)

23 years agoUse the MI fork_return() fork trampoline callout function for child
John Baldwin [Thu, 22 Feb 2001 16:05:48 +0000 (16:05 +0000)]
Use the MI fork_return() fork trampoline callout function for child
processes instead of the MD child_return().

23 years ago- Don't dink with sched_lock in cpu_switch() since mi_switch() does this
John Baldwin [Thu, 22 Feb 2001 16:05:09 +0000 (16:05 +0000)]
- Don't dink with sched_lock in cpu_switch() since mi_switch() does this
  for us.
- Change the switch_trampoline() to call fork_exit() passing in the
  required arguments instead of calling the fork trampoline callout
  function directly.
Warning: this hasn't been tested.

Looked over by: dfr

23 years agoGC unused and now obsolete assertion macros.
John Baldwin [Thu, 22 Feb 2001 15:45:49 +0000 (15:45 +0000)]
GC unused and now obsolete assertion macros.

23 years ago- Axe the now unused ASS_* assertions for interrupt status.
John Baldwin [Thu, 22 Feb 2001 15:43:42 +0000 (15:43 +0000)]
- Axe the now unused ASS_* assertions for interrupt status.
- Use ia64_get_psr() instead of save_intr() in mtx_legal2block().

23 years agoAdd a inline function to read the psr.
John Baldwin [Thu, 22 Feb 2001 15:39:58 +0000 (15:39 +0000)]
Add a inline function to read the psr.

23 years agoAdd a mtx_intr_enable() macro.
John Baldwin [Thu, 22 Feb 2001 15:37:57 +0000 (15:37 +0000)]
Add a mtx_intr_enable() macro.

23 years agoAxe the astpending per-cpu variable.
John Baldwin [Thu, 22 Feb 2001 15:37:34 +0000 (15:37 +0000)]
Axe the astpending per-cpu variable.

23 years agoAdd TRAPF_PC() and TRAPF_USERMODE() macros and redefine CLKF_PC() and
John Baldwin [Thu, 22 Feb 2001 15:35:04 +0000 (15:35 +0000)]
Add TRAPF_PC() and TRAPF_USERMODE() macros and redefine CLKF_PC() and
CLKF_USERMODE() in terms of them.

23 years agoOnly descend into ${MACHINE_ARCH} subdir.
Ruslan Ermilov [Thu, 22 Feb 2001 15:28:57 +0000 (15:28 +0000)]
Only descend into ${MACHINE_ARCH} subdir.

23 years agoCleanup and clarify the comments above switch_trampoline().
John Baldwin [Thu, 22 Feb 2001 15:06:19 +0000 (15:06 +0000)]
Cleanup and clarify the comments above switch_trampoline().

23 years agoPrepare for mdoc(7)NG.
Ruslan Ermilov [Thu, 22 Feb 2001 15:03:09 +0000 (15:03 +0000)]
Prepare for mdoc(7)NG.

23 years agoFix formatting bugs introduced in sysctl_vm_zone() by the previous commit.
Dag-Erling Smørgrav [Thu, 22 Feb 2001 14:44:39 +0000 (14:44 +0000)]
Fix formatting bugs introduced in sysctl_vm_zone() by the previous commit.
Also, if SYSCTL_OUT() returns a non-zero value, stop at once.

23 years agofix usage statement (add missing [-n devs] option)
Alfred Perlstein [Thu, 22 Feb 2001 13:55:12 +0000 (13:55 +0000)]
fix usage statement (add missing [-n devs] option)

Submitted by: Maxim Konovalov <maxim@macomnet.ru>

Silence a warning by renaming the 'pgtok' #define to 'vmstat_pgtok' so
as not to conflict with the 'pgtok' #define in sys/param.h

23 years agoAdd a mtx_assert() in maybe_resched() just to be sure it's always called
John Baldwin [Thu, 22 Feb 2001 13:47:01 +0000 (13:47 +0000)]
Add a mtx_assert() in maybe_resched() just to be sure it's always called
with sched_lock held.

23 years agoLock need_resched with sched_lock.
John Baldwin [Thu, 22 Feb 2001 13:46:09 +0000 (13:46 +0000)]
Lock need_resched with sched_lock.

Reported by: des