]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
18 years agoDo not touch ifp->if_baudrate in miibus aware drivers.
glebius [Tue, 14 Feb 2006 12:44:56 +0000 (12:44 +0000)]
Do not touch ifp->if_baudrate in miibus aware drivers.

18 years agoRemoved the frobbing of CPU percentages from > 99.9 to 99.9. Rev.1.35
bde [Tue, 14 Feb 2006 12:26:51 +0000 (12:26 +0000)]
Removed the frobbing of CPU percentages from > 99.9 to 99.9.  Rev.1.35
made it unnecessary.  (Rev.1.6 had to reduce the field width to 4, and
changed 100.0 and preposterous larger values down to 99.9 since 100.0
wouldn't have fitted.  Rev.1.35 handles precentages > 99.9 well enough by
changing the format to %.0f when the string given by the initial format
is too wide.)

Even with this change, during short testing I've never seen a percentage
of 100 being displayed by systat -v, although top(1) displays percentages
of 100 user or 100 idle for similar loads.

18 years ago- Introduce ifmedia_baudrate(), which returns correct baudrate of the
glebius [Tue, 14 Feb 2006 12:10:03 +0000 (12:10 +0000)]
- Introduce ifmedia_baudrate(), which returns correct baudrate of the
  given media status. [1]
- Utilize ifmedia_baudrate() in miibus_statchg() to update ifp->if_baudrate.

Obtained from: NetBSD [1]

18 years agoFix some minor bugs:
bde [Tue, 14 Feb 2006 11:57:02 +0000 (11:57 +0000)]
Fix some minor bugs:

Always use snprintf()'s return value, since discarding it is a style
bug at best and using it here gives slightly simpler code and better
error checking.  Use snprintf() in putlongdouble() the same as in
putfloat().  (1.25 changed most sprintf()'s to snprintf()'s to fix
non-bugs without changing the logic to use the result of snprintf();
1.27 restored one of the sprintf()s by cloning a stale version of
putfloat().)

Don't print a too-long field in the unlikely case that the fallback
to M units in putint() leaves the field still too long.  (The fallback
to printing stars was lost in rev.1.58 when the fallback to M units
was added.)

18 years agoAdd '-F' option which allows to delete existing empty directories, when
glebius [Tue, 14 Feb 2006 11:08:05 +0000 (11:08 +0000)]
Add '-F' option which allows to delete existing empty directories, when
creating symbolic links.

PR: bin/92149
Submitted by: Eugene Grosbein <eugen grosbein.pp.ru>

18 years agoReduce the field width by 1 for many numeric fields so that most fields
bde [Tue, 14 Feb 2006 10:47:36 +0000 (10:47 +0000)]
Reduce the field width by 1 for many numeric fields so that most fields
cannot run into other fields or field descriptors.  If the value is
too large to fit in the field width, then the output format is adjusted
so that the value (usually) fits, but with fields running together
externally this adjustment usually didn't help.  Mostly it doesn't
matter to lose 1 digit of precision, but switching the output format
is bad if it happens often or gives bogus units.  The loss of width
is most serious for fields near "Csw" (which are also the ones which
must often ran together) since these have a high variance and large
values relative to the possible field widths so the switch occurs more
often now, and for the memory size fields where the switch gives the
bogus units kKB or MKB.

Now only the fields for r, p, d, s and w can run into each other.
These fields have width 3, and 3 cannot be reduced to 2 without losing
all precision when the value is between 100 and 999.

Trim "pdwake" to "pdwak" at think time now that it doesn't get clobbered
at runtime.  The manpage doesn't need to be changed for this because
it documents the clobbered descriptor, unlike for 4 other too-long
descriptors which only get clobbered if there are lots of interrupt
sources.

Trim "% busy" to "%busy" since most other descriptors for percentages
are spelled without the space and this change makes changing the widths
of the %busy fields unnecessary.

18 years agoOops, the "excessive" {} removed in the previous commit was needed
bde [Tue, 14 Feb 2006 09:33:51 +0000 (09:33 +0000)]
Oops, the "excessive" {} removed in the previous commit was needed
around PUTRATE() because PUTRATE() only looked like a function -- it was
multiple statements.  Use "do {...} while(0)" as usual in PUTRATE() so
that it is a single statement that can be used like a function.

18 years agoDisconnect bsnmp from the build until the breakage is sorted out.
harti [Tue, 14 Feb 2006 08:34:26 +0000 (08:34 +0000)]
Disconnect bsnmp from the build until the breakage is sorted out.

18 years agoFixed all (?) bitrot in the comments about the number of columns used by
bde [Tue, 14 Feb 2006 08:33:02 +0000 (08:33 +0000)]
Fixed all (?) bitrot in the comments about the number of columns used by
various groups of fields.

