]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
22 years agoImprove the implementation of adjtime(2).
Poul-Henning Kamp [Mon, 15 Apr 2002 12:23:11 +0000 (12:23 +0000)]
Improve the implementation of adjtime(2).

Apply the change as a continuous slew rather than as a series of
discrete steps and make it possible to adjust arbitraryly huge
amounts of time in either direction.

In practice this is done by hooking into the same once-per-second
loop as the NTP PLL and setting a suitable frequency offset deducting
the amount slewed from the remainder.  If the remaining delta is
larger than 1 second we slew at 5000PPM (5msec/sec), for a delta
less than a second we slew at 500PPM (500usec/sec) and for the last
one second period we will slew at whatever rate (less than 500PPM)
it takes to eliminate the delta entirely.

The old implementation stepped the clock a number of microseconds
every HZ to acheive the same effect, using the same rates of change.

Eliminate the global variables tickadj, tickdelta and timedelta and
their various use and initializations.

This removes the most significant obstacle to running timecounter and
NTP housekeeping from a timeout rather than hardclock.

22 years agoTurn some CTR's into CTR0's.
Benno Rice [Mon, 15 Apr 2002 12:11:18 +0000 (12:11 +0000)]
Turn some CTR's into CTR0's.

22 years agoTake the "tickadj" element out of struct clockinfo. Our adjtime(2)
Poul-Henning Kamp [Mon, 15 Apr 2002 12:11:06 +0000 (12:11 +0000)]
Take the "tickadj" element out of struct clockinfo.  Our adjtime(2)
implementation is being changed and the very concept of tickadj will
no longer be meaningful.

22 years agoGC an extraneous prototype of delay().
Benno Rice [Mon, 15 Apr 2002 12:02:43 +0000 (12:02 +0000)]
GC an extraneous prototype of delay().

22 years agoAdd libypclnt to the prebuild library list, and record its dependency on
Dag-Erling Smørgrav [Mon, 15 Apr 2002 11:31:52 +0000 (11:31 +0000)]
Add libypclnt to the prebuild library list, and record its dependency on
librpcsvc.

22 years agoBasic OpenFirmware disk driver. It will attach to anything in OpenFirmware
Benno Rice [Mon, 15 Apr 2002 10:54:22 +0000 (10:54 +0000)]
Basic OpenFirmware disk driver.  It will attach to anything in OpenFirmware
that declares itself to be a disk, which may be the wrong thing to do in
the long term but it works well enough to attach to emulated disks in the
PowerPC simulator in gdb now that they have the proper device_type
property.

22 years agoGrab a major number for OpenFirmware disk devices.
Benno Rice [Mon, 15 Apr 2002 10:41:47 +0000 (10:41 +0000)]
Grab a major number for OpenFirmware disk devices.

22 years agoFix all-man to look into the SUBDIR subdirs as well.
Ruslan Ermilov [Mon, 15 Apr 2002 10:17:35 +0000 (10:17 +0000)]
Fix all-man to look into the SUBDIR subdirs as well.

22 years agoAdded glue for the all-man and maninstall targets.
Ruslan Ermilov [Mon, 15 Apr 2002 10:16:26 +0000 (10:16 +0000)]
Added glue for the all-man and maninstall targets.

22 years agoDon't unnecessarily include bsd.own.mk.
Ruslan Ermilov [Mon, 15 Apr 2002 09:37:12 +0000 (09:37 +0000)]
Don't unnecessarily include bsd.own.mk.
(This is apparently required in NetBSD).

22 years agoStyle nits.
Ruslan Ermilov [Mon, 15 Apr 2002 09:33:34 +0000 (09:33 +0000)]
Style nits.

22 years agoDon't unnecessarily include .mk files.
Ruslan Ermilov [Mon, 15 Apr 2002 09:33:00 +0000 (09:33 +0000)]
Don't unnecessarily include .mk files.

22 years agoImplement dougb's excellent suggestion, and satisfy one desire of ru.
David E. O'Brien [Mon, 15 Apr 2002 09:28:05 +0000 (09:28 +0000)]
Implement dougb's excellent suggestion, and satisfy one desire of ru.

22 years agooption<space><tab>
David E. O'Brien [Mon, 15 Apr 2002 09:21:51 +0000 (09:21 +0000)]
option<space><tab>

