]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
23 years ago- Various style fixes.
jhb [Thu, 29 Mar 2001 18:10:46 +0000 (18:10 +0000)]
- Various style fixes.
- Fix a silly bug so that we return the actual error code if a procfs
  attach fails rather than always returning 0.

Reported by: bde

23 years agoNew release notes: New CAM error recovery code, PAM support for
bmah [Thu, 29 Mar 2001 17:11:58 +0000 (17:11 +0000)]
New release notes:  New CAM error recovery code, PAM support for
account management and session, tail(1) support for large files.

Updates:  vn(4) removed, file(1) update to 3.34.

23 years ago- Added suspend/resume support.
orion [Thu, 29 Mar 2001 15:36:31 +0000 (15:36 +0000)]
- Added suspend/resume support.

- Added 4 speaker enable to initialization sequence.

- Removed delays between register pokes which appear to aggravate a
  problem this card has sampling at 44.1kHz.  With any form of delay,
  skew relative to system clock at 44.1kHz is usually in range 0-25%
  (now 0-3%).  No other rates exhibit this problem.

- Changed structs cmi_* to sc_*.

Approved by:    Cameron Grant <gandalf@vilnya.demon.co.uk>

23 years agofix a number of printf format string warnings inside DEBUG ifdefs
gallatin [Thu, 29 Mar 2001 15:05:08 +0000 (15:05 +0000)]
fix a number of printf format string warnings inside DEBUG ifdefs

23 years agoChange NO_MAKEDEV to a finer granularity method:
asmodai [Thu, 29 Mar 2001 14:04:19 +0000 (14:04 +0000)]
Change NO_MAKEDEV to a finer granularity method:
NO_MAKEDEV_INSTALL and NO_MAKEDEV_RUN.  The former implying the latter.
The names imply what they do.  The last commit by DES based on a PR defeated
the original idea behind NO_MAKEDEV, which was not to run MAKEDEV, but to do
the installation of MAKEDEV.  This should satisfy both parties on the MAKEDEV
challenge.
Reflect this in mergemaster, this might later on be decided to be set to
NO_MAKEDEV_INSTALL, for now I kept to the old behaviour.

23 years agoChange NO_MAKEDEV to a finer granularity method:
asmodai [Thu, 29 Mar 2001 14:03:29 +0000 (14:03 +0000)]
Change NO_MAKEDEV to a finer granularity method:
NO_MAKEDEV_INSTALL and NO_MAKEDEV_RUN.  The former implying the latter.
The names imply what they do.  The last commit by DES based on a PR defeated
the original idea behind NO_MAKEDEV, which was not to run MAKEDEV, but to do
the installation of MAKEDEV.  This should satisfy both parties on the MAKEDEV
challenge.
Reflect this in the documentation.

23 years agoChange NO_MAKEDEV to a finer granularity method:
asmodai [Thu, 29 Mar 2001 14:03:07 +0000 (14:03 +0000)]
Change NO_MAKEDEV to a finer granularity method:
NO_MAKEDEV_INSTALL and NO_MAKEDEV_RUN.  The former implying the latter.
The names imply what they do.  The last commit by DES based on a PR defeated
the original idea behind NO_MAKEDEV, which was not to run MAKEDEV, but to do
the installation of MAKEDEV.  This should satisfy both parties on the MAKEDEV
challenge.

23 years agomdoc(7) police: LIBRARY should be before SYNOPSIS.
ru [Thu, 29 Mar 2001 13:03:23 +0000 (13:03 +0000)]
mdoc(7) police: LIBRARY should be before SYNOPSIS.

23 years agoKill vn related manual pages, they're not used any more.
ben [Thu, 29 Mar 2001 11:36:46 +0000 (11:36 +0000)]
Kill vn related manual pages, they're not used any more.

Approved by: phk

23 years agoFixed bitrot in the prototypes for NDINIT and NDFREE.
bde [Thu, 29 Mar 2001 10:29:37 +0000 (10:29 +0000)]
Fixed bitrot in the prototypes for NDINIT and NDFREE.

23 years agoFix building NEWCARD again, by including
jesper [Thu, 29 Mar 2001 10:23:45 +0000 (10:23 +0000)]
Fix building NEWCARD again, by including
sys/types.h and sys/lock.h in pccbb.c, as
jhb noted in rev 1.12 of src/share/man/man9/mutex.9

23 years agoFixed missing and disorded includes in synopsis.
bde [Thu, 29 Mar 2001 10:18:54 +0000 (10:18 +0000)]
Fixed missing and disorded includes in synopsis.

Removed bogus quotes in .Fn invocations.  Single words don't need quoting.

23 years agoFixed wrong include in synopsis. <sys/param.h> is a prerequisite for
bde [Thu, 29 Mar 2001 10:06:50 +0000 (10:06 +0000)]
Fixed wrong include in synopsis.  <sys/param.h> is a prerequisite for
<sys/mutex.h> due to #include spam in <sys/mutex.h>.  (More precisely,
<sys/time.h> is the prerequisite, but that is provided by standard
#include spam in <sys/param.h>.)

Fixed bitrot in prototype for mtx_init().