18 years agoFix all (?) cases where the field width of a numeric field was far too
bde [Tue, 14 Feb 2006 07:44:21 +0000 (07:44 +0000)]
Fix all (?) cases where the field width of a numeric field was far too
large.  In most cases it is still 1 too large, so fields tend to run
together, but in the following cases it was more than 1 too large, and
the starting column was too small too, so the field started inside the
previous field or descriptor and clobbered that:
- "wire": the number for this overwrote 2 characters of the number for
  "Flt".  Reduce the field width by 3 (2 to avoid the overwrite and 1
  so that the fields don't run together).  This was already done for
  the preceding number for "cow".
- "inact": the number for this overwrote 1 character of the descriptor
  "Idle".  Reducing the field width by 2 is enough.
- "cache:" the number for this overwrote 3 characters of the scale
  "...|    |".  The field width should be reduced by 4 to keep things
  from running together, but that is a lot and not so necessary here
  since the final "|" in the scale serves as a delimiter.  Only reduce
  it by 3.
- "free": the number for this overwrote 2 characters of the bar graph.
  The character position under the final "|" in the scale is apparently
  not used, so reducing the field width by 3 is enough.

When "zfod" is in the main vmstat display:
- use the normal field width of 9 (not 5) for it since there is no shortage
  of space.  Fix style bugs (excessive {}) in the statement that
  conditionally writes it.

Write all reduced field widths for vmstat fields as "9 - <reduction>" as
a hint that we don't want to reduce them.

18 years agoWhen sending a packet from dummynet, indicate that we're forwarding
ru [Tue, 14 Feb 2006 06:36:39 +0000 (06:36 +0000)]
When sending a packet from dummynet, indicate that we're forwarding
it so that ip_id etc. don't get overwritten.  This fixes forwarding
of fragmented IP packets through a dummynet pipe -- fragments came
out with modified and different(!) ip_id's, making it impossible to
reassemble a datagram at the receiver side.

Submitted by: Alexander Karptsov (reworked by me)
MFC after: 3 days

18 years agoFixed style bugs in rev.1.12. Rev.1.12 arranged to display the interrupt
bde [Tue, 14 Feb 2006 05:37:25 +0000 (05:37 +0000)]
Fixed style bugs in rev.1.12.  Rev.1.12 arranged to display the interrupt
number in more cases by stealing 2 characters from the count field to
give more space in the descriptor field, but it did the column adjustments
for this strangely using an off-by-2 error in the base column and
compensating off-by-2 errors in 6 offsets from the base column (4 new
errors and 2 from not changing the offsets that actually changed).

Print the "Interrupts" header directly at its offset from the base column
instead of spacing it half using the offset and half by printing a space
character.

18 years agoRemove vestiges of OLDCARD.
imp [Tue, 14 Feb 2006 04:16:56 +0000 (04:16 +0000)]
Remove vestiges of OLDCARD.

18 years agoMinor fixes to the code that generates an internal ustar filename
kientzle [Tue, 14 Feb 2006 04:05:03 +0000 (04:05 +0000)]
Minor fixes to the code that generates an internal ustar filename
for Pax extended attribute entries.

18 years agoExtract device number information from SVR4 CPIO archives.
kientzle [Tue, 14 Feb 2006 04:00:14 +0000 (04:00 +0000)]
Extract device number information from SVR4 CPIO archives.
Without this, you cannot properly restore device node entries
from such archives.

Thanks to: Steve 'dillo Okay for reporting this oversight.

18 years agooops, mismerge from working sources.. not only add new code,
julian [Tue, 14 Feb 2006 03:13:12 +0000 (03:13 +0000)]
oops, mismerge from working sources.. not only add new code,
but remove old code!

18 years agoStop ipfw from aborting when asked to delete a table entry that
julian [Tue, 14 Feb 2006 03:10:29 +0000 (03:10 +0000)]
Stop ipfw from aborting when asked to delete a table entry that
doesn't exist or add one that is already present, if the -q flag
is set. Useful for "ipfw -q /dev/stdin" when the command above is
invoked from  something like python or TCL to feed commands
down the throat of ipfw.
MFC in: 1 week

18 years agoAudit the arguments to the ptrace(2) system call.
wsalamon [Tue, 14 Feb 2006 01:18:31 +0000 (01:18 +0000)]
Audit the arguments to the ptrace(2) system call.

Obtained from: TrustedBSD Project
Approved by: rwatson (mentor)

18 years agoAudit the arguments to the kill(2) and killpg(2) system calls.
wsalamon [Tue, 14 Feb 2006 01:17:03 +0000 (01:17 +0000)]
Audit the arguments to the kill(2) and killpg(2) system calls.

Obtained from: TrustedBSD Project
Approved by: rwatson (mentor)

18 years agoThe change to make column use roundup(x, TAB) rounded things to the
dwmalone [Mon, 13 Feb 2006 22:09:26 +0000 (22:09 +0000)]
The change to make column use roundup(x, TAB) rounded things to the
current tab, however the code it replaced wanted to round to the
next TAB. Consequently things like this:

( echo 1 ; echo 2 ) | column

cause column to loop indefinitely. This patch is slightly different
from the one Gary submitted, but is closer to the original code.

Submitted by: Gary Cody <gary@lyranthe.org>
MFC after: 1 week

18 years agoOn ia64, the unaligned_print sysctl is a debugging knob under debug
marcel [Mon, 13 Feb 2006 21:41:32 +0000 (21:41 +0000)]
On ia64, the unaligned_print sysctl is a debugging knob under debug
and not under machdep as the behaviour is controlled by the process.
When PSR.ac is set the process expects to receive a SIGBUS. Otherwise
the processor or the kernel will emulate the misaligned memory access.

MFC after: 3 days

18 years ago.Pp before .Sh is redundant.
joel [Mon, 13 Feb 2006 21:34:19 +0000 (21:34 +0000)]
.Pp before .Sh is redundant.

Reviewed by: ru

18 years agoFix leakage of uncommitted build changes
imp [Mon, 13 Feb 2006 21:25:01 +0000 (21:25 +0000)]
Fix leakage of uncommitted build changes

18 years agoAdd a default ldconfig32_paths entry in default/rc.conf for 32-bit compatability...
matteo [Mon, 13 Feb 2006 21:10:03 +0000 (21:10 +0000)]
Add a default ldconfig32_paths entry in default/rc.conf for 32-bit compatability shared libraries.
It is used by the ldconfig rc.d scripts.
Document this variable in the man page

PR: amd64/91571
Approved by: philip (mentor)
MFC after: 3

18 years agos/lp/plip/ for PLIP interfaces.
ceri [Mon, 13 Feb 2006 20:49:32 +0000 (20:49 +0000)]
s/lp/plip/ for PLIP interfaces.

Approved by: jhb
MFC after: 1 week

18 years agoThe interface for PLIP has been plip0 rather than lp0 for a long time.
ceri [Mon, 13 Feb 2006 20:47:43 +0000 (20:47 +0000)]
The interface for PLIP has been plip0 rather than lp0 for a long time.
Update to match.

18 years agoRemove pccard variables which are no longer supported after the move
imp [Mon, 13 Feb 2006 20:10:34 +0000 (20:10 +0000)]
Remove pccard variables which are no longer supported after the move
to NEWCARD.

18 years agoSince OLDCARD is gone from the kernel, catchup here and remove support
imp [Mon, 13 Feb 2006 20:08:31 +0000 (20:08 +0000)]
Since OLDCARD is gone from the kernel, catchup here and remove support
from here as well.

18 years agofix comment and whitespace
sam [Mon, 13 Feb 2006 18:40:53 +0000 (18:40 +0000)]
fix comment and whitespace

18 years agofix merge botch (duplicate processing of cabq for old cards)
sam [Mon, 13 Feb 2006 18:23:32 +0000 (18:23 +0000)]
fix merge botch (duplicate processing of cabq for old cards)

18 years agoTie the ipmi driver into the i386/amd64 builds.
ambrisko [Mon, 13 Feb 2006 17:56:24 +0000 (17:56 +0000)]
Tie the ipmi driver into the i386/amd64 builds.

18 years agoUse a wildcard unit (-1) to device_find_child() in our identify routine to
jhb [Mon, 13 Feb 2006 17:53:39 +0000 (17:53 +0000)]
Use a wildcard unit (-1) to device_find_child() in our identify routine to
match the wildcard unit passed to BUS_ADD_CHILD().

18 years agoDon't conflict with the DEBUG define.
ambrisko [Mon, 13 Feb 2006 16:50:45 +0000 (16:50 +0000)]
Don't conflict with the DEBUG define.

18 years agoLink the new file from the vendor fix to the build and install
harti [Mon, 13 Feb 2006 14:12:15 +0000 (14:12 +0000)]
Link the new file from the vendor fix to the build and install
the new MIB files. Add a target to smilint the MIB files.

18 years agoThis commit was generated by cvs2svn to compensate for changes in r155602,
harti [Mon, 13 Feb 2006 14:11:18 +0000 (14:11 +0000)]
This commit was generated by cvs2svn to compensate for changes in r155602,
which included commits to RCS files with non-trunk default branches.

18 years agoVendor fix: make mibII HC counters really 64-bit on 32-bit platforms by polling
harti [Mon, 13 Feb 2006 14:11:18 +0000 (14:11 +0000)]
Vendor fix: make mibII HC counters really 64-bit on 32-bit platforms by polling
the kernel periodically.

Submitted by: glebius (partly)

18 years agoAdd a reset of the AHCI machinery to the ICH6/ICH7 support.
sos [Mon, 13 Feb 2006 13:47:58 +0000 (13:47 +0000)]
Add a reset of the AHCI machinery to the ICH6/ICH7 support.
This should fix the missed devices on some systems.

18 years agoOverhaul the named boot script:
dougb [Mon, 13 Feb 2006 08:45:51 +0000 (08:45 +0000)]
Overhaul the named boot script:

1. Remove a now-spurious NetBSD CVS Id, as we are no longer synching work
2. Remove a now-spurious BEFORE, since ntpdate now REQUIRE's named
3. Replace the call to set rcvar with what that function would output,
and generally reduce indirection ($name -> named) since it's highly
unlikely the name of the named process or service will change any time soon.
4. Resort the order the variables at the top of the file to a more
traditional format, and remove a spurious required_dirs from the top, as it
works better after load_rc_config.
5. We do not want the default reload method with named, so define a simple
but appropriate substitute using rndc. If I were writing this script for
the first time I would not include this at all, since it's preferable to
control a running daemon with rndc to start with, but given that this is
already here, let's do it right. I hope that future generations will
however resist the tempation to add reconfig to extra_commands.
6. By the same token, we want to use rndc to shut down named, but given
that by defining a stop function we lose the "find the process by its
pid file in an emergency" goodness of rc.subr, try to do something useful
in the event that rndc is not available, and keep the user informed.
7. Replace some "test -f" with "test -r" to handle the unlikely event
that the relevant file exists, but is unreadable.
8. Twiddle whitespace in a few areas, remove a spurious blank line,
a bogus double space, and try to do better indenting.
9. Improve generation of the rndc.key file significantly
a. If for some reason a user has an rndc.conf file, assume that they
did that on purpose, and hence know what they are doing, so leave them alone.
b. Introduce a named_uid configuration variable so that the user which owns
the rndc.key file and the user named runs as always match, and is more
easily configurable. This should dramatically reduce problems with rndc.
c. Also test that the rndc.key file size is greater than zero, rather than
simply that the file exists. I have seen at least one user report this exact
problem, and although neither of us is sure where the empty file came from,
the fix is simple, so include it.
d. Rather than try to create an rndc.key file in both /etc/namedb and the
chroot'ed /etc/namedb, assume that they are be the same (which they should
be), and only create the file in the chroot'ed version of the directory.
This partially addresses the problem described in conf/73929, but I have
not yet finished thinking about the PREFIX issue that PR also raises.

