Hartmut Brandt [Mon, 26 Jan 2004 15:19:43 +0000 (15:19 +0000)]
Replace deprecated NG_NODELEN with the new NG_NODESIZ. There is one
problem here still to be solved: the sockaddr_hci has still a 16 byte
field for the node name. The code currently does not correctly use the
length field in the sockaddr to handle the address length, so
node names get truncated to 15 characters when put into a sockaddr_hci.
Hartmut Brandt [Mon, 26 Jan 2004 14:54:39 +0000 (14:54 +0000)]
Define the new command NGM_SOURCE_START_NOW to allow generation of
traffic for non-ethernet hooks. This commit should have been packaged
with the commit to ng_source.c.
Hartmut Brandt [Mon, 26 Jan 2004 14:53:16 +0000 (14:53 +0000)]
Make ng_source to work with non-ethernet interfaces. We do this by
introducing a START_NOW command. This command does not send
and GET_IFINDEX message downstream (to wait for the response from
the ETHERNET node), but directly starts the sending process. This allows
one to generate traffic as input for any hook on any node.
Hartmut Brandt [Mon, 26 Jan 2004 14:46:35 +0000 (14:46 +0000)]
Should use the non-locking versions of the ifqueue macros to
fiddle around with private queues, because their mutex is not
needed. All this processing should be protected by the netgraph
locking.
Maxim Sobolev [Mon, 26 Jan 2004 12:33:56 +0000 (12:33 +0000)]
Add support for WCCPv2. It should be enablem manually using link2
ifconfig(8) flag since header for version 2 is the same but IP payload
is prepended with additional 4-bytes field.
Inspired by: Roman Synyuk <roman@univ.kiev.ua>
MFC after: 2 weeks
Hartmut Brandt [Mon, 26 Jan 2004 10:28:31 +0000 (10:28 +0000)]
Update the upgrade instructions to account for the fact, that
there is no need anymore to re-create files. Also give a hint to
look for changes needed to the Makefiles.
Bill Paul [Mon, 26 Jan 2004 08:36:18 +0000 (08:36 +0000)]
Avoid possible panic on shutdown: if there are still some devices
attached when shutting down, kill our kthreads, but don't destroy
the mutex pool and uma zone resources since the driver shutdown
routine may need them later.
Stephen McKay [Mon, 26 Jan 2004 04:27:22 +0000 (04:27 +0000)]
Use malloc() instead of alloca() to allocate a (potentially) large buffer
for storing the "diff -n" output. Some files (eg ports/INDEX,v) are too
big nowadays to fit on the stack.
Submitted by: Stephen Montgomery-Smith <stephen@math.missouri.edu>
Ian Dowse [Mon, 26 Jan 2004 00:46:46 +0000 (00:46 +0000)]
Be much more strict about parsing tagged log messages from /dev/klog;
if the line doesn't match ^<%d>, then treat it as a regular kernel
printf line. Previously if a kernel printf message started with "<"
it would be interpreted as a log message, often with LOG_EMERG
level. This was triggered by some printfs in sys/dev/aic7xxx/, and
can also happen with the partial lines that result if syslogd cannot
keep up with the rate of arrival of kernel messages.
Mathew Kanner [Sun, 25 Jan 2004 22:46:22 +0000 (22:46 +0000)]
Fix a panic in dsp_clone when trying to access a sound
device that doesn't exists. I'm using my discretion and
committing without mentor approval since Seigo is away.
Doug Ambrisko [Sun, 25 Jan 2004 19:52:16 +0000 (19:52 +0000)]
- Existing code would ignore pccard_ether_delay when more then 9 seconds
- If there was an exiting dhclient running on the same interface as the
new iface that left and returned then dhclient would be told to use the
same interface twice. Dhclient would fail and exit after getting
confused. Use "sort -u" on them to ensure no duplicates.
This is a mostly a race condition on suspend and resume and how things
happen to occur.
- Check for netmask being set on an interface rather then up. An interface
can be up but not configured.
Ruslan Ermilov [Sun, 25 Jan 2004 12:28:36 +0000 (12:28 +0000)]
Fixed a bug that previous revision has introduced -- we missed
the double quotes ("" and '') as a separate argument.
Reported by: ache
The fix in this and previous revisions combined is functionally
equivalent to the below patch against rev. 1.27 but the code is
now much easier to follow:
I don't normally use my middle name, so remove it from attributions in
man pages (though not from copyright notices). While I'm here, add email
addresses where appropriate.
Martin Blapp [Sun, 25 Jan 2004 11:30:50 +0000 (11:30 +0000)]
Dhclient dumps core on suspend/resume cycles. If the client isn't active
then we need to go to the reboot state or in state_bound it will core on
the de-reference of client -> active -> options since client -> active = NULL.
Maxim Sobolev [Sun, 25 Jan 2004 09:59:16 +0000 (09:59 +0000)]
Move LongRun support out of identcpu.c, where it hardly belongs, into its
own file and make it opt-in, not mandatory, depending on CPU_ENABLE_LONGRUN
config(8) option.
Maxim Sobolev [Sun, 25 Jan 2004 09:59:15 +0000 (09:59 +0000)]
Move LongRun support out of identcpu.c, where it hardly belongs, into its
own file and make it opt-in, not mandatory, depending on CPU_ENABLE_LONGRUN
config(8) option.
Jeff Roberson [Sun, 25 Jan 2004 08:04:45 +0000 (08:04 +0000)]
- Now that both schedulers support temporary cpu pinning use this rather
than the switchin functions to guarantee that we're operating with the
correct tlb entry.
- Remove the post copy/zero tlb invalidations. It is faster to invalidate
an entry that is known to exist and so it is faster to invalidate after
use. However, some architectures implement speculative page table
prefetching so we can not be guaranteed that the invalidated entry is still
invalid when we re-enter any of these functions. As a result of this we
must always invalidate before use to be safe.
Jeff Roberson [Sun, 25 Jan 2004 07:47:57 +0000 (07:47 +0000)]
- Compile 4BSD in LINT since ULE will be tested by GENERIC kernel builds.
- Fix the formatting on the ULE options line, I didn't notice that a space
was used normally.
Jeff Roberson [Sun, 25 Jan 2004 05:03:14 +0000 (05:03 +0000)]
- Don't define DETECT_DEADLOCK. I don't know that this code has detected
a deadlock in several years. Furthermore, the IPI code is currently
protected by a seperate spinlock. This only served to make IPIs twice as
expensive as they had to be which severely slowed down the IPI heavy ULE
scheduler.
Jeff Roberson [Sun, 25 Jan 2004 03:54:52 +0000 (03:54 +0000)]
- Add a flags parameter to mi_switch. The value of flags may be SW_VOL or
SW_INVOL. Assert that one of these is set in mi_switch() and propery
adjust the rusage statistics. This is to simplify the large number of
users of this interface which were previously all required to adjust the
proper counter prior to calling mi_switch(). This also facilitates more
switch and locking optimizations.
- Change all callers of mi_switch() to pass the appropriate paramter and
remove direct references to the process statistics.
Robert Watson [Sun, 25 Jan 2004 01:59:27 +0000 (01:59 +0000)]
Add some basic support for measuring sleep mutex contention to the
mutex profiling code. As with existing mutex profiling, measurement
is done with respect to mtx_lock() instances in the code, as opposed
to specific mutexes. In particular, measure two things:
(1) Lock contention. How often did this mtx_lock() call get made and
have to sleep (or almost sleep) waiting for the lock. This helps
identify the "victims" of contention.
(2) Hold contention. How often, while the lock was held by a thread
as a result of this mtx_lock(), did another thread try to acquire
the same mutex. This helps identify the causes of contention.
I'm currently exploring adding measurement of "time waited for the
lock", but the current implementation has proven useful to me so far
so I figured I'd commit it so others could try it out. Note that this
increases the size of mutexes when MUTEX_PROFILING is enabled, so you
might find you need to further bump UMA_BOOT_PAGES. Fixes welcome.
Deal with MOD_FREQUENCY before MOD_OFFSET because the latter is the
one which runs the actual update. This fixes a bug where there were
a delay in applying the frequency adjustment. In extreme cases this
could result in marginal stability of the kernel-pll.
Jeff Roberson [Sat, 24 Jan 2004 21:38:52 +0000 (21:38 +0000)]
- Recruit some new ULE users by making it the default scheduler in GENERIC.
ULE will be in a probationary period to determine whether it will be left
as the default in 5.3 which would likely mean the rest of the 5.x series.
Alan Cox [Sat, 24 Jan 2004 21:31:06 +0000 (21:31 +0000)]
1. Statically initialize swap_pager_full and swap_pager_almost_full to the
full state. (When swap is added their state will change appropriately.)
2. Set swap_pager_full and swap_pager_almost_full to the full state when
the last swap device is removed.
Combined these changes eliminate nonsense messages from the kernel on swap-
less machines.
Item 2 submitted by: Divacky Roman <xdivac02@stud.fit.vutbr.cz>
Prodding by: phk
Maxim Sobolev [Sat, 24 Jan 2004 21:23:12 +0000 (21:23 +0000)]
Add support for Crystalfontz CFA-631 USB LCD (uftdi(4) driver).
For some very unclear reason this device contains a FTDI 8U232AM USB->COM
adapter, but reports different device id than original 8U232AM. At the same
time, it reports vendor id of FTDI.
Sponsored by: Porta Software Ltd
MFC after: 2 weeks
Maxim Sobolev [Sat, 24 Jan 2004 21:13:13 +0000 (21:13 +0000)]
- Move performance-controlling sysctls into hw.p4tcc.* tree;
Suggested by: nate
- get rid of "magick" values in code and make sysctl's reflecting reality
on processor versions which have one or another frequency "forbidden"
due to errata.
Maxim Sobolev [Sat, 24 Jan 2004 21:13:12 +0000 (21:13 +0000)]
- Move performance-controlling sysctls into hw.p4tcc.* tree;
Suggested by: nate
- get rid of "magick" values in code and make sysctl's reflecting reality
on processor versions which have one or another frequency "forbidden"
due to errata.