22 years agoIn the ntp_adjtime(2) syscall, return our actual estimate of unapplied
Poul-Henning Kamp [Mon, 15 Apr 2002 08:58:24 +0000 (08:58 +0000)]
In the ntp_adjtime(2) syscall, return our actual estimate of unapplied
offset correction instead of the most recent offset applied.

22 years agoLong-forgotten patch: warn if a closed PR has no "closed by"
Dag-Erling Smørgrav [Mon, 15 Apr 2002 06:36:22 +0000 (06:36 +0000)]
Long-forgotten patch: warn if a closed PR has no "closed by"

22 years agoLong-forgotten patch: list prstats
Dag-Erling Smørgrav [Mon, 15 Apr 2002 06:35:36 +0000 (06:35 +0000)]
Long-forgotten patch: list prstats

22 years agoThis commit was generated by cvs2svn to compensate for changes in r94735,
Dag-Erling Smørgrav [Mon, 15 Apr 2002 06:32:54 +0000 (06:32 +0000)]
This commit was generated by cvs2svn to compensate for changes in r94735,
which included commits to RCS files with non-trunk default branches.

22 years agoPrint newline after error and info messages (perforce change 9750)
Dag-Erling Smørgrav [Mon, 15 Apr 2002 06:32:54 +0000 (06:32 +0000)]
Print newline after error and info messages (perforce change 9750)

22 years agoUse PAM_SUCCESS instead of PAM_IGNORE.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 06:26:32 +0000 (06:26 +0000)]
Use PAM_SUCCESS instead of PAM_IGNORE.

22 years agoRemoved 2 lines from the cd(9) manual page.
Tom Rhodes [Mon, 15 Apr 2002 06:02:58 +0000 (06:02 +0000)]
Removed 2 lines from the cd(9) manual page.

PR: 35944

22 years agoFinish adding support code for sysctl kern.mprof. This dumps some malloc
Jeff Roberson [Mon, 15 Apr 2002 05:24:01 +0000 (05:24 +0000)]
Finish adding support code for sysctl kern.mprof.  This dumps some malloc
information related to bucket size effeciency.  Three things are printed on
each row:

Size is the size the user actually asked for rounded to 16 bytes.
Requests is the number of times this size was asked for.
Real Size is the size we actually handed out.

At the end the total memory used and total waste is displayed.  Currently my
system displays about 33% wasted memory.

The intent of this code is to gather statistics for tuning the malloc bucket
sizes.  It is not intended to be run with INVARIANTS and it is not entirely
mp safe.  It can be enabled via 'options MALLOC_PROFILE' which was commited
earlier.

22 years agoRemove malloc_type's ks_limit.
Jeff Roberson [Mon, 15 Apr 2002 04:05:53 +0000 (04:05 +0000)]
Remove malloc_type's ks_limit.

Updated the kmemzones logic such that the ks_size bitmap can be used as an
index into it to report the size of the zone used.

Create the kern.malloc sysctl which replaces the kvm mechanism to report
similar data.  This will provide an easy place for statistics aggregation if
malloc_type statistics become per cpu data.

Add some code ifdef'd under MALLOC_PROFILING to facilitate a tool for sizing
the malloc buckets.

22 years agoWhitespace nits.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:52:22 +0000 (03:52 +0000)]
Whitespace nits.

22 years agoAdd a manual page based on Solar Designer's README.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:45:14 +0000 (03:45 +0000)]
Add a manual page based on Solar Designer's README.

Sponsored by: DARPA, NAI Labs

22 years agopam_passwdqc depends on libcrypt.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:44:42 +0000 (03:44 +0000)]
pam_passwdqc depends on libcrypt.

22 years agoDon't peak into the malloc_type structure for limits. The desired vnodes
Jeff Roberson [Mon, 15 Apr 2002 03:35:35 +0000 (03:35 +0000)]
Don't peak into the malloc_type structure for limits.  The desired vnodes
check should be sufficient.  This is required for the pending removal of
malloc_type limits.

22 years agoInclude <sys/_types.h>. This should have been part of the previous
Mike Barcroft [Mon, 15 Apr 2002 03:33:27 +0000 (03:33 +0000)]
Include <sys/_types.h>.  This should have been part of the previous
revision.

22 years agoAdd support for X/Open.
Mike Barcroft [Mon, 15 Apr 2002 03:21:21 +0000 (03:21 +0000)]
Add support for X/Open.

PR: 37078

