Commit Graph

119740 Commits

Author SHA1 Message Date
Craig Rodrigues
c02fbedfee Increase WARNS level to 6 2005-11-13 01:40:36 +00:00
Craig Rodrigues
fe4ad3bc06 Convert mount_cd9660 to use nmount(). 2005-11-13 01:39:55 +00:00
Craig Rodrigues
b19e74ca20 - Make size parameter to build_iovec() a size_t, not an int
- Add build_iovec_argf() helper function, for help converting old
  mount options which used the mount_argf() function for the mount() syscall.

Discussed with:	phk
2005-11-13 01:27:57 +00:00
Bruce Evans
25efbfb212 Fixed some magic numbers.
The threshold for not being tiny was too small.  Use the usual 2**-12
threshold.  This change is not just an optimization, since the general
code that we fell into has accuracy problems even for tiny x.  Avoiding
it fixes 2*1366 args with errors of more than 1 ulp, with a maximum
error of 1.167 ulps.

The magic number 22 is log(DBL_EPSILON)/2 plus slop.  This is bogus
for float precision.  Use 9 (~log(FLT_EPSILON)/2 plus less slop than
for double precision).  The code for handling the interval
[2**-28, 9_was_22] has accuracy problems even for [9, 22], so this
change happens to fix errors of more than 1 ulp in about 2*17000
cases.  It leaves such errors in about 2*1074000 cases, with a max
error of 1.242 ulps.

The threshold for switching from returning exp(x)/2 to returning
exp(x/2)^2/2 was a little smaller than necessary.  As for coshf(),
This was not quite harmless since the exp(x/2)^2/2 case is inaccurate,
and fixing it avoids accuracy problems in 2*6 cases, leaving problems
in 2*19997 cases.

Fixed naming errors in pseudo-code in comments.
2005-11-13 00:41:46 +00:00
Bruce Evans
c24b7984fc Fixed some magic numbers.
The threshold for not being tiny was confusing and too small.  Use the
usual 2**-12 threshold and simplify the algorithm slightly so that
this threshold works (now use the threshold for sinhf() instead of one
for 1+expm1()).  This is just a small optimization.

The magic number 22 is log(DBL_EPSILON)/2 plus slop.  This is bogus
for float precision.  Use 9 (~log(FLT_EPSILON)/2 plus less slop than
for double precision).

The threshold for switching from returning exp(x)/2 to returning
exp(x/2)^2/2 was a little smaller than necessary.  This was not quite
harmless since the exp(x/2)^2/2 case is inaccurate.  Fixing it happens
to avoid accuracy problems for 2*6 of the 2*151 args that were handled
by the exp(x)/2 case.  This leaves accuracy problems for about 2*19997
args near the overflow threshold (~89); the maximum error there is
2.5029 ulps.

There are also accuracy probles for args in +-[0.5*ln2, 9] -- 2*188885
args with errors of more than 1 ulp, with a maximum error of 1.384 ulps.

Fixed a syntax error and naming errors in pseudo-code in comments.
2005-11-13 00:08:23 +00:00
Jens Schweikhardt
26cd969f5e Correct a grammo and capitalize a few abbreviations. 2005-11-12 21:45:20 +00:00
Marcel Moolenaar
d453d31b41 Instead of saving the unit number of the md(4) device name, save the
whole name. This does not unnecessarily close the door that in some
future we want to test on something other than md(4) devices.

Also add a "conf" action so that we can check whether a gctl actually
did the right thing or not. It's one thing to check that the result
strings are as expected, but it doesn't tell us if the end result is
correct. This needs a bit more fleshing out, but for now a visual
(i.e. manual) check suffices.
2005-11-12 20:17:08 +00:00
Craig Rodrigues
6f5f1a6b3e - Minor fixes to raise WARNS level to 6.
- Teach the mount program to call the nmount() syscall directly
- Preserve existing method of calling mount() for UFS, until we clean things
  up.
- Preserve existing method of forking and calling external mount programs for
  mfs, msdosfs, nfs, nfs4, ntfs, nwfs, nullfs, portalfs, reiserfs, smbfs,
  udf, umapfs, unionfs
- devfs, linprocfs, procfs, ext2fs call nmount() syscall directly, since
  that is all those external mount programs were doing

Reviewed by:	phk
Discussed on:	arch
2005-11-12 20:12:56 +00:00
Bruce Evans
e96c4fd9f7 Imoproved comments for the minimax polynomial.
Removed an unused variable.

Fixed some wrong comments and some nearby misformatting.
2005-11-12 20:06:04 +00:00
Marcel Moolenaar
d40f7f8b3e Make the kern.geom.conftxt sysctl more usable by also dumping the
MD class. Previously only the DISK class was dumped. The only
consumer of this sysctl is libdisk (i.e. sysinstall) and it tests
explicitly for instances of the DISK class. Dumping other classes
is therefore harmless.
By also dumping the MD class regression tests can be written that
use the MD class for operations that would normally be done on the
DISK class. The sysctl can now be used to test if those operations
took an effect. An example is partitioning.
2005-11-12 20:02:02 +00:00
Bruce Evans
6e10a447f8 Tweaked the minimax polynomial and improved its comments. 2005-11-12 19:56:35 +00:00
Bruce Evans
787d6d77d5 Improved comments for the minimax polynomial. 2005-11-12 19:54:45 +00:00
Ruslan Ermilov
006846f7ae Speed up stale catpages hunting by not running sed(1) for every catpage. 2005-11-12 19:31:30 +00:00
Ruslan Ermilov
0f8bb094ff Don't check DESTDIR when making distributeworld; the latter expects
DISTDIR.