As a result of introducing the named_uid knob, the default named_flags
are now empty.

Update defaults/rc.conf and rc.conf(5) to reflect these changes.

18 years agoIn order to speed up process suspension on MP machine, send IPI to
davidxu [Mon, 13 Feb 2006 03:16:55 +0000 (03:16 +0000)]
In order to speed up process suspension on MP machine, send IPI to
remote CPU. While here, abstract thread suspension code into a function
called sig_suspend_threads, the function is called when a process received
a STOP signal.

18 years agoRemove extra slash from pty slave device name returned by ptsname.
kan [Mon, 13 Feb 2006 00:04:04 +0000 (00:04 +0000)]
Remove extra slash from pty slave device name returned by ptsname.

18 years ago- Use consistent capitalization for ThinkLight
brueffer [Sun, 12 Feb 2006 22:07:30 +0000 (22:07 +0000)]
- Use consistent capitalization for ThinkLight
- Xref led(4)

MFC after: 3 days

18 years agos/asynchronuous/asynchronous/
joel [Sun, 12 Feb 2006 21:10:27 +0000 (21:10 +0000)]
s/asynchronuous/asynchronous/

18 years agos/specfic/specific/
joel [Sun, 12 Feb 2006 21:06:14 +0000 (21:06 +0000)]
s/specfic/specific/

