Andrew Morton [Sun, 10 Nov 2002 10:01:33 +0000 (02:01 -0800)]
[PATCH] SMP iowait stats
Patch from William Lee Irwin III <wli@holomorphy.com>
Idle time accounting is disturbed by the iowait statistics, for several
reasons:
(1) iowait time is not subdivided among cpus.
The only way the distinction between idle time subtracted from
cpus (in order to be accounted as iowait) can be made is by
summing counters for a total and dividing the individual tick
counters by the proportions. Any tick type resolution which is
not properly per-cpu breaks this, meaning that cpus which are
entirely idle, when any iowait is present on the system, will
have all idle ticks accounted to iowait instead of true idle time.
(2) kstat_read_proc() misreports iowait time
The idle tick counter is passed twice to the sprintf(), once
in the idle tick position, and once in the iowait tick position.
(3) performance enhancement
The O(1) scheduler was very carefully constructed to perform
accesses only to localized cachelines whenever possible. The
global counter violates one of its core design principles,
and the localization of "most" accesses is in greater harmony
with its overall design and provides (at the very least) a
qualitative performance improvement wrt. cache.
The method of correcting this is simple: embed an atomic iowait counter
in the runqueues, find the runqueue being manipulated in io_schedule(),
increment its atomic counter prior to schedule(), and decrement it
after returning from schedule(), which is guaranteed to be the same one,
as the counter incremented is tracked as a variable local to the procedure.
Then simply sum to obtain a global iowait statistic.
(Atomicity is required as the post-wait decrement may occur on a different
cpu from the one owning the counter.)
io_schedule() and io_schedule_timeout() are moved to sched.c as they must
access the runqueues, which are private to sched.c, and nr_iowait() is
created in order to export the sum of all runqueues' nr_iowait().
Jaroslav Kysela [Sun, 10 Nov 2002 22:04:58 +0000 (23:04 +0100)]
ALSA update
- CS4231 - added sparc support to merge sparc/cs4231.c code
- ICE1712
- added support for AK4529
- added support for Midiman M-Audio Delta410
- USB driver
- fixed against newer USB API but allow compilation under 2.4
Jaroslav Kysela [Sun, 10 Nov 2002 21:47:30 +0000 (22:47 +0100)]
ALSA update
- Moved initialization of card->id to card_register() function.
The new default id is composed from the shortname given by driver.
- ES18xx - Fixed power management defines
- VIA82xx - The SG table is build inside hw_params (outside spinlock - memory allocation).
Roman Zippel [Sat, 9 Nov 2002 04:26:20 +0000 (20:26 -0800)]
[PATCH] kconfig update
- fix loading of another configuration
- accept longer strings in configuration
- move conf_filename to mconf.c (it's the only user)
- fix off by one error during string scanning
Zwane Mwaikambo [Sat, 9 Nov 2002 01:38:38 +0000 (17:38 -0800)]
[PATCH] do_nmi needs irq_enter/irq_exit lovin...
Use new "nmi_enter/exit()" which acts the same as the regular irq
entries (increases the preempt count appropriately), but doesn't try to
start processing softirqs on nmi exit (it just decreases the count).
Trond Myklebust [Fri, 8 Nov 2002 11:35:01 +0000 (03:35 -0800)]
[PATCH] Lift the 256 outstanding NFS read/write request limit.
Given the previous set of patches that integrate NFS with the VM +
pdflush memory control, and add mechanisms to cope with low memory
conditions, the time is now ripe to rip out the 256 outstanding
request limit, as well as the associated LRU list in the superblock,
and the nfs_flushd daemon.
The following patch offers a 30% speed increase on my test setup with
512MB of core memory (iozone using 4 threads each writing a 512MB file
over 100Mbit to a Solaris server). Setting mem=64m, I still see a 2-3%
speed increase.
Trond Myklebust [Fri, 8 Nov 2002 11:31:34 +0000 (03:31 -0800)]
[PATCH] slabify the sunrpc layer
In order to better cope with low memory conditions, add slabs for
struct rpc_task and 'small' RPC buffers of <= 2k. Protect these using
mempools.
The only case where we appear to use buffers of > 2k is when
symlinking, and is due to the fact that the path can be up to 4k in
length. For the moment, we just use kmalloc(), but it may be worth it
some time in the near future to convert nfs_symlink() to use pages.
Paul Mackerras [Fri, 8 Nov 2002 11:31:24 +0000 (03:31 -0800)]
[PATCH] remove obsolete powermac drivers
This removes two drivers from drivers/macintosh. The files affected are
all in drivers/macintosh. First, the patch removes the old macintosh
ADB keyboard driver and the macintosh keymap file, which are no longer
used now that we use the input layer and the adbhid.c driver. Secondly,
it removes the drivers/macintosh/rtc.c driver, which was only ever used
on PPC, and which is obsolete now that we use the drivers/char/genrtc.c
driver instead.
Paul Mackerras [Fri, 8 Nov 2002 11:30:02 +0000 (03:30 -0800)]
[PATCH] Update ADB drivers in 2.5
This updates the ADB driver and the three low-level ADB bus adaptor
drivers used on powermacs. The files affected are all in
drivers/macintosh; they are adb.c, macio-adb.c, via-cuda.c and
via-pmu.c.
The main changes in this patch are:
- Remove the use of global cli/sti and replace them with local cli/sti,
spinlocks and semaphores as appropriate.
- Use DECLARE_WORK/schedule_work instead of tq_struct/schedule_task.
- Improvements to the PMU interrupt handling and sleep/wakeup code.
Chuck Lever [Fri, 8 Nov 2002 11:25:23 +0000 (03:25 -0800)]
[PATCH] minor TCP connect cleanup
TCP connect semantics now assume the rpciod is already running, so there
is no longer a need to bump the rpciod semaphor when connecting or closing
an RPC over TCP transport socket.
Chuck Lever [Fri, 8 Nov 2002 11:25:07 +0000 (03:25 -0800)]
[PATCH] remove unused cl_flags field
The RPC clnt struct has a cl_flags field with one bit defined (in an NFS
header, no less). no one ever sets the flag, so remove flag, field, and
test in NFSv2 XDR routines that check for the flag.
[PATCH] cpufreq: correct initialization on Intel Coppermines
cpufreq: Intel Coppermines -- the saga continues.
The detection process for speedstep-enabled Pentium III Coppermines is
considered proprietary by Intel. The attempt to detect this capability
using MSRs failed.
So, users need to pass the option "speedstep_coppermine=1" to the kernel
(boot option or parameter) if they own a SpeedStep capable PIII
Coppermine processor. Tualatins work as before.
Tim Schmielau [Fri, 8 Nov 2002 06:12:48 +0000 (22:12 -0800)]
[PATCH] move _STK_LIM to <linux_resource.h>
I don't see any connection between the stack limit and scheduling. So I
think _STK_LIMIT is better defined in <linux/resource.h> than in
<linux/sched.h>.
The only place STK_LIM is used is in <asm/resource.h>, which only gets
included by <linux/resource.h>, so no change in #includes is necessary.
Jens Axboe [Fri, 8 Nov 2002 05:59:54 +0000 (21:59 -0800)]
[PATCH] enable ide to use bios timings
This is the 2nd version Torben did, basically the same as the one from
yesterday but with symbolic tune defines instead of more magic numbers.
I think the feature is good to have, and it would even allow good ide
performance even for an unsupported chipset as long as the bios sets the
timings right.
Jens Axboe [Fri, 8 Nov 2002 05:50:13 +0000 (21:50 -0800)]
[PATCH] make 16 the default fifo_batch count
Lets just make the default fifo_batch count 16. I see a slight slope in
throughput, but the various interactiveness improvements are worth it,
imho. Plus this gets Andrew of my back, he's been lobbying for this for
a while.
Jens Axboe [Fri, 8 Nov 2002 05:50:01 +0000 (21:50 -0800)]
[PATCH] soft and hard barriers
Right now we have one type of barrier in the block layer, and that is
used mainly for making sure that the io scheduler doesn't reorder
requests when we don't want it to. We also need a flag to tell the io
scheduler and low level queue that this is a barrier. So basically two
needs:
o software barrier, prevents the io scheduler from reordering
o hardware barrier, driver must prevent drive from reordering
So this patch gets rid of REQ_BARRIER and instead adds REQ_SOFTBARRIER
and REQ_HARDBARRIER.
Trond Myklebust [Fri, 8 Nov 2002 05:47:55 +0000 (21:47 -0800)]
[PATCH] Make nfs_find_request() scale
nfs_find_request() needs to be called every time we schedule a write
on the page cache. Currently it is implemented as a linked list which
needs to be traversed completely in the case where we don't already
have a pending write request on the page in question.
The following patch adopts the new radix tree, as is already used in
the page cache. Performance change is more or less negligeable with
the current hard limit of 256 outstanding write requests per mount.
However when I remove this limit then the old nfs_find_request()
actually results in a 50% reduction in speed on my benchmark test
(iozone with 4 threads each writing a 512Mb file on a 512Mb Linux
client against a Solaris server on 100Mbit switched net). With this
patch, the result for the same benchmark is a 50% increase in speed.
Trond Myklebust [Fri, 8 Nov 2002 05:47:43 +0000 (21:47 -0800)]
[PATCH] Add nfs_writepages & backing_dev...
The following patch adds a simple ->writepages method that interprets
the extra information passed down in Andrew's writeback_control
structure, and translates it into nfs-speak.
It also adds a backing_dev_info structure that scales the readahead in
terms of the rsize. Maximum readahead is still 128k if you use 32k
rsize, but it is scaled down to 4k if you use 1k rsize.
Rob Weryk [Fri, 8 Nov 2002 03:25:49 +0000 (19:25 -0800)]
[PATCH] Fix ALSA emu10k1 bass control
This trivial patch fixes a mixer problem with the emu10k1 driver in
ALSA. In sound/pci/emu10k1/emufx.c, the line
static const u32 bass_table[41][5] = {
only has 40 lines defined, instead of 41. This results in no sound
output when the bass control is set at 100% (but works fine at 98%) I
added the missing line, which is present in the OSS emu10k1 driver.
David Mosberger [Fri, 8 Nov 2002 03:23:22 +0000 (19:23 -0800)]
[PATCH] let binfmt_misc optionally preserve argv[1]
This makes it possible for binfmt_misc to optionally preserve the
contents of argv[1]. This is needed for building accurate simulators
which are invoked via binfmt_misc. I had brought up this patch a while
ago (see URL below) and there was no negative feedback (OK, there was no
feedback at all... ;-).
The patch is trivial and the new behavior is triggered only if the
letter "P" (for "preserve") is appended to the binfmt_misc registration
string, so it shold be completely safe.
[IPSEC] More work.
1. Expiration of SAs. Some missing updates of counters.
Question: very strange, rfc defines use_time as time of the first use
of SA. But kame setkey refers to this as lastuse.
2. Bug fixes for tunnel mode and forwarding.
3. Fix bugs in per-socket policy: policy entries do not leak but are destroyed,
when socket is closed, and are cloned on children of listening sockets.
4. Implemented use policy: i.e. use ipsec if a SA is available,
ignore if it is not.
5. Added sysctl to disable in/out policy on some devices.
It is set on loopback by default.
6. Remove resolved reference from template. It is not used,
but pollutes code.
7. Added all the SASTATEs, now they make sense.
Clean up vfs_readv/writev() interface and avoid code duplication.
Make kNFSd use the cleaned-up interfaces, and disable the code that
accesses the low-level readpage() function of the exported filesystem
(not allowed - many filesystems need extra setup, which is why we have
a separate ->sendpage() routine for that).