Reported by:	nyan
2005-11-12 19:28:46 +00:00
Ruslan Ermilov
28b6aa4a84 Really fix it this time. 2005-11-12 19:14:21 +00:00
Ruslan Ermilov
79dae79f66 Attempt to fix pc98 GENERIC compile breakage. 2005-11-12 18:50:06 +00:00
Bruce Evans
d4a74de9fc As for the float trig functions, use a minimax polynomial that is
specialized for float precision.  The new polynomial has degree 8
instead of 14, and a maximum error of 2**-34.34 (absolute) instead of
2**-30.66.  This doesn't affect the final error significantly; the
maximum error was and is about 0.8879 ulps on amd64 -01.

The fdlibm expf() is not used on i386's (the "optimized" asm version
is used), but probably should be since it was already significantly
faster than the asm version on athlons.  The asm version has the
advantage of being more accurate, so keep using it for now.
2005-11-12 18:20:09 +00:00
Ian Dowse
a60c16ad2f Fix a > 1 year old typo that caused the ulpt driver to try reading
from the printer and discarding the data even if the ulpt device
was opened for reading. This resulted in crashes because two
conconcurrent read transfers were using the same transfer structure.

PR:		usb/88886
Reported By:	Alex Pivovarov
MFC after:	1 week
2005-11-12 17:39:31 +00:00
Daniel Eischen
f4fb3299fa Fix a stub function so that is has the correct number of
arguments.  While I'm here, correct a couple of [tab] alignments.

Submitted by:	bland
2005-11-12 16:00:29 +00:00
Craig Rodrigues
d5328381f1 style(9) cleanups.
Spotted by:	njl, bde
2005-11-12 14:41:44 +00:00
Robert Watson
df0c8868b1 Add "-s" argument to kdump to suppress the display of I/O data.
MFC after:	1 week
2005-11-12 14:21:48 +00:00
Greg Lehey
b2f9e51241 Look through ext2fs file systems as well as ufs.
This should almost certainly be extended to other local file systems
as well (ntfs springs to mind), but I don't have the ability to test
it.
2005-11-12 12:45:08 +00:00
Kirill Ponomarev
3d4e952eef Add -P flag, it does the same as the -p option, except that the
given prefix is also used recursively for the dependency packages,
if any.  If the -P flag appears after any -p flag on the
command line, it overrides it's effect, causing pkg_add to use the
given prefix recursively.

PR:		bin/75742
Submitted by:	Frerich Raabe <raabe AT kde DOT org>
MFC after:	3 days
2005-11-12 11:45:01 +00:00
Robert Watson
71909edec8 Significant refactoring of the accounting code to improve locking and VFS
happiness, as well as correct other bugs:

- Replace notion of current and saved accounting credential/vnode with a
  single credential/vnode and an acct_suspended flag.  This simplifies the
  accounting logic substantially.

- Replace acct_mtx with acct_sx, a sleepable lock held exclusively during
  reconfiguration and space polling, but shared during log entry
  generation.  This avoids holding a mutex over sleepable VFS operations.

- Hold the sx lock over the duration of the I/O so that the vnode I/O
  cannot occur after vnode close, which could occur previously if
  accounting was disabled as a process exited.

- Write the accounting log entry with Giant conditionally acquired based
  on the file system where the log is stored.  Previously, the accounting
  code relied on the caller acquiring Giant.

- Acquire Giant conditionally in the accounting callout based on the file
  system where the accounting log is stored.  Run the callout MPSAFE.

- Expose acct_suspended via a read-only sysctl so it is possibly to
  programmatically determine whether accounting is suspended or not without
  attempting to parse logs.

- Check both acct_vp and acct_suspended lock-free before entering the
  accounting sx lock in acct().

- When accounting is disabled due to a VBAD vnode (i.e., forceable unmount),
  generate a log message indicating accounting has been disabled.

- Correct a long-standing bug in how free space is calculated and compared
  to the required space: generate and compare signed results, not unsigned
  results, or negative free space will cause accounting to not be suspended
  when required, or worse, incorrectly resumed once negative free space is
  reached.

