jeff [Sun, 13 Mar 2005 11:44:02 +0000 (11:44 +0000)]
- Get rid of VXLOCK, VXWANT, and vx_*. The vnode lock now protects us
against recycling.
- Modify VSHOULDFREE, VCANRECYCLE, etc. now that certain flags are no
longer important. Remove VMIGHTFREE as it is only used in one place.
iedowse [Sun, 13 Mar 2005 04:07:40 +0000 (04:07 +0000)]
Fix the arrangement of periodic QH tree to give the correct interval
between passes over a QH. Previously the accesses to a QH were
bunched together in time, so the interval was often much longer
than intended. This now appears to match the diagrams in the EHCI
spec, so remove the XXX comment.
kientzle [Sun, 13 Mar 2005 02:53:42 +0000 (02:53 +0000)]
Support extracting entries with pathnames longer than PATH_MAX. In
testing, I've archived and restored dir trees with ~1MB pathnames.
Most formats, of course, have much smaller limits.
kan [Sat, 12 Mar 2005 21:26:53 +0000 (21:26 +0000)]
Allow kernels loaded by pxeboot, which was compiled with LOADER_TFTP_SUPPORT,
to stll be able to mount NFS root as prescribed by DCHP configuration. Since
pxeboot is using TFTP to get to the files, pxeboot can not rely on NFS to
provide it a root directory hande as a side effect. pxeboot has to make RPC
mount call itself.
hrs [Sat, 12 Mar 2005 19:04:03 +0000 (19:04 +0000)]
New release notes:
jail(8) security.jail.chflags_allowed sysctl,
zs driver removed,
ng_ipfw(4) added,
ips(4) crash dump support,
getaddrinfo(3) DNS query order changed,
powerd(8) added, and
RFC derived manual pages replaced.
Update release notes:
acpi_throttle and acpi_perf merged into acpi and
can be disabled via device hints, and
some rewording due to zs driver removal in the entry which
explains uart(4) has been enabled by default on FreeBSD/sparc64.
marius [Sat, 12 Mar 2005 17:06:03 +0000 (17:06 +0000)]
In uart_cpu_getdev_console() when determinig whether we should use
a serial console anyway because input-device is set to keyboard and
output-device is set to screen but no keyboard is plugged in don't
assume that a device node for the input-device alias exists. While
this is true for RS232 keyboards (the node of the SCC and UART
respectively which controls the keyboard doesn't disappear when no
keyboard is plugged in) this assumption breaks for USB keyboards.
It's most likely also not true for PS/2 keyboards but OFW doesn't
reliably switch to a serial console when the potential keyboard is
a PS/2 one which isn't plugged in so this couldn't be verified
properly.
Reported by: Will Andrews <will@csociety.org>, obrien
MFC after: 1 week
rwatson [Sat, 12 Mar 2005 13:39:39 +0000 (13:39 +0000)]
Extend the coverage of the accept and socket mutexes in soisconnected()
so that the socket lock is held over the test-and-set removal of the
accept filter option during connect, and the two socket mutex regions
(transition to connected, perform accept filter) are combined.
rwatson [Sat, 12 Mar 2005 12:57:18 +0000 (12:57 +0000)]
Move the logic implementing retrieval of the SO_ACCEPTFILTER socket option
from uipc_socket.c to uipc_accf.c in do_getopt_accept_filter(), so that it
now matches do_setopt_accept_filter(). Slightly reformulate the logic to
match the optimistic allocation of storage for the argument in advance,
and slightly expand the coverage of the socket lock.
rwatson [Sat, 12 Mar 2005 12:27:47 +0000 (12:27 +0000)]
Part two of post-SMPng cleanup of accept filter registration: perform all
allocation up front before grabbing the socket mutex and doing the
registration work. The result is a lot cleaner.
scottl [Sat, 12 Mar 2005 07:01:53 +0000 (07:01 +0000)]
Guard against an integer underflow that could cause busdma to eat up all
available RAM. This also results in the global bounce page limit being
applied to zones instead of globally.
mux [Sat, 12 Mar 2005 02:43:50 +0000 (02:43 +0000)]
Fix a long-standing bug in alpha's implementation of busdma. We need to
OR the physical address with alpha_XXX_dmamap_or to get the DMA address,
like the name of the variable suggests. However, while we were doing
this correctly in the alpha_XXX_dmamap() macro, the busdma code added
the variable to the physical address instead of or'ing it. Fortunately
and if my math is not entirely wrong, you would need more than 128GB of
RAM and a device able to do DMA in 64bits to experience the bug.
njl [Fri, 11 Mar 2005 23:27:45 +0000 (23:27 +0000)]
The mbnambuf routines combine multiple substrings into a single
long filename. Each substring is indexed by the windows ID, a
sequential one-based value. The previous code was extremely slow,
doing a malloc/strcpy/free for each substring.
This code optimizes these routines with this in mind, using the ID
to index into a single array and concatenating each WIN_CHARS chunk
at once. (The last chunk is variable-length.)
This code has been tested as working on an FS with difficult filename
sizes (255, 13, 26, etc.) It gives a 77.1% decrease in profiled
time (total across all functions) and a 73.7% decrease in wall time.
Test was "ls -laR > /dev/null".
Per-function time savings:
mbnambuf_init: -90.7%
mbnambuf_write: -18.7%
mbnambuf_flush: -67.1%
peter [Fri, 11 Mar 2005 22:16:09 +0000 (22:16 +0000)]
Remove diffs to i386 version that came in via the compiler support ifdefs.
This changes things like whitespace, inconsistent use of #ifndef vs
#if !defined(), different macro argument orders, mismatched comments, etc.
rwatson [Fri, 11 Mar 2005 21:37:45 +0000 (21:37 +0000)]
First step in simplifying accept filter socket option logic in the
post-SMPng world order. Centralize handling of the socket option
clear case in do_setopt_accept_filter().
sam [Fri, 11 Mar 2005 19:40:34 +0000 (19:40 +0000)]
reorder ath_rate_onoe to after ath_rate_sample so it gets used as the
default rate control algorithm; this should be done differently but for
now use this simple solution
rwatson [Fri, 11 Mar 2005 16:30:02 +0000 (16:30 +0000)]
When setting up a socket in socreate(), there's no need to lock the
socket lock around knlist_init(), so don't.
Hard code the setting of the socket reference count to 1 rather than
using soref() to avoid asserting the socket lock, since we've not yet
exposed the socket to other threads.
This removes two mutex operations from each socket allocation.
rwatson [Fri, 11 Mar 2005 15:06:16 +0000 (15:06 +0000)]
The SO_NOSIGPIPE socket option allows a user process to mark a socket
so that the socket does not generate SIGPIPE, only EPIPE, when a write
is attempted after socket shutdown. When the option was introduced in
2002, this required the logic for determining whether SIGPIPE was
generated to be pushed down from dofilewrite() to the socket layer so
that the socket options could be considered. However, the change in
2002 omitted modification to soo_write() required to add that logic,
resulting in SIGPIPE not being generated even without SO_NOSIGPIPE when
the socket was written to using write() or related generic system calls.
This change adds the EPIPE logic to soo_write(), generating a SIGPIPE
signal to the process associated with the passed uio in the event that
the SO_NOSIGPIPE option is not set.
Notes:
- The are upsides and downsides to placing this logic in the socket
layer as opposed to the file descriptor layer. This is really fd
layer logic, but because we need so_options, we have a choice of
layering violations and pick this one.
- SIGPIPE possibly should be delivered to the thread performing the
write, not the process performing the write.
- uio->uio_td and the td argument to soo_write() might potentially
differ; we use the thread in the uio argument.
- The "sigpipe" regression test in src/tools/regression/sockets/sigpipe
tests for the bug.
Submitted by: Mikko Tyolajarvi <mbsd at pacbell dot net>
Talked with: glebius, alfred
PR: 78478
MFC after: 1 week
harti [Fri, 11 Mar 2005 13:24:08 +0000 (13:24 +0000)]
Simplify the print routines by using LST_FOREACH instead of Lst_ForEach
and inlining the small printing utility functions.
Create a function that can be used to produce printable representations
of flag words.
harti [Fri, 11 Mar 2005 13:02:38 +0000 (13:02 +0000)]
Remove leading underscores from the pathname defines. All identifiers
with leading underscore followed by an uppercase letter are in the
implementation namespace.
rwatson [Fri, 11 Mar 2005 12:47:14 +0000 (12:47 +0000)]
Add sigpipe, a simple UNIX domain socket and TCP regression test that is
intended to verify that SIGPIPE is delivered to a process writing or
sending on a socket that has been shut down for write. If available,
SO_NOSIGPIPE is also tested.
This regression test is currently passed by RELENG_4, but not by HEAD or
RELENG_5, due to a bug in the write() code for sockets. SO_NOSIGPIPE is not
present in RELENG_4, however, so is not tested there.
Reported by: Mikko Tyolajarvi <mbsd at pacbell dot net>
PR: 78478
harti [Fri, 11 Mar 2005 11:29:39 +0000 (11:29 +0000)]
Call ParseFinishLine() also for the last line in a file. This
patch differs from the previous one in that it calls the function
only when a real file hits EOF. The bodies of .for loops are also
handled as files, but for these we don't want to end a dependency block
on the 'EOF' as in:
imp [Fri, 11 Mar 2005 07:03:46 +0000 (07:03 +0000)]
Make the pps interrupt register as MPSAFE and FAST. Use a spin lock
to syncrhonize access to the data as a result. This makes the pps
less likely to miss the 1ms pulse that I'm feeding it, but not
entirely reliable yet on my 133MHz P5.
imp [Fri, 11 Mar 2005 05:27:05 +0000 (05:27 +0000)]
Revert changes of 1.49. Lots-a-people broke with it, for reasons
unknown (since my sony vaio didn't :-(.
Instead, fix the problem described by 1.49 in a different way: just
add the two calls I'd hoped I'd avoid in 1.49 by doing the (wrong)
gymnastics there. While 1.49 is a good direction to go in, each step
of the way should work :-(.
dds [Thu, 10 Mar 2005 22:10:16 +0000 (22:10 +0000)]
Add a new pipe sub-namespace.
This allows us to:
- perform scatter gather operations without using temporary files,
- create non-linear pipelines, and
- implement file views using symbolic links.
File view idea by: Vassilios Karakoidas
Portalfs pointer by: John Ioannidis
MFC after: 1 month
bmilekic [Thu, 10 Mar 2005 21:50:50 +0000 (21:50 +0000)]
Make some basic grammar and style fixes to ng_source.c and ng_source.h.
The latter was particularly violated by someone's editor in the past, due
to an effect I like to call "premature linewrapping."
imp [Thu, 10 Mar 2005 18:09:25 +0000 (18:09 +0000)]
Fix a couple of problems with the probe code when used with pnpbios
resources. When allocating 6 ports for a 4 port range isa code
returns an error. I'm not sure yet why this is the case, but suspect
it is just a non-regularity in how the resource allocation code works
which should be corrected. Use 1 as the ports size in this case.
However, in the hints case, we have to specify the length, so use 6 in
that case. I believe that this is also acpi friendly.
Also, complain when we can't allocate FDOUT register space. Right now we
silently fail when we can't. This failure is referred to above.
When there's no resource for FDCTL, go ahead and allocate one by hand.
Many PNPBIOS tables don't list this resource, and our hints mechanism also
doesn't cover that range. If we can't allocate it, whine, but fake up
something. Before, we were always bogusly faking it and no one noticed
the sham (save the original author who has now fixed his private shame).