23 years agonumdirtybuffers is an int, not a long.
gallatin [Thu, 29 Mar 2001 02:18:19 +0000 (02:18 +0000)]
numdirtybuffers is an int, not a long.

23 years agoNote that the -v option is not supported. Don't remove the actual
dd [Thu, 29 Mar 2001 01:46:20 +0000 (01:46 +0000)]
Note that the -v option is not supported.  Don't remove the actual
text because the code is still in pstat.c, and may be reincarnated at
some point.

PR: 26054
Approved by: nik

23 years agoRemove a comment which seemed to confuse makewhatis:
ben [Thu, 29 Mar 2001 01:25:06 +0000 (01:25 +0000)]
Remove a comment which seemed to confuse makewhatis:

ben@freefall:~$ whatis ed
ed(1), -(1) - ed, red text editor

PR: 25164
Submitted by: Rich Morin <rdm@cfcl.com>

23 years agoCorrect the description of the "low" (< 1024) port range.
ben [Thu, 29 Mar 2001 01:00:42 +0000 (01:00 +0000)]
Correct the description of the "low" (< 1024) port range.

PR: 25500
Submitted by: Barry Irwin <bvi@devco.net>

23 years agoCorrect function name: acl_clear_perm -> acl_clear_perms
jedgar [Thu, 29 Mar 2001 00:48:54 +0000 (00:48 +0000)]
Correct function name: acl_clear_perm -> acl_clear_perms

23 years agoaic7770.c:
gibbs [Thu, 29 Mar 2001 00:36:35 +0000 (00:36 +0000)]
aic7770.c:
aic7xxx_pci.c:
Enable board generation of interrupts only once our handler is
in place and all other setup has occurred.

aic7xxx.c:
More conversion of data types to ahc_* names.  tmode_tstate and
tmode_lstate are the latest victims.

Clean up the check condition path by branching early rather
than indenting a giant block of code.

Add support for target mode initiated sync negotiation.
The code has been tested by forcing the feature on for
all devices, but for the moment is left inaccesible until
a decent mechanism for controlling the behavior is complete.
Implementing this feature required the removal of the
old "target message request" mechanism.  The old method
required setting one of the 16 bit fields to initiate
negotiation with a particular target.  This had the nice
effect of being easy to change the request and have it
effect the next command.  We now set the MK_MESSAGE bit
on any new command when negotiation is required.  When
the negotiation is successful, we walk through and clean
up the bit on any pending commands.  Since we have to walk
the commands to reset the SCSI syncrate values so no additional
work is required.  The only drawback of this approach is that
the negotiation is deferred until the next command is queued to
the controller.  On the plus side, we regain two bytes of
sequencer scratch ram and 6 sequencer instructions.

When cleaning up a target mode instance, never remove the
"master" target mode state object.  The master contains
all of the saved SEEPROM settings that control things like
transfer negotiations.  This data will be cloned as the
defaults if a target mode instance is re-instantiated.

Correct a bug in ahc_set_width().  We neglected to update
the pending scbs to reflect the new parameters.  Since
wide negotiation is almost always followed by sync
negotiation it is doubtful that this had any real
effect.

When in the target role, don't complain about
"Target Initiated" negotiation requests when an initiator
negotiates with us.

Defer enabling board interrupts until after ahc_intr_enable()
is called.

Pull all info that used to be in ahc_timeout for the FreeBSD
OSM into ahc_dump_card_state().  This info should be printed
out on all platforms.

aic7xxx.h:
Add the SCB_AUTO_NEGOITATE scb flag.  This allows us to
discern the reason the MK_MESSAGE flag is set in the hscb
control byte.  We only want to clear MK_MESSAGE in
ahc_update_pending_scbs() if the MK_MESSAGE was set due
to an auto transfer negotiation.

Add the auto_negotiate bitfield for each tstate so that
behavior can be controlled for each of our enabled SCSI
IDs.

Use a bus interrupt handler vector in our softc rather
than hard coding the PCI interrupt handler.  This makes
it easier to build the different bus attachments to
the aic7xxx driver as modules.

aic7xxx.reg:
Remove the TARGET_MSG_REQUEST definition for sequencer ram.

aic7xxx.seq:
Fix a few target mode bugs:

o If MK_MESSAGE is set in an SCB, transition to
  message in phase and notify the kernel so that
  message delivery can occur.  This is currently
  only used for target mode initiated transfer
  negotiation.

o Allow a continue target I/O to compile without
  executing a status phase or disconnecting.  If
  we have not been granted the disconnect privledge
  but this transfer is larger than MAXPHYS, it may
  take several CTIOs to get the job done.

Remove the tests of the TARGET_MSG_REQUEST field in scratch ram.

aic7xxx_freebsd.c:
Add support for CTIOs that don't disconnect.  We now defer
the clearing of our pending target state until we see a
CTIO for that device that has completed sucessfully.

Be sure to return early if we are in a target only role
and see an initiator only CCB type in our action routine.

If a CTIO has the CAM_DIS_DISCONNECT flag set, propogate
this flag to the SCB.  This flag has no effect if we've
been asked to deliver status as well.  We will complete
the command and release the bus in that case.