18 years agoDocument NO_AUDIT.
brueffer [Sun, 12 Feb 2006 19:56:01 +0000 (19:56 +0000)]
Document NO_AUDIT.

Obtained from: TrustedBSD Project

18 years agoEnable SWIDTH.
ume [Sun, 12 Feb 2006 17:56:16 +0000 (17:56 +0000)]
Enable SWIDTH.
It makes tcsh(1) work correctly with ja_JP.SJIS locale.

MFC after: 1 week

18 years agoOn component state change to ACTIVE don't forget to update metadata.
pjd [Sun, 12 Feb 2006 17:38:09 +0000 (17:38 +0000)]
On component state change to ACTIVE don't forget to update metadata.

MFC after: 3 days

18 years agoUse time_uptime instead of time_second, as the latter may go backwards.
pjd [Sun, 12 Feb 2006 17:36:09 +0000 (17:36 +0000)]
Use time_uptime instead of time_second, as the latter may go backwards.

Suggested by: ru
MFC after: 3 days

18 years agoTypo: s/fint/find/
glebius [Sun, 12 Feb 2006 17:32:59 +0000 (17:32 +0000)]
Typo: s/fint/find/

18 years agoDocument NO_AUDIT make variable.
csjp [Sun, 12 Feb 2006 17:06:14 +0000 (17:06 +0000)]
Document NO_AUDIT make variable.

