On Sun, 1 Jan 2006, Lee Revell wrote:
>
> In fact neither of these patches helps, because these RCU callbacks run
> from a tasklet in softirq context, and softirqs are not preemptible
> (unless they are running in threads, see below):
That wasn't why I was hoping they would help..
The actual RCU callback will run uninterruptible, but I was hoping that
the patch would make it be called more often, and not have thousands of
events to work on...
> Linus, would you accept CONFIG_PREEMPT_SOFTIRQS to always run softirqs
> in threads (default N of course, it certainly has a slight throughput
> cost) for mainline if Ingo were to submit it?
Actually, I think there's a better solution.
Try just setting maxbatch back to 10 in kernel/rcupdate.c.
The thing is, "maxbatch" doesn't actually _work_ because what happens is
that the tasklet will continually re-schedule itself, and the caller will
keep calling it. So maxbatch is actually broken.
However, what happens is that after kernel/softirq.c has called the
tasklet ten times, and it is still pending, it will do the softirq in a
thread (see the "max_restart" logic).
Which happens to do the right thing, although I'm pretty convinced that it
was by mistake (or if on purpose, it depends way too closely on silly
magic implementation issues).
I raised maxbatch because the dentry RCU problem (since fixed) was
reported to become less (probably because the scheduling of the softirq's
delayed the freeing of old dentries further, making the problem worse),
and because I don't like the subtlety involved in having two layers of
batching. But hey, it might work, at which point we should just document
how maxbatch and max_restart interact with each other and with softirqd.
Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]