22 years agoTurn off collect2.
David E. O'Brien [Mon, 15 Apr 2002 03:15:40 +0000 (03:15 +0000)]
Turn off collect2.
collect2 was added based on the need of -frepo.  However, -frepo is currently
broken on -CURRENT (Gcc 2.95.4 20020320 [FreeBSD] / ld 2.12.0 [FreeBSD]
2002-04-10).  It is also broken on RELENG_4 (Gcc 2.95.3 20010315 / ld
2.11.2 20010719), so there is no need to MFC collect2 there yet.  I have
a feeling the brokeness is due to the wide difference between the libiberty
bits of Gcc 2.95 and the later ld.

Testing by: fjoe

22 years agoPAMified passwd(1). Some NIS-related issues remain to be solved, but this
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:02:57 +0000 (03:02 +0000)]
PAMified passwd(1).  Some NIS-related issues remain to be solved, but this
should work for everyday use.

Sponsored by: DARPA, NAI Labs

22 years agoAdd PAM policy for the "passwd" service, including a sample config line
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:01:32 +0000 (03:01 +0000)]
Add PAM policy for the "passwd" service, including a sample config line
for pam_passwdqc.

Sponsored by: DARPA, NAI Labs

22 years agoPrompt for new password during update phase, not during preliminary phase.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 03:00:14 +0000 (03:00 +0000)]
Prompt for new password during update phase, not during preliminary phase.

Sponsored by: DARPA, NAI Labs

22 years agoAdd pam_lastlog(8) here since I removed lastlog support from sshd.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 02:46:24 +0000 (02:46 +0000)]
Add pam_lastlog(8) here since I removed lastlog support from sshd.

Sponsored by: DARPA, NAI Labs

22 years agoDike out most of the NIS code and replace it with calls to libypclnt.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 02:34:43 +0000 (02:34 +0000)]
Dike out most of the NIS code and replace it with calls to libypclnt.
Rework pam_sm_chauthtok() so it (mostly?) works.
The standard pw stuff still needs to move into a library somewhere.

Sponsored by: DARPA, NAI Labs

22 years agoAdd a dependency on libypclnt to libpam, in preperation for making pam_unix
Dag-Erling Smørgrav [Mon, 15 Apr 2002 02:32:54 +0000 (02:32 +0000)]
Add a dependency on libypclnt to libpam, in preperation for making pam_unix
use it to update NIS passwords.

22 years agoAdd a missing generated file.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 02:32:04 +0000 (02:32 +0000)]
Add a missing generated file.

22 years agoDocument option to option dependancy. Fix typo.
John W. De Boskey [Mon, 15 Apr 2002 02:21:12 +0000 (02:21 +0000)]
Document option to option dependancy. Fix typo.

MFC after: 1 week

22 years agoa.out.5 states that nobody seems to agree on what bss stands for. This is
Tom Rhodes [Mon, 15 Apr 2002 02:05:06 +0000 (02:05 +0000)]
a.out.5 states that nobody seems to agree on what bss stands for.  This is
incorrect, however, as Dennis Ritchie states ``Actually the acronym is "block
started by symbol."  It was a pseudo-op in FAP (Fortran Assembly Program), an
assembler for the IBM <models> machines.  It identified its label and set
aside space for a given number of words.''

PR: 34088
Submitted by: Martin Faxer <gmh003532@brfmasthugget.se>
MFC after: 2 days

22 years agoFix typo in pam_get_authtok(3) (perforce change 9746)
Dag-Erling Smørgrav [Mon, 15 Apr 2002 01:26:36 +0000 (01:26 +0000)]
Fix typo in pam_get_authtok(3) (perforce change 9746)

22 years agoThis commit was generated by cvs2svn to compensate for changes in r94706,
Dag-Erling Smørgrav [Mon, 15 Apr 2002 01:26:36 +0000 (01:26 +0000)]
This commit was generated by cvs2svn to compensate for changes in r94706,
which included commits to RCS files with non-trunk default branches.

22 years agoMissed a spot in previous commit.
Dag-Erling Smørgrav [Mon, 15 Apr 2002 00:21:25 +0000 (00:21 +0000)]
Missed a spot in previous commit.

Sponsored by: DARPA, NAI Labs

22 years agoWhen it's necessary to kldload tun(4), don't forget to re-try to open
Brian Somers [Mon, 15 Apr 2002 00:14:40 +0000 (00:14 +0000)]
When it's necessary to kldload tun(4), don't forget to re-try to open
tun0.

Submitted by: qhwt@myrealbox.com