Obtained from: TrustedBSD Project

18 years agoThe wcwidth(3) should return 2 about characters in JISX0208 codeset.
ume [Sun, 12 Feb 2006 16:13:42 +0000 (16:13 +0000)]
The wcwidth(3) should return 2 about characters in JISX0208 codeset.
But it returned 1.
It fixes the problem reported by many Japanese people that tcsh 6.14
doesn't work correctly with ja_JP.eucJP locale.

PR: conf/79701
Submitted by: Kazuaki Oda <ybbkaz__at__yahoo.co.jp>
Tested by: many people
MFC after: 1 week

18 years agoFix pkg_version with the -o argument to print the origin.
krion [Sun, 12 Feb 2006 16:09:33 +0000 (16:09 +0000)]
Fix pkg_version with the -o argument to print the origin.

Submitted by: Sebastian Stach <sebsta AT t-online DOT de>
MFC after: 3 days

18 years agoAdd USB polling calls to umass_cam_poll(). This appears to be enough
iedowse [Sun, 12 Feb 2006 15:51:03 +0000 (15:51 +0000)]
Add USB polling calls to umass_cam_poll(). This appears to be enough
to make kernel crash dumps to umass devices work, at least in some
cases.

18 years agoavoided the use of purged address structure when an address became
ume [Sun, 12 Feb 2006 15:37:08 +0000 (15:37 +0000)]
avoided the use of purged address structure when an address became
invalid in nd6_timer().

PR: kern/93170
Reported by: kris
Submitted by: JINMEI Tatuya <jinmei__at__isl.rdc.toshiba.co.jp>
Confirmed by: kris
Obtained from: KAME
MFC after: 2 days

18 years agoImprove consistency of return() style.
rwatson [Sun, 12 Feb 2006 15:00:27 +0000 (15:00 +0000)]
Improve consistency of return() style.

MFC after: 3 days

18 years agoIn quotaoff(), lock the vnode instead of asserting it when manipulating
rwatson [Sun, 12 Feb 2006 13:20:06 +0000 (13:20 +0000)]
In quotaoff(), lock the vnode instead of asserting it when manipulating
v_vflags.

MFC after: 1 week
Submitted by: Antoine Brodin <antoine at brodin at laposte dot net>

18 years agoInstall audit_control and audit_user, both of which are likely to be
rwatson [Sun, 12 Feb 2006 13:01:39 +0000 (13:01 +0000)]
Install audit_control and audit_user, both of which are likely to be
modified by the administrator, as user-writable instead of read-only.

Obtained from: TrustedBSD Project

18 years agoDon't include geli devices in list when noauto is specified in the options field.
flz [Sun, 12 Feb 2006 12:57:07 +0000 (12:57 +0000)]
Don't include geli devices in list when noauto is specified in the options field.

Approved by: pjd
MFC after: 3 days

18 years agoFix possible DMA leak and locking violation especially
ariff [Sun, 12 Feb 2006 10:42:47 +0000 (10:42 +0000)]
Fix possible DMA leak and locking violation especially
during suspend <-> resume and module load <-> unload.

PR: kern/92764
MFC after: 3 days

18 years agoDefault number of direct access devices had been changed from three to two.
marck [Sun, 12 Feb 2006 10:30:52 +0000 (10:30 +0000)]
Default number of direct access devices had been changed from three to two.
Reflect this in other paragraphs.

PR: 93201
Submitted by: Marian Cerny
MFC After: 1 week

18 years agoMake localpkg print local scripts names when the boot is verbose
matteo [Sun, 12 Feb 2006 10:04:56 +0000 (10:04 +0000)]
Make localpkg print local scripts names when the boot is verbose

PR: conf/68525
Approved by: philip (mentor)
MFC after: 3 days

18 years agos/Februari/February/.
joel [Sun, 12 Feb 2006 07:57:27 +0000 (07:57 +0000)]
s/Februari/February/.

18 years agoDocument the two argument form of the "machine" directive.
jkoshy [Sun, 12 Feb 2006 07:56:11 +0000 (07:56 +0000)]
Document the two argument form of the "machine" directive.

Reviewed by: imp
MFC After: 3 days

18 years agoHook audit into OpenSSH. Now that the necessary bits for OpenSSH support
csjp [Sun, 12 Feb 2006 07:19:45 +0000 (07:19 +0000)]
Hook audit into OpenSSH. Now that the necessary bits for OpenSSH support
have been added with the latest OpenBSM import, hook USE_BSM_AUDIT into
build conditionally.

For users which do not care for audit support and do not want to compile
it into their SSH servers, add the following to the /etc/make.conf:

NO_AUDIT=true

Discussed with: rwatson
Obtained from: TrustedBSD Project

18 years agoGive the asr softc list global a proper name.
scottl [Sun, 12 Feb 2006 06:57:41 +0000 (06:57 +0000)]
Give the asr softc list global a proper name.

