Cameron Grant [Sat, 17 Mar 2001 16:04:25 +0000 (16:04 +0000)]
destroy child devices on detach to prevent ever-increasing numbers of
pcm/midi devices trying to attach if the module is repeatedly loaded and
unloaded.
Add a new entrypoint to the hashes in libmd:
char *
FooFileChunk(const char *filename, char *buf, off_t offset, off_t length)
Which only hashes part of a file.
Implement FooFile() in terms of this function.
Peter Wemm [Sat, 17 Mar 2001 09:31:06 +0000 (09:31 +0000)]
Use a generic implementation of the Fowler/Noll/Vo hash (FNV hash).
Make the name cache hash as well as the nfsnode hash use it.
As a special tweak, create an unsigned version of register_t. This allows
us to use a special tweak for the 64 bit versions that significantly
speeds up the i386 version (ie: int64 XOR int64 is slower than int64
XOR int32).
The code layout is a little strange for the string function, but I was
able to get between 5 to 10% improvement over the original version I
started with. The layout affects gcc code generation choices and this way
was fastest on x86 and alpha.
Note that 'CPUTYPE=p3' etc makes a fair difference to this. It is
around 45% faster with -march=pentiumpro on a p6 cpu.
Peter Wemm [Sat, 17 Mar 2001 05:43:01 +0000 (05:43 +0000)]
Dramatically improve the **lame** nfs_hash(). This is based on the
Fowler / Noll / Vo Hash (http://www.isthe.com/chongo/tech/comp/fnv/).
This improves hash coverage a *massive* amount. We were seeing one
set of machines that were using 0.84% of their 131072 entry nfsnode
hash buckets with maximum chain lengths of up to ~500 entries. The
machine was spending nearly 100% of its time in 'system'.
A test with this has pushed the coverage from a few perCent up to 91%
utilization with a max chain length of 11.
Peter Wemm [Sat, 17 Mar 2001 00:21:54 +0000 (00:21 +0000)]
Stop cron from shouting in the syslog. Use setproctitle() instead, since
smashing argv[0] doesn't have the intended effect of changing the ps(1)
output these days.
Justin T. Gibbs [Sat, 17 Mar 2001 00:12:15 +0000 (00:12 +0000)]
This is an MFC candidate.
Add the AAC_DEBUG option to enable debugging in the aac driver.
Correct a race condition in the interrupt handler where the
controller may queue a fib to a response queue after the driver
has serviced the queue but before the interrupt is cleared.
This could leave a completed fib stranded in the response queue
unless another I/O completed and generated another interrupt.
Jonathan Lemon [Fri, 16 Mar 2001 22:37:06 +0000 (22:37 +0000)]
When doing a recv(.. MSG_WAITALL) for a message which is larger than
the socket buffer size, the receive is done in sections. After completing
a read, call pru_rcvd on the underlying protocol before blocking again.
This allows the the protocol to take appropriate action, such as
sending a TCP window update to the peer, if the window happened to
close because the socket buffer was filled. If the protocol is not
notified, a TCP transfer may stall until the remote end sends a window
probe.
Kenneth D. Merry [Fri, 16 Mar 2001 22:16:54 +0000 (22:16 +0000)]
Fix inquiry length detection for the ses(4) driver. It was using the
inq_len member of the ccb_getdev structure, but we've never filled that
value in..
So we now get the length from the inquiry data returned by the drive.
(Since we will fetch as much inquiry data as the drive claims to support.)
Reviewed by: mjacob
Reported by: Andrzej Tobola <san@iem.pw.edu.pl>
Robert Watson [Fri, 16 Mar 2001 17:42:38 +0000 (17:42 +0000)]
o The revenge of the mdoc(7) police:
- These pages abused Ar macro (they should have used Fa).
- NULL and other numeric constants should be marked with Dv.
- VOP_* in the ERRORS section for the EOPNOTSUPP entry should be marked
with Fn.
Robert Watson [Fri, 16 Mar 2001 15:02:30 +0000 (15:02 +0000)]
o The mdoc(7) police strike with avengance:
- These pages abused Ar macro (they should have used Fa).
- NULL constant should be marked with Dv.
- VOP_* in the ERRORS section for the EOPNOTSUPP entry should be marked
with Fn.
Warner Losh [Fri, 16 Mar 2001 08:07:00 +0000 (08:07 +0000)]
Back out ru's changes. Soren has requested this and I see no reason
to not just do it. It is his new code that is being actively
developed so he has say over it. ru's direct changes were premature
as they occurred less than 4 hours after it was committed to the tree.
Warner Losh [Fri, 16 Mar 2001 07:36:54 +0000 (07:36 +0000)]
Add some devices:
Xircom CreditCard Netwave cnw
Intel PRO/Wireless 2011 (PRISM II) wi
3COM 3CRWE737A (PRISM II) wi
Note: I've had some reports that the latter two cards work, but I've not
been able to get them to work for me.
Warner Losh [Fri, 16 Mar 2001 07:25:42 +0000 (07:25 +0000)]
Commit port of cnw driver from Hiroyuki Aizu-san. This driver
supports Xircom netwave series of cards. I have one of these cards
(but am trying to find one or two to test with), but it compiles and
aizu-san says it works.
I don't know if this supports 802.11 or not. I've seen conflicting
information on this.
Warner Losh [Fri, 16 Mar 2001 06:33:44 +0000 (06:33 +0000)]
Resync to GENERIC. This backs out the spammage that I committed wrt
killing ipv6 and some other things.
This makes GENERIC and NEWCARD the same, with OLDCARD stuff commented
out and the NEWCARD stuff included. For the moment, pcic is commented
out (which has a old). Plus invariants. Plus ddb.
Jonathan Lemon [Thu, 15 Mar 2001 18:50:32 +0000 (18:50 +0000)]
Limit the number of paths that glob can return to MAX_GLOBENTRIES, which
is currently set to 10000. This is intended to prevent glob from running
amok when a highly recursive path is provided (such as "../*/../*/../*/...")
Søren Schmidt [Thu, 15 Mar 2001 15:36:25 +0000 (15:36 +0000)]
Provide the interface to atacontrol and associated logic.
see atacontrol(8) for more.
Also the ATA_ENABLE_ATAPI_DMA, ATA_ENABLE_WC and ATA_ENABLE_TAGS
options are gone, use the tuneables listed in ata.4 instead from
the loader (this makes it possible to switch off DMA before the
driver has to touch the devices on broken hardware).
Ruslan Ermilov [Thu, 15 Mar 2001 14:52:12 +0000 (14:52 +0000)]
net/route.c:
A route generated from an RTF_CLONING route had the RTF_WASCLONED flag
set but did not have a reference to the parent route, as documented in
the rtentry(9) manpage. This prevented such routes from being deleted
when their parent route is deleted.
Now, for example, if you delete an IP address from a network interface,
all ARP entries that were cloned from this interface route are flushed.
This also has an impact on netstat(1) output. Previously, dynamically
created ARP cache entries (RTF_STATIC flag is unset) were displayed as
part of the routing table display (-r). Now, they are only printed if
the -a option is given.
netinet/in.c, netinet/in_rmx.c:
When address is removed from an interface, also delete all routes that
point to this interface and address. Previously, for example, if you
changed the address on an interface, outgoing IP datagrams might still
use the old address. The only solution was to delete and re-add some
routes. (The problem is easily observed with the route(8) command.)
Note, that if the socket was already bound to the local address before
this address is removed, new datagrams generated from this socket will
still be sent from the old address.
PR: kern/20785, kern/21914
Reviewed by: wollman (the idea)
Maxim Sobolev [Thu, 15 Mar 2001 10:47:00 +0000 (10:47 +0000)]
When creating a package sort dependencies in such a way that if dependency
A depends on dependency B then dependency A will be in all cases listed
before B, so ``pkg_add -r'' will fetch/install packages in the correct order.
Previously dependencies were sorted just by its names, which is why
``pkg_add -r'' never actually worked properly.
To be usefull, hovewer, this fix requires that all packages have been
rebuilt, so it will take some time until users would be able to feel
posititive improvements. For the same reasons it is desirable to propagate
these changes to the 4-stable package building cluster *before* 4.3 ports
freeze, so packages for 4.3-RELEASE would be properly prepared.
Bill Fumerola [Thu, 15 Mar 2001 10:33:00 +0000 (10:33 +0000)]
with my mentor hat on...
remove the concept of a 'maintainer' of our make. there really isn't a
need for any one committer to hold an exclusive lock or serve as a filter
for this code.
Will Andrews [Thu, 15 Mar 2001 10:22:50 +0000 (10:22 +0000)]
Revert previous change -- apparently it's not quite right. It broke
src/sys/modules/if_ef and possibly other things. I tested the build with
a make based on rev. 1.26, and it worked fine. Since I'm not particularly
inclined to figure out what's going on with this, it's probably prudent
just to back it out for now.
Peter Wemm [Thu, 15 Mar 2001 06:56:51 +0000 (06:56 +0000)]
Add a placeholder for the ServerWorks OSB4 device id. The SMBus
interface on this chip is compatable with the PIIX4. The catch is that
this interferes with isab0 which wants to attach to the same PCI node.
It seems to work, but we only tested it on systems with no ISA cards.
Peter Wemm [Thu, 15 Mar 2001 05:10:06 +0000 (05:10 +0000)]
Kill the 4MB kernel limit dead. [I hope :-)].
For UP, we were using $tmp_stk as a stack from the data section. If the
kernel text section grew beyond ~3MB, the data section would be pushed
beyond the temporary 4MB P==V mapping. This would cause the trampoline
up to high memory to fault. The hack workaround I did was to use all of
the page table pages that we already have while preparing the initial
P==V mapping, instead of just the first one.
For SMP, the AP bootstrap process suffered the same sort of problem and
got the same treatment.
MFC candidate - this breaks on 4.x just the same..
Thanks to: Richard Todd <rmtodd@ichotolot.servalan.com>