22 years agoFix tx-rate setting for Lucent cards.
Brooks Davis [Sun, 14 Apr 2002 23:18:40 +0000 (23:18 +0000)]
Fix tx-rate setting for Lucent cards.

Submitted by: Eugene Perevyazko <john@pcs.dp.ua>

22 years agoRemove ws at EOL
Doug Barton [Sun, 14 Apr 2002 22:35:46 +0000 (22:35 +0000)]
Remove ws at EOL

22 years agopam_passwdqc builds now.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:31:36 +0000 (22:31 +0000)]
pam_passwdqc builds now.

22 years agoThis commit was generated by cvs2svn to compensate for changes in r94691,
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:30:54 +0000 (22:30 +0000)]
This commit was generated by cvs2svn to compensate for changes in r94691,
which included commits to RCS files with non-trunk default branches.

22 years agoBug & warning fixes; pretty much what will become 0.5 later this week.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:30:54 +0000 (22:30 +0000)]
Bug & warning fixes; pretty much what will become 0.5 later this week.

Submitted by: Solar Designer <solar@openwall.com>

22 years agoConnect libypclnt to the build.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:27:12 +0000 (22:27 +0000)]
Connect libypclnt to the build.

22 years agoSkip zombies. Add an option (-z) to revert to the historical behaviour
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:25:57 +0000 (22:25 +0000)]
Skip zombies.  Add an option (-z) to revert to the historical behaviour
of trying to kill zombies (which has no effect except emit a few error
messages)

22 years ago(ab)use unused bits in the pw_fields member of struct passwd to record
Dag-Erling Smørgrav [Sun, 14 Apr 2002 22:24:55 +0000 (22:24 +0000)]
(ab)use unused bits in the pw_fields member of struct passwd to record
the source of the data contained in the structure.

Sponsored by: DARPA, NAI Labs

22 years agoSupport the Siemens SpeedStream PCI card.
Brooks Davis [Sun, 14 Apr 2002 22:08:58 +0000 (22:08 +0000)]
Support the Siemens SpeedStream PCI card.

PR: kern/35988
Submitted by: Stephen Gunn <csg@waterspout.com>

22 years agoMake the MTRR code a bit more defensive - this should help people
David Malone [Sun, 14 Apr 2002 20:19:13 +0000 (20:19 +0000)]
Make the MTRR code a bit more defensive - this should help people
trying to run X on some Athlon systems where the BIOS does odd things
(mines an ASUS A7A266, but it seems to also help on other systems).

Here's a description of the problem and my fix:

        The problem with the old MTRR code is that it only expects
        to find documented values in the bytes of MTRR registers.
        To convert the MTRR byte into a FreeBSD "Memory Range Type"
        (mrt) it uses the byte value and looks it up in an array.
        If the value is not in range then the mrt value ends up
        containing random junk.

        This isn't an immediate problem. The mrt value is only used
        later when rewriting the MTRR registers. When we finally
        go to write a value back again, the function i686_mtrrtype()
        searches for the junk value and returns -1 when it fails
        to find it. This is converted to a byte (0xff) and written
        back to the register, causing a GPF as 0xff is an illegal
        value for a MTRR byte.

To work around this problem I've added a new mrt flag
MDF_UNKNOWN.  We set this when we read a MTRR byte which
we do not understand.  If we try to convert a MDF_UNKNOWN
back into a MTRR value, then the new function, i686_mrt2mtrr,
just returns the old value of the MTRR byte. This leaves
the memory range type unchanged.

I have seen one side effect of the fix, which is that ACPI calls
after X has been run seem to hang my machine. As running X would
previously panic the machine, this is still an improvement ;-)

I'd like to MFC this before the 4.6 code freeze - please let me
know if it causes any problems.

PR: 28418, 25958
Tested by: jkh, Christopher Masto <chris@netmonger.net>
MFC after: 2 weeks

22 years agoMake the MTRR code a bit more defensive - this should help people
David Malone [Sun, 14 Apr 2002 20:13:08 +0000 (20:13 +0000)]
Make the MTRR code a bit more defensive - this should help people
trying to run X on some Athlon systems where the BIOS does odd things
(mines an ASUS A7A266, but it seems to also help on other systems).

Here's a description of the problem and my fix:

The problem with the old MTRR code is that it only expects
to find documented values in the bytes of MTRR registers.
To convert the MTRR byte into a FreeBSD "Memory Range Type"
(mrt) it uses the byte value and looks it up in an array.
If the value is not in range then the mrt value ends up
containing random junk.