18 years agoAdd regression test which verifies that options -P and -i cannot be used
pjd [Sun, 12 Feb 2006 02:07:56 +0000 (02:07 +0000)]
Add regression test which verifies that options -P and -i cannot be used
together.

MFC after: 3 days

18 years agoAllow to set kern.geom.raid3.disconnect_on_failure from loader.conf.
pjd [Sun, 12 Feb 2006 02:01:38 +0000 (02:01 +0000)]
Allow to set kern.geom.raid3.disconnect_on_failure from loader.conf.

MFC after: 3 days

18 years agoAdd stub AUE_EACCESS entry.
rwatson [Sat, 11 Feb 2006 23:55:08 +0000 (23:55 +0000)]
Add stub AUE_EACCESS entry.

Obtained from: TrustedBSD Project

18 years agoInitialize user process audit ID to AU_DEFAUDITID so that init and
rwatson [Sat, 11 Feb 2006 23:53:00 +0000 (23:53 +0000)]
Initialize user process audit ID to AU_DEFAUDITID so that init and
its pre-authentication children are covered by naflags.

Obtained from: TrustedBSD Project

18 years agoAdd a simple manpage.
marcel [Sat, 11 Feb 2006 23:09:58 +0000 (23:09 +0000)]
Add a simple manpage.

18 years agoSort sfbuf allocation counters with other sfbuf information.
rwatson [Sat, 11 Feb 2006 21:27:16 +0000 (21:27 +0000)]
Sort sfbuf allocation counters with other sfbuf information.

MFC after: 3 days

18 years agoInstead of asserting the vnode lock before manipulating v_vflag, acquire
rwatson [Sat, 11 Feb 2006 21:09:27 +0000 (21:09 +0000)]
Instead of asserting the vnode lock before manipulating v_vflag, acquire
it and drop it afterwards.

Found by: kris
MFC after: 1 week

18 years agoDon't count output bytes twice (the byte accouting is done
ru [Sat, 11 Feb 2006 20:25:00 +0000 (20:25 +0000)]
Don't count output bytes twice (the byte accouting is done
in if.c).  Count output errors.

MFC after: 3 days

18 years agoCorrect the spinlock nesting of the idle thread of the APs before we
marcel [Sat, 11 Feb 2006 19:55:18 +0000 (19:55 +0000)]
Correct the spinlock nesting of the idle thread of the APs before we
save the MCA state of the AP. Saving the MCA state of the AP requires
us to allocate memory, which uses sleep locks.
Now that we correct the spinlock nesting of the AP without having
schedlock, avoid calling spinlock_exit(). Instead call critical_exit()
and manually clear the MD spinlock count.

MFC after: 3 days

18 years agoUpdate copyright for 2006.
rwatson [Sat, 11 Feb 2006 19:21:39 +0000 (19:21 +0000)]
Update copyright for 2006.

MFC after: 3 days

18 years agoSkip per-cpu caches associated with absent CPUs when generating a
rwatson [Sat, 11 Feb 2006 19:20:56 +0000 (19:20 +0000)]
Skip per-cpu caches associated with absent CPUs when generating a
memory statistics record stream via sysctl.

MFC after: 3 days

18 years agoThe uma_zone data structure defines the size of its uz_cpu[] array as 1,
rwatson [Sat, 11 Feb 2006 19:19:29 +0000 (19:19 +0000)]
The uma_zone data structure defines the size of its uz_cpu[] array as 1,
but then sizes the containing data structure at run-time to make room
for per-cpu cache data.  Modify libmemstat to separately allocate a
buffer to hold per-cpu cache data, sized based on the run-time mp_maxid
variable when using libkvm to access UMA data.  This avoids reading
invalid cache data from beyond the end of the uma_zone data structure
on the stack, which can result in invalid statistics and/or reads from
invalid kernel addresses.

Foot target practice by: ps
MFC after: 3 days

18 years agoWhen reporting an error reading from UMA per-cpu cache pointers using KVM,
rwatson [Sat, 11 Feb 2006 18:55:03 +0000 (18:55 +0000)]
When reporting an error reading from UMA per-cpu cache pointers using KVM,
return a KVM error rather than an out of memory error, so that the caller
reports the KVM error state.  This replaces a misleading error message
with a more accurate although equally confusing one.

MFC after: 3 days

18 years agoRead all_cpus variable out of kmem, and validate CPUs against the all_cpus
rwatson [Sat, 11 Feb 2006 18:44:37 +0000 (18:44 +0000)]
Read all_cpus variable out of kmem, and validate CPUs against the all_cpus
cpu mask before looking at the cache entries for the CPU.  For systems
with sparse CPU id arrays, this skips otherwise uninitialized cache
structures.

MFC after: 3 days