Handle the new auto_negotiate field in the tstate correctly.

Make sure that SCBs for "immediate" (i.e. to continue a non
disconnected transaction) CTIO requests get a proper mapping
in the SCB lookup table.  Without this, we'll complain when
the transaction completes.

Update ahc_timeout() to reflect the changes to ahc_dump_card_state().

aic7xxx_inline.h:
Use ahc->bus_intr rather than ahc_pci_intr.

23 years agoCatch up with a comment that changed in rev1.73 of mount.h
ben [Thu, 29 Mar 2001 00:29:00 +0000 (00:29 +0000)]
Catch up with a comment that changed in rev1.73 of mount.h

PR: 25836
Submitted by: Tony Finch <dot@dotat.at>

23 years agoWhoops, mention the Asante PCI 1000BASE-SX Gigabit Ethernet Adapter
wpaul [Thu, 29 Mar 2001 00:25:58 +0000 (00:25 +0000)]
Whoops, mention the Asante PCI 1000BASE-SX Gigabit Ethernet Adapter
(fiber version) too.

23 years agoMention that the Asante GigaNIX1000T Gigabit Ethernet Adapter is supported
wpaul [Thu, 29 Mar 2001 00:23:17 +0000 (00:23 +0000)]
Mention that the Asante GigaNIX1000T Gigabit Ethernet Adapter is supported
by the ti(4) driver. (Another OEM'ed Tigon 2.)

23 years agoFix some minor nits:
ben [Thu, 29 Mar 2001 00:12:01 +0000 (00:12 +0000)]
Fix some minor nits:
IEEE802.11 -> IEEE 802.11
(infrastructure) mode. -> (infrastructure mode).
place of ".".

PR: 25985
Submitted by: SUZUKI Koichi <metal@vc-net.ne.jp>

23 years agoRegenerate correctly.
peter [Thu, 29 Mar 2001 00:06:16 +0000 (00:06 +0000)]
Regenerate correctly.

23 years agoHint: usbdevs_data.h and usbdevs.h are marked:
peter [Thu, 29 Mar 2001 00:05:51 +0000 (00:05 +0000)]
Hint: usbdevs_data.h and usbdevs.h are marked:
  * THIS FILE IS AUTOMATICALLY GENERATED.  DO NOT EDIT.
Put the Epson 1240 scanner device in the correct place.

23 years agoMostly pick up OpenBSD's rev 1.14 by deraadt@ and millert@.
peter [Wed, 28 Mar 2001 23:55:51 +0000 (23:55 +0000)]
Mostly pick up OpenBSD's rev 1.14 by deraadt@ and millert@.
I've left out a couple of unused args between internal functions.
Use MAXPATHLEN, not MAXPATHLEN + 1 in a couple of places.
Pass a pointer to the end of the target filename space.

23 years agoPrepare for pseudofs.
des [Wed, 28 Mar 2001 22:21:07 +0000 (22:21 +0000)]
Prepare for pseudofs.

23 years agoUpdate message #56. Maxim didn't merge the English version here since
joerg [Wed, 28 Mar 2001 21:33:30 +0000 (21:33 +0000)]
Update message #56.  Maxim didn't merge the English version here since
partially merging the line would have exceeded 80 characters.

Reminded by: sobomax

23 years agoThere was only a single message to be translated into German here.
joerg [Wed, 28 Mar 2001 21:02:56 +0000 (21:02 +0000)]
There was only a single message to be translated into German here.

23 years agoBring the usage message in synch with reality.
des [Wed, 28 Mar 2001 21:01:07 +0000 (21:01 +0000)]
Bring the usage message in synch with reality.

PR: bin/26160

23 years agoo introduce u_cansee(), which performs access control checks between
rwatson [Wed, 28 Mar 2001 20:50:15 +0000 (20:50 +0000)]
o introduce u_cansee(), which performs access control checks between
  two subject ucreds.  Unlike p_cansee(), u_cansee() doesn't have
  process lock requirements, only valid ucred reference requirements,
  so is prefered as process locking improves.  For now, back p_cansee()
  into u_cansee(), but eventually p_cansee() will go away.

Reviewed by: jhb, tmm
Obtained from: TrustedBSD Project

23 years agoMake per-address input packet counts for lo0 work.
ume [Wed, 28 Mar 2001 19:47:52 +0000 (19:47 +0000)]
Make per-address input packet counts for lo0 work.

Reported by: bmah
Submitted by: Noriyasu KATO <noriyasu.kato@toshiba.co.jp> (via itojun)

23 years agoAdd to BUGS section why tar can't dump large minors
phk [Wed, 28 Mar 2001 19:31:59 +0000 (19:31 +0000)]
Add to BUGS section why tar can't dump large minors

23 years agoresurrect the declaration of order to unbreak kernel build. Put
gallatin [Wed, 28 Mar 2001 19:02:08 +0000 (19:02 +0000)]
resurrect the declaration of order to unbreak kernel build.  Put
it inside the ifdef so as to avoid unused variable warnings

23 years agoThe f_syncreads and f_asyncreads entries are missing from the man page.
phk [Wed, 28 Mar 2001 18:21:54 +0000 (18:21 +0000)]
The f_syncreads and f_asyncreads entries are missing from the man page.

This also tidies up the formatting a bit and omits all the padding
entries.

PR: 25834
Submitted by: Tony Finch <dot@dotat.at>

23 years agoSmall patch is required to the USB susbsystem to include support for
phk [Wed, 28 Mar 2001 17:58:31 +0000 (17:58 +0000)]
Small patch is required to the USB susbsystem to include support for
Epson Perfection 1240U scanner.

PR: 25565
Submitted by: Martin Machacek <m@m3a.cz>

23 years agoUpdate history to reflect that ktr first appeared in BSD/OS 3.0.
jhb [Wed, 28 Mar 2001 17:54:50 +0000 (17:54 +0000)]
Update history to reflect that ktr first appeared in BSD/OS 3.0.

23 years agoChange ntp_flags to "-b" to inspire people to set it right.
phk [Wed, 28 Mar 2001 17:51:03 +0000 (17:51 +0000)]
Change ntp_flags to "-b" to inspire people to set it right.

Note that "right" in this case is not universally recognized, but
NTP-practittioners as opposed to theoretians generally agree that
getting "inside the window" using ntpdate is TRTTD on PC hardware.

PR: 25514
Submitted by: Chris Johnson <cjohnson-pr@palomine.net>

23 years agoAllow specification of which source address to use for encapsulation.
phk [Wed, 28 Mar 2001 17:30:26 +0000 (17:30 +0000)]
Allow specification of which source address to use for encapsulation.

PR: 25847
Submitted by: Eugene Polovnikov <eugene@brain-fag.org>

23 years agoAdd Ukrainian translation.
sobomax [Wed, 28 Mar 2001 16:51:02 +0000 (16:51 +0000)]
Add Ukrainian translation.

Submitted by: Olexander Kunytsa <kunia@wolf.istc.kiev.ua>

23 years agoClose a race condition where if we were obtaining a sleep lock and no spin
jhb [Wed, 28 Mar 2001 16:11:51 +0000 (16:11 +0000)]
Close a race condition where if we were obtaining a sleep lock and no spin
locks were held, we could be preempted and switch CPU's in between the time
that we set a variable to the list of spin locks on our CPU and the time
that we checked that variable to ensure no spinlocks were held while
grabbing a sleep lock.  Losing the race resulted in checking some other
CPU's spin lock list and bogusly panicing.

23 years agoFix a number of minor bugs in the VLAN code:
yar [Wed, 28 Mar 2001 15:52:12 +0000 (15:52 +0000)]
Fix a number of minor bugs in the VLAN code:

* Initialize the "struct sockaddr_dl sdl" correctly in vlan_setmulti().

  PR: kern/22181

* The driver used to call malloc(..., M_NOWAIT), but to not check the
  return value. Change malloc(..., M_NOWAIT) to malloc(..., M_WAITOK)
  because the corresponding part of code is called from the upper
  half of the kernel only.

  PR: kern/22181

* Make sure a parent interface is up and running before invoking
  its if_start() routine in order to avoid system panic.

  PR: kern/22179 kern/24741 i386/25478

* Do not copy all the flags from a parent mindlessly.

  PR: kern/22179

* Do not call if_down() on a parent interface if it's already down.
  Call if_down() at splimp because if_down() needs that.

  PR: kern/22179

Reviewed by: wollman

23 years ago- Document recent MAN[1-9] -> MAN changes.
ru [Wed, 28 Mar 2001 15:12:29 +0000 (15:12 +0000)]
- Document recent MAN[1-9] -> MAN changes.
- Backout part of revision 1.4 (../Makefile.inc -> bsd.inc.mk change).

23 years agoDefine MAN to ${PROG}.1 if no manpages were specified, but still
ru [Wed, 28 Mar 2001 15:07:48 +0000 (15:07 +0000)]
Define MAN to ${PROG}.1 if no manpages were specified, but still
provide MAN1 for backwards compatibility.  Third party software
may still have dependancy lines of this form:

${MAN1}: foo.man

23 years agoAdd missing includes of <sys/sx.h>
jhb [Wed, 28 Mar 2001 15:04:22 +0000 (15:04 +0000)]
Add missing includes of <sys/sx.h>

Reported by: peter

23 years ago- Removed `n' from the list of manpage sections.
ru [Wed, 28 Mar 2001 14:58:08 +0000 (14:58 +0000)]
- Removed `n' from the list of manpage sections.

- Only support the old syntax for manpage declarations
  (MAN1...MAN9) if no MAN is defined.

23 years agoTypo fix. s/criticale_t/critical_t/
peter [Wed, 28 Mar 2001 14:54:28 +0000 (14:54 +0000)]
Typo fix. s/criticale_t/critical_t/

23 years agoMFC candidate.
jesper [Wed, 28 Mar 2001 14:13:19 +0000 (14:13 +0000)]
MFC candidate.

Change code from PRC_UNREACH_ADMIN_PROHIB to PRC_UNREACH_PORT for
ICMP_UNREACH_PROTOCOL and ICMP_UNREACH_PORT

And let TCP treat PRC_UNREACH_PORT like PRC_UNREACH_ADMIN_PROHIB

This should fix the case where port unreachables for udp returned
ENETRESET instead of ECONNREFUSED

Problem found by: Bill Fenner <fenner@research.att.com>
Reviewed by: jlemon

23 years agoIn case the driver runs on an HP NetRaid controller, attempt to properly
hm [Wed, 28 Mar 2001 14:11:15 +0000 (14:11 +0000)]
In case the driver runs on an HP NetRaid controller, attempt to properly
decode the BIOS and firmware version and announce the board as HP NetRaid.

This has been tested with a NetRaid 3si controller, the BIOS/firmware
printout should also work for other NetRaid controllers but the type
detection for other NetRaids (such as the 1si) will not work due to the
lack of hardware.

Reviewed by: msmith

23 years agoForgot to add pci_if.h to SRCS
alfred [Wed, 28 Mar 2001 13:42:42 +0000 (13:42 +0000)]
Forgot to add pci_if.h to SRCS

Pointed out by: phk

23 years agoAllow ident requests with trailing junk following the terminating "\n".
dwmalone [Wed, 28 Mar 2001 13:41:19 +0000 (13:41 +0000)]
Allow ident requests with trailing junk following the terminating "\n".

Reviewed by: ben
Approved by: green

23 years agoBack out my fseeko -> fseek(END) change - we need to position on what we
ache [Wed, 28 Mar 2001 13:10:17 +0000 (13:10 +0000)]
Back out my fseeko -> fseek(END) change - we need to position on what we
displayed last, not to the end of file

23 years ago- Both <sys/sx.h> and <sys/mutex.h> depend on <sys/types.h> and
jhb [Wed, 28 Mar 2001 12:45:41 +0000 (12:45 +0000)]
- Both <sys/sx.h> and <sys/mutex.h> depend on <sys/types.h> and
  <sys/lock.h>.
- <sys/sx.h> depends on <sys/mutex.h>.

23 years agoAdd a simple manpage describing the basic functionality of witness.
jhb [Wed, 28 Mar 2001 12:44:30 +0000 (12:44 +0000)]
Add a simple manpage describing the basic functionality of witness.
It needs a diagonistics section added at some point in the future.

23 years ago- s/mutexes/locks/g in appropriate comments.
jhb [Wed, 28 Mar 2001 12:39:40 +0000 (12:39 +0000)]
- s/mutexes/locks/g in appropriate comments.
- Rename the 'show mutexes' ddb command to 'show locks' since it shows
  a list of all the lock objects held by the current process.

23 years agoMerged src/lib/libtelnet rev.1.9 (fixed removing of obsolete shared
ru [Wed, 28 Mar 2001 12:15:22 +0000 (12:15 +0000)]
Merged src/lib/libtelnet rev.1.9 (fixed removing of obsolete shared
library: wrong library directory, wrong library extension and wrong
comment).  This is mainly of historical interest, if any.  The library
that gets removed is aout.

Also, backout the beforeinstall -> afterinstall change in rev.1.20
that was required to install proper telnet.h into /usr/include/arpa.
The actual problem is in <bsd.lib.mk>, and I am going to fix it.

23 years agoBye-bye /usr/lib/libtelnet.a. This should fix ``make release'' brokeness.
ru [Wed, 28 Mar 2001 12:08:22 +0000 (12:08 +0000)]
Bye-bye /usr/lib/libtelnet.a.  This should fix ``make release'' brokeness.

Approved by: markm

23 years agoConvert the allproc and proctree locks from lockmgr locks to sx locks.
jhb [Wed, 28 Mar 2001 11:52:56 +0000 (11:52 +0000)]
Convert the allproc and proctree locks from lockmgr locks to sx locks.

23 years agoPut a note about ee(1) update.
sobomax [Wed, 28 Mar 2001 11:50:15 +0000 (11:50 +0000)]
Put a note about ee(1) update.

23 years agoAxe out duplicate.
phk [Wed, 28 Mar 2001 11:10:50 +0000 (11:10 +0000)]
Axe out duplicate.

Not to submitter: (I don't let Jordan use my axe)

PR: 24782
Submitted by: Szilveszter Adam <sziszi@petra.hos.u-szeged.hu>

23 years agoSpelling fixes.
phk [Wed, 28 Mar 2001 11:08:32 +0000 (11:08 +0000)]
Spelling fixes.

PR: 20474
Submitted by: Christian Weisgerber <naddy@mips.inka.de>

23 years agoRemove duplicate.
phk [Wed, 28 Mar 2001 11:06:50 +0000 (11:06 +0000)]
Remove duplicate.

PR: 19670
Submitted by: Anton Berezin <tobez@tobez.org>

23 years agoRemove a duplicate piece of chalk.
phk [Wed, 28 Mar 2001 11:02:14 +0000 (11:02 +0000)]
Remove a duplicate piece of chalk.

PR: 23132
Submitted by: Alex Kapranoff <alex@kapran.bitmcnit.bryansk.su>

23 years agoOpenBSD's g_Ctoc() returned a false error when the target buffer was
peter [Wed, 28 Mar 2001 10:56:11 +0000 (10:56 +0000)]
OpenBSD's g_Ctoc() returned a false error when the target buffer was
exactly the right size.  Do it differently - pass a length rather than an
end-of-string+1 pointer as this is more convenient anyway.  Get rid of
the bogus +1's.

23 years agoPass in a pointer to the mutex's lock_object as the second argument to
jhb [Wed, 28 Mar 2001 10:41:15 +0000 (10:41 +0000)]
Pass in a pointer to the mutex's lock_object as the second argument to
WITNESS_SLEEP() rather than the mutex itself.

23 years agoRemove sockets found in /var/run or /var/spool/lock at boot time
brian [Wed, 28 Mar 2001 10:13:26 +0000 (10:13 +0000)]
Remove sockets found in /var/run or /var/spool/lock at boot time
(as well as files).

23 years agoFix g_Ctoc() interface, approximately based on OpenBSD's recent changes.
peter [Wed, 28 Mar 2001 09:53:16 +0000 (09:53 +0000)]
Fix g_Ctoc() interface, approximately based on OpenBSD's recent changes.
Also, set gl_pathv to NULL after we free it, especially when dealing
with realloc failures.

Obtained from: OpenBSD

23 years agoBring the PPPoE interface UP if required
brian [Wed, 28 Mar 2001 09:45:27 +0000 (09:45 +0000)]
Bring the PPPoE interface UP if required

Suggested by: archie

23 years agoCatch up to header include changes:
jhb [Wed, 28 Mar 2001 09:17:56 +0000 (09:17 +0000)]
Catch up to header include changes:
- <sys/mutex.h> now requires <sys/systm.h>
- <sys/mutex.h> and <sys/sx.h> now require <sys/lock.h>

23 years agoUse mtx_initiaalized() rather than violating the internals of the mutex
jhb [Wed, 28 Mar 2001 09:04:25 +0000 (09:04 +0000)]
Use mtx_initiaalized() rather than violating the internals of the mutex
structure.

23 years agoRework the witness code to work with sx locks as well as mutexes.
jhb [Wed, 28 Mar 2001 09:03:24 +0000 (09:03 +0000)]
Rework the witness code to work with sx locks as well as mutexes.
- Introduce lock classes and lock objects.  Each lock class specifies a
  name and set of flags (or properties) shared by all locks of a given
  type.  Currently there are three lock classes: spin mutexes, sleep
  mutexes, and sx locks.  A lock object specifies properties of an
  additional lock along with a lock name and all of the extra stuff needed
  to make witness work with a given lock.  This abstract lock stuff is
  defined in sys/lock.h.  The lockmgr constants, types, and prototypes have
  been moved to sys/lockmgr.h.  For temporary backwards compatability,
  sys/lock.h includes sys/lockmgr.h.
- Replace proc->p_spinlocks with a per-CPU list, PCPU(spinlocks), of spin
  locks held.  By making this per-cpu, we do not have to jump through
  magic hoops to deal with sched_lock changing ownership during context
  switches.
- Replace proc->p_heldmtx, formerly a list of held sleep mutexes, with
  proc->p_sleeplocks, which is a list of held sleep locks including sleep
  mutexes and sx locks.
- Add helper macros for logging lock events via the KTR_LOCK KTR logging
  level so that the log messages are consistent.
- Add some new flags that can be passed to mtx_init():
  - MTX_NOWITNESS - specifies that this lock should be ignored by witness.
    This is used for the mutex that blocks a sx lock for example.
  - MTX_QUIET - this is not new, but you can pass this to mtx_init() now
    and no events will be logged for this lock, so that one doesn't have
    to change all the individual mtx_lock/unlock() operations.
- All lock objects maintain an initialized flag.  Use this flag to export
  a mtx_initialized() macro that can be safely called from drivers.  Also,
  we on longer walk the all_mtx list if MUTEX_DEBUG is defined as witness
  performs the corresponding checks using the initialized flag.
- The lock order reversal messages have been improved to output slightly
  more accurate file and line numbers.

23 years ago- Resort some includes to deal with the new witness code coming in shortly.
jhb [Wed, 28 Mar 2001 08:41:04 +0000 (08:41 +0000)]
- Resort some includes to deal with the new witness code coming in shortly.
- Make sure we have Giant locked before calling coredump() in sigexit().

Spotted by: peter (2)

23 years agoAdd a manpage for the critical_enter/exit() functions.
jhb [Wed, 28 Mar 2001 07:30:58 +0000 (07:30 +0000)]
Add a manpage for the critical_enter/exit() functions.

23 years agoBack out previous commit until I figure out a way to do it properly.
jlemon [Wed, 28 Mar 2001 07:01:45 +0000 (07:01 +0000)]
Back out previous commit until I figure out a way to do it properly.
We really want to be able to say "auto NWAY", "limited NWAY", and
"no NWAY".  Unfortunately, this does not appear to be possible with
the current mediaopt structure.

23 years agoFix nasty corruption problem where a 64bit variable was being used
markm [Wed, 28 Mar 2001 06:27:42 +0000 (06:27 +0000)]
Fix nasty corruption problem where a 64bit variable was being used
(overflowed) to catch a 256bit result.

Hard work done by: jhb

23 years agoAdd support for the Addtron AWA100 PCI wireless card.
alfred [Wed, 28 Mar 2001 05:05:05 +0000 (05:05 +0000)]
Add support for the Addtron AWA100 PCI wireless card.

The AWA100 is a PCI board with a PLX 9052 chip that's used to talk to
the pccard inserted into the board.

Remove a redundant $FreeBSD while I'm here.

23 years agoDon't explicitly zero p_intr_nesting_level and p_aioinfo in fork.
jhb [Wed, 28 Mar 2001 03:14:14 +0000 (03:14 +0000)]
Don't explicitly zero p_intr_nesting_level and p_aioinfo in fork.

23 years ago- Fix a whitespace bogon with p_blocked.
jhb [Wed, 28 Mar 2001 03:08:59 +0000 (03:08 +0000)]
- Fix a whitespace bogon with p_blocked.
- Move p_intr_nesting_level, p_aioinfo, and p_ithd into the zero'd area
  so that we don't have to explicitly zero them during fork().

23 years agoSwitch from save/disable/restore_intr() to critical_enter/exit().
jhb [Wed, 28 Mar 2001 03:06:10 +0000 (03:06 +0000)]
Switch from save/disable/restore_intr() to critical_enter/exit().

23 years agoCatch up to the mtx_saveintr -> mtx_savecrit change.
jhb [Wed, 28 Mar 2001 02:46:21 +0000 (02:46 +0000)]
Catch up to the mtx_saveintr -> mtx_savecrit change.

23 years agoUse mtx_intr_enable() on sched_lock to ensure child processes always start
jhb [Wed, 28 Mar 2001 02:44:11 +0000 (02:44 +0000)]
Use mtx_intr_enable() on sched_lock to ensure child processes always start
with interrupts enabled rather than calling the no-longer MI function
enable_intr().  This is bogus anyways and in theory shouldn't even be
needed.

23 years ago- Switch from using save/disable/restore_intr to using critical_enter/exit
jhb [Wed, 28 Mar 2001 02:40:47 +0000 (02:40 +0000)]
- Switch from using save/disable/restore_intr to using critical_enter/exit
  and change the u_int mtx_saveintr member of struct mtx to a critical_t
  mtx_savecrit.
- On the alpha we no longer need a custom _get_spin_lock() macro to avoid
  an extra PAL call, so remove it.
- Partially fix using mutexes with WITNESS in modules.  Change all the
  _mtx_{un,}lock_{spin,}_flags() macros to accept explicit file and line
  parameters and rename them to use a prefix of two underscores.  Inside
  of kern_mutex.c, generate wrapper functions for
  _mtx_{un,}lock_{spin,}_flags() (only using a prefix of one underscore)
  that are called from modules.  The macros mtx_{un,}lock_{spin,}_flags()
  are mapped to the __mtx_* macros inside of the kernel to inline the
  usual case of mutex operations and map to the internal _mtx_* functions
  in the module case so that modules will use WITNESS and KTR logging if
  the kernel is compiled with support for it.

23 years agoMention that the vga(4) driver supports 90-column video modes.
dd [Wed, 28 Mar 2001 02:32:10 +0000 (02:32 +0000)]
Mention that the vga(4) driver supports 90-column video modes.

PR: 26050
Submitted by: Alex Kapranoff <alex@kapran.bitmcnit.bryansk.su>
Approved by: nik

23 years ago- Add the new critical_t type used to save state inside of critical
jhb [Wed, 28 Mar 2001 02:31:54 +0000 (02:31 +0000)]
- Add the new critical_t type used to save state inside of critical
  sections.
- Add implementations of the critical_enter() and critical_exit() functions
  and remove restore_intr() and save_intr().
- Remove the somewhat bogus disable_intr() and enable_intr() functions on
  the alpha as the alpha actually uses a priority level and not simple bit
  flag on the CPU.

23 years agoPrevious commit message was bogus:
jhb [Wed, 28 Mar 2001 02:07:28 +0000 (02:07 +0000)]
Previous commit message was bogus:
- Switch to using critical_enter/exit instead of save/disable/restore_intr.

23 years agoRevert previous commit which had a bogus message. It actually just
jhb [Wed, 28 Mar 2001 02:03:29 +0000 (02:03 +0000)]
Revert previous commit which had a bogus message.  It actually just
disabled the somewhat annoying KTR log trace for clock interrupts.

23 years agoPrevious commit message was bogus:
jhb [Wed, 28 Mar 2001 02:01:34 +0000 (02:01 +0000)]
Previous commit message was bogus:
- Catch up to rename of mtx_saveintr to mtx_savecrit within struct mtx.

23 years agoPrevious commit message was bogus, here's the real one:
jhb [Wed, 28 Mar 2001 01:59:40 +0000 (01:59 +0000)]
Previous commit message was bogus, here's the real one:
- Switch to using critical_enter/exit instead of save/disable/restore_intr.
- Disable interrupts in Debugger().

This second change wasn't really supposed to go in, but since it's in
there and is useful so that one doesn't get spammed with clock interrupts
while in ddb, I'll leave it in unless people want it reverted.

23 years agoThe previous commit message is bogus, this actually just removed an
jhb [Wed, 28 Mar 2001 01:56:13 +0000 (01:56 +0000)]
The previous commit message is bogus, this actually just removed an
unused variable to silence a warning.

23 years ago- Include <machine/prom.h> to get the prototype for prom_halt().
jhb [Wed, 28 Mar 2001 01:54:06 +0000 (01:54 +0000)]
- Include <machine/prom.h> to get the prototype for prom_halt().
- If there is no gdb device, just return without trying to return any
  value since gdb_handle_exception() returns void.
- When calling prom_halt(), pass in a value telling it to actually halt
  and not to randomly choose whether or not to halt or reboot depending on
  whatever value happened to be in a0 when the call was made.

23 years agoLast commit was broken.. It always prints '[CTRL-C to abort]'.
ps [Wed, 28 Mar 2001 01:37:29 +0000 (01:37 +0000)]
Last commit was broken.. It always prints '[CTRL-C to abort]'.
Move duplicate code for printing the status of the dump and checking
for abort into a separate function.

Pointy hat to: me

23 years agoCheck whether we need to do a full restore after handling ASTs. If
gallatin [Wed, 28 Mar 2001 01:19:41 +0000 (01:19 +0000)]
Check whether we need to do a full restore after handling ASTs.  If
an AST results in a signal being delivered, we'll need to do a full register
restore so as to properly setup the signal handler.  This is somewhat of
a pessimization, because ast() will be called twice in this case.

This fixes several problems that have been reported where signal intensive
userland apps (most notably dump) have been SEGV'ing for no fault of their
own.

Thanks to Peter Jeremy <peter.jeremy@alcatel.com.au> for presenting the
AST scenario which led to me fiinally figuring this out.

Reviewed by: jhb

23 years agoo De-uglify IMPLEMENTATION NOTES section by removing unnecessary use of
rwatson [Wed, 28 Mar 2001 01:03:33 +0000 (01:03 +0000)]
o De-uglify IMPLEMENTATION NOTES section by removing unnecessary use of
  .Fx

23 years agoAdd some comments to two examples and extend a ``set ifaddr''.
brian [Wed, 28 Mar 2001 00:23:30 +0000 (00:23 +0000)]
Add some comments to two examples and extend a ``set ifaddr''.

23 years agoRestore part of my fix spammed in v1.23:
ache [Tue, 27 Mar 2001 23:24:25 +0000 (23:24 +0000)]
Restore part of my fix spammed in v1.23:
fseeko(file_size, SEEK_SET) -> fseek(0L, SEEK_END)
1) File may grows between operations, so fseeko to file_size may miss
2) 0L, SEEK_END is the same code using in tail in all other places

23 years agoUpdate the acknowledgements section.
jkh [Tue, 27 Mar 2001 22:06:37 +0000 (22:06 +0000)]
Update the acknowledgements section.

23 years agoFinally fix __yp_ping(). We can't use the old locally defined clntudp_call()
wpaul [Tue, 27 Mar 2001 21:29:31 +0000 (21:29 +0000)]
Finally fix __yp_ping(). We can't use the old locally defined clntudp_call()
method anymore since the code inside the RPC library has changed too much.
Now that the clnt_dg module has the necessary code internally, we can yank
out the local method code and turn on the ASYNC hack with clnt_control().
This will make the -m flag work again.

23 years agoAdd a CLSET_ASYNC command, which allows us to (ab)use the clnt_dg transport
wpaul [Tue, 27 Mar 2001 21:27:33 +0000 (21:27 +0000)]
Add a CLSET_ASYNC command, which allows us to (ab)use the clnt_dg transport
to make asynchronous RPCs. This is needed to help fix ypbind, which can no
longer override the clnt_dg_call() method (formerly the clntudp_call()
method) due to all the internal descriptor locking code in TI-RPC. Turning
on this flag allows us to send an RPC request, then return immediately,
and handle a reply later, rather than being forced to do the request
and reply in a single function call.

Also fix a byte ordering bug: when clnt_dg_call() increments the XID
prior to transmitting a request, it uses the raw value, which is wrong.
The XID is stored in network byte order, i.e. big-endian. The CLSET_XID
and CLGET_XID commands in clnt_dg_control() use ntohl()/htonl() to get
the byte ordering right, but because clnt_dg_call() does not do this,
using CLSET_XID/CLGET_XID doesn't actually work, unless you're on a
big endian host, which we aren't (yet). Fix clnt_dg_call() to byte swap
properly when doing the increment.

23 years agoNew release notes: Filesystem ACLs, getfacl(1) and setfacl(1).
bmah [Tue, 27 Mar 2001 21:17:18 +0000 (21:17 +0000)]
New release notes:  Filesystem ACLs, getfacl(1) and setfacl(1).

Submitted by: rwatson

23 years agoDon't leak the memory we've just malloced if we can't find the
dwmalone [Tue, 27 Mar 2001 20:49:51 +0000 (20:49 +0000)]
Don't leak the memory we've just malloced if we can't find the
process we're looking for. (I don't think this can currently
happen, but it depends how the function is called).

PR: 25932
Submitted by: David Xu <davidx@viasoft.com.cn>