This isn't an immediate problem. The mrt value is only used
later when rewriting the MTRR registers. When we finally
go to write a value back again, the function i686_mtrrtype()
searches for the junk value and returns -1 when it fails
to find it. This is converted to a byte (0xff) and written
back to the register, causing a GPF as 0xff is an illegal
value for a MTRR byte.

To work around this problem I've added a new mrt flag
MDF_UNKNOWN.  We set this when we read a MTRR byte which
we do not understand.  If we try to convert a MDF_UNKNOWN
back into a MTRR value, then the new function, i686_mrt2mtrr,
just returns the old value of the MTRR byte. This leaves
the memory range type unchanged.

I'd like to merge this before the 4.6 code freeze, so if people
can test this with XFree 4 that would be very useful.

PR: 28418, 25958
Tested by: jkh, Christopher Masto <chris@netmonger.net>
MFC after: 2 weeks

22 years agoCorrect two syntax mistakes.
Jeroen Ruigrok van der Werven [Sun, 14 Apr 2002 19:52:42 +0000 (19:52 +0000)]
Correct two syntax mistakes.
Fix overflowing right side, so that the && operator fits on the same line.

22 years agoRemove extraneous newline.
Jeroen Ruigrok van der Werven [Sun, 14 Apr 2002 19:33:07 +0000 (19:33 +0000)]
Remove extraneous newline.

22 years agoFix up submit.cf alternation instructions in light of new SENDMAIL_SUBMIT_MC
Gregory Neil Shapiro [Sun, 14 Apr 2002 19:24:28 +0000 (19:24 +0000)]
Fix up submit.cf alternation instructions in light of new SENDMAIL_SUBMIT_MC
make.conf knob.

MFC after: 1 week

22 years agoProvide a new make.conf knob, SENDMAIL_SUBMIT_MC to allow users to pick
Gregory Neil Shapiro [Sun, 14 Apr 2002 19:20:26 +0000 (19:20 +0000)]
Provide a new make.conf knob, SENDMAIL_SUBMIT_MC to allow users to pick
the .mc file used for /etc/mail/submit.cf.  By default,
/etc/mail/freebsd.submit.mc is installed and used.

Requested by: fenner
Submitted by: ume
MFC after: 1 week

22 years agoMore recent versions of pam_passwdqc (not yet released) build with very
Dag-Erling Smørgrav [Sun, 14 Apr 2002 18:48:57 +0000 (18:48 +0000)]
More recent versions of pam_passwdqc (not yet released) build with very
few warnings.

22 years agoNew files in OpenPAM Cineraria.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 18:30:27 +0000 (18:30 +0000)]
New files in OpenPAM Cineraria.

Sponsored by: DARPA, NAI Labs

22 years agoCosmetic nit.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 18:30:03 +0000 (18:30 +0000)]
Cosmetic nit.

22 years agoVendor import of OpenPAM Cineraria.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 18:28:22 +0000 (18:28 +0000)]
Vendor import of OpenPAM Cineraria.

22 years agoThis commit was generated by cvs2svn to compensate for changes in r94670,
Dag-Erling Smørgrav [Sun, 14 Apr 2002 18:28:22 +0000 (18:28 +0000)]
This commit was generated by cvs2svn to compensate for changes in r94670,
which included commits to RCS files with non-trunk default branches.

22 years agoThe new Compaq DS20L is a direct derivative of the CS20 so we support
Wilko Bulte [Sun, 14 Apr 2002 18:19:27 +0000 (18:19 +0000)]
The new Compaq DS20L is a direct derivative of the CS20 so we support
it with FreeBSD/alpha.

Pictures of DS20L will be available soon at
http://people.freebsd.org/~wilko/Alpha-gallery/

Along with pictures of a ES80 'Marvel' EV7 box (which we don't support
yet :-P )

22 years agoUse 'struct callout' instead of 'struct callout_handle' to avoid
Archie Cobbs [Sun, 14 Apr 2002 17:37:35 +0000 (17:37 +0000)]
Use 'struct callout' instead of 'struct callout_handle' to avoid
exhausting the kernel timeout table. Perform the usual gymnastics to
avoid race conditions between node shutdown and timeouts occurring.

Also fix a bug in handling ack delays < PPTP_MIN_ACK_DELAY. Before,
we were ack'ing immediately. Instead, just impose a minimum ack delay
time, like the name of the macro implies.