18 years ago- Add kern.geom.raid3.disconnect_on_failure sysctl/tunnable (default to 1
pjd [Sat, 11 Feb 2006 17:42:31 +0000 (17:42 +0000)]
- Add kern.geom.raid3.disconnect_on_failure sysctl/tunnable (default to 1
  to preserve currect behaviour). When set to 0, components are not
  disconnected - graid3 will try to still use them (only first error will
  be logged). This is helpful when we have two broken components, but in
  different places, so actually all data is available.
  Such buggy component will be visible in 'graid3 list' output with flag
  BROKEN.
- Never disconnect the last valid component. If we detect errors there we
  will just pass them up. This wasn't reasonable to deny access to the
  whole provider because of one broken sector.

Prodded by: ru
MFC after: 3 days

18 years ago- Add kern.geom.mirror.disconnect_on_failure sysctl/tunnable (default to 1
pjd [Sat, 11 Feb 2006 17:39:29 +0000 (17:39 +0000)]
- Add kern.geom.mirror.disconnect_on_failure sysctl/tunnable (default to 1
  to preserve currect behaviour). When set to 0, components are not
  disconnected - gmirror will try to still use them (only first error will
  be logged). This is helpful when we have two broken components, but in
  different places, so actually all data is available.
  Such buggy component will be visible in 'gmirror list' output with flag
  BROKEN.
- Never disconnect the last valid component. If we detect errors there we
  will just pass them up. This wasn't reasonable to deny access to the
  whole provider because of one broken sector.

Prodded by: ru
MFC after: 3 days

18 years agoCorrect typo. 'fbp' is NULL here so this will result in a panic.
pjd [Sat, 11 Feb 2006 17:29:06 +0000 (17:29 +0000)]
Correct typo. 'fbp' is NULL here so this will result in a panic.

MFC after: 3 days

18 years agoUn-#if 0 the printing of allocation failure counts for mbufs, clusters,
rwatson [Sat, 11 Feb 2006 17:18:36 +0000 (17:18 +0000)]
Un-#if 0 the printing of allocation failure counts for mbufs, clusters,
and packets in netstat -m.

MFC after: 3 days

18 years agoCorrect a typo in the extraction of zone information from UMA using kmem:
rwatson [Sat, 11 Feb 2006 16:54:00 +0000 (16:54 +0000)]
Correct a typo in the extraction of zone information from UMA using kmem:
bytes = allocated - freed, not bytes = allocated = freed.

MFC after: 3 days

18 years ago- Grammar fixes
markus [Sat, 11 Feb 2006 15:36:37 +0000 (15:36 +0000)]
- Grammar fixes
- Reword one sentence

Approved by: brueffer
MFC after: 3 days

18 years agoMark array as CLEAN when there are no write requests in
pjd [Sat, 11 Feb 2006 14:42:58 +0000 (14:42 +0000)]
Mark array as CLEAN when there are no write requests in
kern.geom.raid3.idletime seconds. Write, not any requests.
Mark array as clean immediatelly on last write close.

Prodded by: ru
MFC after: 3 days

18 years agoMark array as CLEAN when there are no write requests in
pjd [Sat, 11 Feb 2006 14:42:23 +0000 (14:42 +0000)]
Mark array as CLEAN when there are no write requests in
kern.geom.mirror.idletime seconds. Write, not any requests.
Mark array as clean immediatelly on last write close.

Prodded by: ru
MFC after: 3 days

18 years agoAdd an example how to use keyfiles for encrypted providers which should be
pjd [Sat, 11 Feb 2006 13:18:47 +0000 (13:18 +0000)]
Add an example how to use keyfiles for encrypted providers which should be
attached before the root file system is mounted.

MFC after: 3 days

18 years agoTeach geli how to load keyfiles before root file system is mounted.
pjd [Sat, 11 Feb 2006 13:08:24 +0000 (13:08 +0000)]
Teach geli how to load keyfiles before root file system is mounted.
An example entries for loader.conf to make it possible:

geli_da0_keyfile0_load="YES"
geli_da0_keyfile0_type="da0:geli_keyfile0"
geli_da0_keyfile0_name="/boot/keys/da0.key0"
geli_da0_keyfile1_load="YES"
geli_da0_keyfile1_type="da0:geli_keyfile1"
geli_da0_keyfile1_name="/boot/keys/da0.key1"
geli_da0_keyfile2_load="YES"
geli_da0_keyfile2_type="da0:geli_keyfile2"
geli_da0_keyfile2_name="/boot/keys/da0.key2"

geli_da1s3a_keyfile0_load="YES"
geli_da1s3a_keyfile0_type="da1s3a:geli_keyfile0"
geli_da1s3a_keyfile0_name="/boot/keys/da1s3a.key"

Thanks for jhb and kan who showed me the right direction.

MFC after: 3 days

18 years ago- Allow to use -b without passphrase or with keyfiles as it will be
pjd [Sat, 11 Feb 2006 13:04:10 +0000 (13:04 +0000)]
- Allow to use -b without passphrase or with keyfiles as it will be
  supported for a moment.
- Don't allow to use -i when no passphrase is given. Now if iterations is
  equal to -1 (not set), we know that we should not ask for the passphrase
  on boot.
  It still doesn't handle situation when one key is protected with
  passphrase and the other is not. There is no quick fix for this.
  The complete solution will be to make number of iterations a per-key
  value. Because this need metadata format change and is only needed for
  devices attached on boot, I'll leave it as it is for now.

MFC after: 3 days

18 years agoCheck rootvnode variable to see if we still want to ask for passphrase on
pjd [Sat, 11 Feb 2006 12:45:01 +0000 (12:45 +0000)]
Check rootvnode variable to see if we still want to ask for passphrase on
boot. Other methods just don't work properly.

MFC after: 3 days

18 years agoCPU time accounting speedup (step 2)
phk [Sat, 11 Feb 2006 09:33:07 +0000 (09:33 +0000)]
CPU time accounting speedup (step 2)

Keep accounting time (in per-cpu) cputicks and the statistics counts
in the thread and summarize into struct proc when at context switch.

Don't reach across CPUs in calcru().

Add code to calibrate the top speed of cpu_tickrate() for variable
cpu_tick hardware (like TSC on power managed machines).

Don't enforce monotonicity (at least for now) in calcru.  While the
calibrated cpu_tickrate ramps up it may not be true.

Use 27MHz counter on i386/Geode.

Use TSC on amd64 & i386 if present.

Use tick counter on sparc64

18 years agoUse the correct address for the ohci device.
imp [Sat, 11 Feb 2006 03:58:07 +0000 (03:58 +0000)]
Use the correct address for the ohci device.

18 years agoUse ETHER_ADDR_LEN rather than 6.
imp [Sat, 11 Feb 2006 03:50:03 +0000 (03:50 +0000)]
Use ETHER_ADDR_LEN rather than 6.

18 years agoImprove the memory resoruce allocation and usage during the probe.
imp [Sat, 11 Feb 2006 03:41:20 +0000 (03:41 +0000)]
Improve the memory resoruce allocation and usage during the probe.
I've had these improvements in my tree for almost a year now...

18 years agoUse the release version as a floor, not an exact match. Add comment to that
imp [Sat, 11 Feb 2006 03:30:17 +0000 (03:30 +0000)]
Use the release version as a floor, not an exact match.  Add comment to that
effect and draw attention to the fact that the list has stronger ordering
requirements than before.

18 years agoGive ohci_intr a proper return value. In FreeBSD, this is void. Remove
imp [Sat, 11 Feb 2006 03:29:02 +0000 (03:29 +0000)]
Give ohci_intr a proper return value.  In FreeBSD, this is void.  Remove
now-redundant cast on establishing the interrupt.

18 years agoUpdate the keyspan product list from NetBSD.
imp [Sat, 11 Feb 2006 03:27:57 +0000 (03:27 +0000)]
Update the keyspan product list from NetBSD.

18 years agoDo initial cut of SAS HBA support. These controllers (106X) seem to support
mjacob [Sat, 11 Feb 2006 01:35:29 +0000 (01:35 +0000)]
Do initial cut of SAS HBA support. These controllers (106X) seem to support
automatically both SATA and SAS drives.  The async SAS event handling we catch
but ignore at present (so automagic attach/detach isn't hooked up yet).

Do 64 bit PCI support- we can now work on systems with > 4GB of memory.

Do large transfer support- we now can support up to reported chain depth, or
the length of our request area. We simply allocate additional request elements
when we would run out of room for chain lists.

Tested on Ultra320, FC and SAS controllers on AMD64 and i386 platforms.
There were no RAID cards available for me to regression test.

The error recovery for this driver still is pretty bad.

18 years agoThis commit was generated by cvs2svn to compensate for changes in r155518,
rwatson [Sat, 11 Feb 2006 00:39:23 +0000 (00:39 +0000)]
This commit was generated by cvs2svn to compensate for changes in r155518,
which included commits to RCS files with non-trunk default branches.

18 years agoCVS import OpenBSM 1.0 alpha 4:
rwatson [Sat, 11 Feb 2006 00:39:23 +0000 (00:39 +0000)]
CVS import OpenBSM 1.0 alpha 4:

- Remove "audit" user example from audit_user, as it's not present on most
  systems.
- Add cannot_audit() function non-Darwin systems that wraps auditon();
  required by OpenSSH BSM support.  Convert Darwin cannot_audit() into a
  function rather than a macro.
- Library build fixed on Darwin following include file tweaks.  The native
  Darwin sys/audit.h conflicts with bsm/audit.h due to duplicate types, so
  for now we force bsm_wrappers.c to not perform a nested include of
  sys/audit.h.

Obtained from: TrustedBSD Project