MFC after:	2 weeks
2005-11-12 10:45:13 +00:00
David Xu
413cf3bbe1 Make sure only remove one signal by debugger. 2005-11-12 04:22:16 +00:00
Maksim Yevmenkin
e4638e53d8 Add section to start/stop Bluetooth USB devices (via ng_ubt(4))
Submitted by:	Panagiotis Astithas ( past at ebs dot gr )
Reviewed by:	brooks, imp
MFC after:	1 week
2005-11-12 03:42:56 +00:00
David Xu
ec0fd3f855 add continued status. 2005-11-12 01:37:03 +00:00
David Xu
b1e515a3f4 Insert missing copyright headers. 2005-11-12 01:19:05 +00:00
John Baldwin
6efabadaef Document -32 flag in usage() output as well.
Requested by:	ru
MFC after:	1 week
2005-11-11 21:24:21 +00:00
Ruslan Ermilov
0069d4d8b1 Traditionally expand tabs here. 2005-11-11 21:05:40 +00:00
John Baldwin
cff2cd1d3c Document the -32 switch available on amd64.
Submitted by:	Steve Kargl sgk at troutmask dot apl dot washington dot edu
MFC after:	1 week
2005-11-11 20:29:50 +00:00
John Baldwin
4d5fe96d68 Fix a bug in dlinfo(RTLD_DI_SERINFOSIZE) requests. For each search path
we included the length of the path in the returned size but not the length
of the associated Dl_serpath structure.  Without this fix, programs
attempting to allocate a structure to hold the search path information
would allocate too small of a buffer and rtld would overrun the buffer
while filling it via a subsequent RTLD_DI_SERINFO request.

Submitted by:	"William K. Josephson" wkj at morphisms dot net
Reviewed by:	jdp
MFC after:	2 weeks
2005-11-11 19:57:41 +00:00
Xin LI
d9276f685b Add dev/speaker into include/ tree 2005-11-11 17:38:10 +00:00
Xin LI
b0f3cf4492 Since speaker.h now lives in sys/dev/speaker, reflect this fact here. 2005-11-11 16:48:01 +00:00
Paul Saab
cad572c41b Update PCI ids to add the E200, E200i, P400, and P400i storage
controllers.  Remove the E400 since it is not a real product.

Submitted by:	HP
2005-11-11 16:45:33 +00:00
Ruslan Ermilov
4a0d6638b3 - Store pointer to the link-level address right in "struct ifnet"
rather than in ifindex_table[]; all (except one) accesses are
  through ifp anyway.  IF_LLADDR() works faster, and all (except
  one) ifaddr_byindex() users were converted to use ifp->if_addr.

- Stop storing a (pointer to) Ethernet address in "struct arpcom",
  and drop the IFP2ENADDR() macro; all users have been converted
  to use IF_LLADDR() instead.
2005-11-11 16:04:59 +00:00
David Xu
b71ec5beb4 Only signo should be marked with .Fa. 2005-11-11 14:52:06 +00:00
Jean-Yves Lefort
d0d5f05bff List /boot/device.hints entries for the second joystick.
Approved by:	joel
2005-11-11 12:53:37 +00:00
Ruslan Ermilov
f0a2ef4889 Use the more appropriate ifnet_byindex() instead of ifaddr_byindex(). 2005-11-11 12:32:49 +00:00
Ruslan Ermilov
f5071cacb1 Catch up with IFP2ENADDR() type change (array -> pointer). 2005-11-11 12:17:31 +00:00
Peter Grehan
58d7d1a8fa Add definitions for 64-bit PTEs 2005-11-11 12:03:28 +00:00
Pawel Jakub Dawidek
d941425873 Rename GEOM class kernel module g_md.ko to geom_md.ko for consistency
with the rest.

mdconfig.c:	Simplify mdmaybeload() function.
mdioctl.h:	Removed (now unused) #define.
loader.conf:	Sort GEOM classes properly.

OK'ed by:	phk
2005-11-11 11:31:23 +00:00
Gleb Smirnoff
d314617e8a Force this interface to be RUNNING. 2005-11-11 11:17:57 +00:00
Pawel Jakub Dawidek
62e698b51d Add more GEOM classes to defaults/loader.conf. Add references to manual
pages to those already present.

Reviewed by:	brueffer
2005-11-11 10:48:30 +00:00
Ruslan Ermilov
6d8200ff0c Add /dev/speaker support to amd64.
The following repo-copies were made (by Mark Murray):

sys/i386/isa/spkr.c -> sys/dev/speaker/spkr.c
sys/i386/include/speaker.h -> sys/dev/speaker/speaker.h
share/man/man4/man4.i386/spkr.4 -> share/man/man4/spkr.4
2005-11-11 09:57:32 +00:00
Peter Grehan
c00f3b9d77 ata_generic_hw takes a dev as a parameter, not a channel. 2005-11-11 09:36:38 +00:00
Peter Grehan
95dc459223 Fix compile warning: pmap_bootstrap is now declared extern in pmap.h,
remove redundant declaration.
2005-11-11 09:32:27 +00:00
Gleb Smirnoff
44ec3c8c44 Some fixes for last commit.
Submitted by:	ru
2005-11-11 09:31:23 +00:00
Ruslan Ermilov
9f5529b45a Skip .symbols files. 2005-11-11 08:13:18 +00:00
Xin LI
16902e8a3f Fix plural. 2005-11-11 08:00:44 +00:00