MFC after: 1 week

22 years agoDon't allow one to trace an ancestor when already traced.
Alfred Perlstein [Sun, 14 Apr 2002 17:12:55 +0000 (17:12 +0000)]
Don't allow one to trace an ancestor when already traced.

PR: kern/29741
Submitted by: Dave Zarzycki <zarzycki@FreeBSD.org>
Fix from: Tim J. Robbins <tim@robbins.dropbear.id.au>
MFC After: 2 weeks

22 years agoActually add the UDF files!
Scott Long [Sun, 14 Apr 2002 16:52:14 +0000 (16:52 +0000)]
Actually add the UDF files!

22 years agoCast a ptrdiff_t to int before using it as a printf field width.
Dag-Erling Smørgrav [Sun, 14 Apr 2002 16:44:04 +0000 (16:44 +0000)]
Cast a ptrdiff_t to int before using it as a printf field width.

22 years agoCosmetical change: remove empty line to reduce diffs to RELENG_4
Max Khon [Sun, 14 Apr 2002 16:40:11 +0000 (16:40 +0000)]
Cosmetical change: remove empty line to reduce diffs to RELENG_4

22 years agoAdd a filesystem driver for the Universal Disk Format. For more info,
Scott Long [Sun, 14 Apr 2002 16:36:49 +0000 (16:36 +0000)]
Add a filesystem driver for the Universal Disk Format.  For more info,
see http://people.freebsd.org/~scottl/udf

 MFC after: when asmodai gets the backport done
 Prodded by: phk asmodai des

22 years agoFix some warnings. Don't record logins twice in USE_PAM case. Strip
Dag-Erling Smørgrav [Sun, 14 Apr 2002 16:24:36 +0000 (16:24 +0000)]
Fix some warnings.  Don't record logins twice in USE_PAM case.  Strip
"/dev/" off the tty name before passing it to auth_ttyok or PAM.

Inspired by: dinoex
Sponsored by: DARPA, NAI Labs

22 years agoFix a witness warning when expanding a hash table. We were allocating the new
Jeff Roberson [Sun, 14 Apr 2002 13:47:10 +0000 (13:47 +0000)]
Fix a witness warning when expanding a hash table.  We were allocating the new
hash while holding the lock on a zone.  Fix this by doing the allocation
seperately from the actual hash expansion.

The lock is dropped before the allocation and reacquired before the expansion.
The expansion code checks to see if we lost the race and frees the new hash
if we do.  We really never will lose this race because the hash expansion is
single threaded via the timeout mechanism.

22 years agoProtect the initial list traversal in sysctl_vm_zone() with the uma_mtx.
Jeff Roberson [Sun, 14 Apr 2002 12:39:38 +0000 (12:39 +0000)]
Protect the initial list traversal in sysctl_vm_zone() with the uma_mtx.

22 years agoRemove the hard-coded limit of 3 bytes for EUC encodings.
Jeroen Ruigrok van der Werven [Sun, 14 Apr 2002 10:55:42 +0000 (10:55 +0000)]
Remove the hard-coded limit of 3 bytes for EUC encodings.
Satoshi NIIMI-san kindly explained that EUC does not limit the byte length to
any arbitrary number.

We now set the limit to the maximum octet length of the codeset and it is
locale-specific.

Submitted by: Yong-Jhen Hong <winard@ms11.url.com.tw>

22 years agoFix the play / record rate setting so that it actually works.
John Hay [Sun, 14 Apr 2002 10:39:59 +0000 (10:39 +0000)]
Fix the play / record rate setting so that it actually works.

The extra microphone channel capability is part of the "normal" ac97
capabilities and not an extended ac97 capability. Now recording on
codecs without a seperate mic channel works.

MFC after: 1 week

22 years agoUse VOP_GETVOBJECT instead of accessing the member directly. This fixed
Jeff Roberson [Sun, 14 Apr 2002 10:18:48 +0000 (10:18 +0000)]
Use VOP_GETVOBJECT instead of accessing the member directly.  This fixed
an issue with nullfs and NAMEI shared.

Submitted by: Alexander Kabaev

22 years agoModernize SCM ID.
David E. O'Brien [Sun, 14 Apr 2002 07:07:09 +0000 (07:07 +0000)]
Modernize SCM ID.

22 years agoDotting the i-s:
Marcel Moolenaar [Sun, 14 Apr 2002 05:37:18 +0000 (05:37 +0000)]
Dotting the i-s:
o  Use chunk instead of region when we talk about a memory range.
   Region can be confused with region register and we already
   call it chunk in machdep.c
o  Update the twiddle every 16MB

22 years agoRegen
Alan Cox [Sun, 14 Apr 2002 05:33:58 +0000 (05:33 +0000)]
Regen

22 years agoRemove the requirement that Giant be held around sigreturn().
Alan Cox [Sun, 14 Apr 2002 05:31:47 +0000 (05:31 +0000)]
Remove the requirement that Giant be held around sigreturn().

22 years agoAllow a kernel to be compiled with both SKI and acpica and still
Peter Wemm [Sun, 14 Apr 2002 04:33:41 +0000 (04:33 +0000)]
Allow a kernel to be compiled with both SKI and acpica and still
work on real hardware.  (SKI used to break the sapic probes)

22 years agoBack out rev 1.17, it breaks dependencies.
David E. O'Brien [Sun, 14 Apr 2002 04:15:34 +0000 (04:15 +0000)]
Back out rev 1.17, it breaks dependencies.
With rev 1.7 one cannot build src/bin/sh -- because make fails to create
the buildtools before trying to use them.  Actually it does compile the
buildtools into .o's before trying to use them, but not all the way into
binaries.

22 years agoRemove stale XXX comment.
John Baldwin [Sun, 14 Apr 2002 04:12:44 +0000 (04:12 +0000)]
Remove stale XXX comment.

22 years ago o Use aiocblist::fd_file in the AIO threads rather than recomputing
Alan Cox [Sun, 14 Apr 2002 03:04:19 +0000 (03:04 +0000)]
 o Use aiocblist::fd_file in the AIO threads rather than recomputing
   the file * from the calling process's descriptor table.
 o Eliminate sharing of the calling process's descriptor table
   with the AIO threads.

22 years agoCorrect markup.
Dima Dorfman [Sun, 14 Apr 2002 02:29:20 +0000 (02:29 +0000)]
Correct markup.

22 years agoFix the calculation that determines uz_maxpages. It was off for large zones.
Jeff Roberson [Sun, 14 Apr 2002 01:56:25 +0000 (01:56 +0000)]
Fix the calculation that determines uz_maxpages.  It was off for large zones.
Fortunately we have no large zones with maximums specified yet, so it wasn't
breaking anything.

Implement blocking when a zone exceeds the maximum and M_WAITOK is specified.
Previously this just failed like the old zone allocator did.  The old zone
allocator didn't support WAITOK/NOWAIT though so we should do what we
advertise.

While I was in there I cleaned up some more zalloc logic to further simplify
that code path and reduce redundant code.  This was needed to make the blocking
work properly anyway.

22 years agoClean up the 1/2 a** committing from Thu, 3 May 2001 11:05:39 -0700 (PDT).
David E. O'Brien [Sun, 14 Apr 2002 01:30:20 +0000 (01:30 +0000)]
Clean up the 1/2 a** committing from Thu, 3 May 2001 11:05:39 -0700 (PDT).
Since then we have living with a GPL'ed find(1) due to grabbing getdate.y
from src/contrib/cvs and its user of the GPL'ed xtime.h.  I don't even want
to think about how this could have affected people using our source base.

Would it have been too much trouble to do then what I did now?
Copied getdate.y (public domain) to usr.bin/find and change to use
standard system headers.  find(1) now compiles simply with out having
to go to extra effort to do so.

Pointed hat to: phk
Build fixed on: gcc 3.1 using platforms

22 years agoDo not use perl where sed is more than adequate.
David E. O'Brien [Sat, 13 Apr 2002 23:53:36 +0000 (23:53 +0000)]
Do not use perl where sed is more than adequate.

22 years agoAdd comment that sigreturn() is MPSAFE.
Alan Cox [Sat, 13 Apr 2002 23:37:10 +0000 (23:37 +0000)]
Add comment that sigreturn() is MPSAFE.

22 years ago- Change killpg1()'s first argument to be a thread instead of a process so
John Baldwin [Sat, 13 Apr 2002 23:33:36 +0000 (23:33 +0000)]
- Change killpg1()'s first argument to be a thread instead of a process so
  we can use td_ucred.
- In killpg1(), the proc lock is sufficient to check if p_stat is SZOMB
  or not.  We don't need sched_lock.
- Close some races in psignal().  In psignal() there is a big switch
  statement based on p_stat.  All the different cases are assuming that
  the process (or thread) isn't going to change state out from under it.
  To ensure this is true, just lock sched_lock for the entire switch.  We
  practically held it the entire time already anyways.  This also
  simplifies the locking somewhat and actually results in fewer lock
  operations.
- Allow signotify() to be called with the sched_lock held since psignal()
  now does that.
- Use td_ucred in a couple of places.

22 years agoRemove bogus dependency on rlogin.
Dag-Erling Smørgrav [Sat, 13 Apr 2002 23:31:27 +0000 (23:31 +0000)]
Remove bogus dependency on rlogin.

22 years ago- Change donice() to take a thread as the first argument instead of a
John Baldwin [Sat, 13 Apr 2002 23:28:23 +0000 (23:28 +0000)]
- Change donice() to take a thread as the first argument instead of a
  process so it can use td_ucred.
- Require the target process of donice() to be locked when donice() is
  called.
- Use td_ucred.
- Lock the target process of p_cansee() and while reading the credentials
  of a process.
- Change the logic of rtprio() slightly so it does it's copyin() if needed
  prior to locking the target process.
- rtprio() no longer needs Giant.  In theory with full KSE it would still
  need Giant to protect p_ucred of curproc for the p_canfoo() functions
  but p_canfoo() will be changing to using td_ucred of curthread before
  full KSE hits the tree.

22 years ago- Change procfs_control()'s first argument to be a thread pointer instead
John Baldwin [Sat, 13 Apr 2002 23:19:13 +0000 (23:19 +0000)]
- Change procfs_control()'s first argument to be a thread pointer instead
  of a process pointer.
- Move the p_candebug() at the start of procfs_control() a bit to make
  locking feasible.  We still perform the access check before doing
  anything, we just now perform it after acquiring locks.
- Don't lock the sched_lock for TRACE_WAIT_P() and when checking to see if
  p_stat is SSTOP.  We lock the process while setting p_stat to SSTOP
  so locking the process is sufficient to do a read to see if p_stat is
  SSTOP or not.

22 years agoLock the target process for p_candebug().
John Baldwin [Sat, 13 Apr 2002 23:15:28 +0000 (23:15 +0000)]
Lock the target process for p_candebug().

22 years agoLock the target process in procfs_doproc*regs() for p_candebug and while
John Baldwin [Sat, 13 Apr 2002 23:14:08 +0000 (23:14 +0000)]
Lock the target process in procfs_doproc*regs() for p_candebug and while
reading/writing the registers.

22 years agoRework logic of syscalls that modify process credentials as described in
John Baldwin [Sat, 13 Apr 2002 23:11:23 +0000 (23:11 +0000)]
Rework logic of syscalls that modify process credentials as described in
rev 1.152 of sys/kern/kern_prot.c.

22 years ago- p_cansee() needs the target process locked.
John Baldwin [Sat, 13 Apr 2002 23:09:41 +0000 (23:09 +0000)]
- p_cansee() needs the target process locked.
- We need the proc lock held for more of procfs_doprocstatus().

22 years ago- Change the algorithms of the syscalls to modify process credentials to
John Baldwin [Sat, 13 Apr 2002 23:07:05 +0000 (23:07 +0000)]
- Change the algorithms of the syscalls to modify process credentials to
  allocate a blank cred first, lock the process, perform checks on the
  old process credential, copy the old process credential into the new
  blank credential, modify the new credential, update the process
  credential pointer, unlock the process, and cleanup rather than trying
  to allocate a new credential after performing the checks on the old
  credential.
- Cleanup _setugid() a little bit.
- setlogin() doesn't need Giant thanks to pgrp/session locking and
  td_ucred.

22 years ago- Change the first argument of ktrcanset(), ktrsetchildren(), and ktrops()
John Baldwin [Sat, 13 Apr 2002 22:54:18 +0000 (22:54 +0000)]
- Change the first argument of ktrcanset(), ktrsetchildren(), and ktrops()
  to a thread pointer so that ktrcanset() can use td_ucred.
- Add some proc locking to partially protect p_tracep and p_traceflag.

22 years agoTurn on TGA support.
David E. O'Brien [Sat, 13 Apr 2002 22:34:16 +0000 (22:34 +0000)]
Turn on TGA support.

Submitted by: Andrew M. Miklic <AndrwMklc@cs.com>