Re: Kernel WARNING: at net/core/dev.c:1330 __netif_schedule+0x2c/0x98()

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Nick Piggin
Date: Thursday, July 24, 2008 - 3:38 am

On Thursday 24 July 2008 20:08, Peter Zijlstra wrote:

Aside from lockdep, is there a particular problem with taking 64k locks
at once? (in a very slow path, of course) I don't think it causes a
problem with preempt_count, does it cause issues with -rt kernel?

Hey, something kind of cool (and OT) I've just thought of that we can
do with ticket locks is to take tickets for 2 (or 64K) nested locks,
and then wait for them both (all), so the cost is N*lock + longest spin,
rather than N*lock + N*avg spin.

That would mean even at the worst case of a huge amount of contention
on all 64K locks, it should only take a couple of ms to take all of
them (assuming max spin time isn't ridiculous).

Probably not the kind of feature we want to expose widely, but for
really special things like the scheduler, it might be a neat hack to
save a few cycles ;) Traditional implementations would just have
#define spin_lock_async	      spin_lock
#define spin_lock_async_wait  do {} while (0)

Sorry it's offtopic, but if I didn't post it, I'd forget to. Might be
a fun quick hack for someone.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[GIT]: Networking, David Miller, (Sun Jul 20, 10:44 am)
Re: [GIT]: Networking, Arjan van de Ven, (Sun Jul 20, 10:59 am)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 4:52 pm)
Re: [GIT]: Networking, Linus Torvalds, (Sun Jul 20, 5:54 pm)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 6:03 pm)
Re: [GIT]: Networking, Linus Torvalds, (Sun Jul 20, 6:07 pm)
Re: [GIT]: Networking, Alexey Dobriyan, (Sun Jul 20, 6:09 pm)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 6:14 pm)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 6:17 pm)
Re: [GIT]: Networking, Patrick McHardy, (Sun Jul 20, 6:20 pm)
Re: [GIT]: Networking, Alexey Dobriyan, (Sun Jul 20, 6:22 pm)
Re: [GIT]: Networking, Alexey Dobriyan, (Sun Jul 20, 7:40 pm)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 7:48 pm)
Re: [GIT]: Networking, David Miller, (Sun Jul 20, 10:11 pm)
Re: [GIT]: Networking, Alexander Beregalov, (Mon Jul 21, 2:48 am)
Re: [GIT]: Networking, Ben Hutchings, (Mon Jul 21, 3:16 am)
Re: [GIT]: Networking, Stefan Richter, (Mon Jul 21, 4:28 am)
Re: [GIT]: Networking, James Morris, (Mon Jul 21, 4:45 am)
Re: [GIT]: Networking, Alexey Dobriyan, (Mon Jul 21, 4:57 am)
Re: [GIT]: Networking, Patrick McHardy, (Mon Jul 21, 5:05 am)
Re: [GIT]: Networking, Ingo Molnar, (Mon Jul 21, 6:50 am)
Re: [GIT]: Networking, Stefan Richter, (Mon Jul 21, 7:15 am)
Re: [GIT]: Networking, David Miller, (Mon Jul 21, 8:27 am)
Re: [GIT]: Networking, David Miller, (Mon Jul 21, 8:35 am)
Re: [GIT]: Networking, Alexander Beregalov, (Mon Jul 21, 9:04 am)
Re: [GIT]: Networking, Linus Torvalds, (Mon Jul 21, 9:49 am)
Re: [GIT]: Networking, David Miller, (Mon Jul 21, 9:53 am)
Re: [GIT]: Networking, David Miller, (Mon Jul 21, 10:28 am)
Re: [GIT]: Networking, Linus Torvalds, (Mon Jul 21, 10:40 am)
[crash] kernel BUG at net/core/dev.c:1328!, Ingo Molnar, (Mon Jul 21, 11:23 am)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Linus Torvalds, (Mon Jul 21, 11:35 am)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Ingo Molnar, (Mon Jul 21, 11:46 am)
Re: [crash] kernel BUG at net/core/dev.c:1328!, David Miller, (Mon Jul 21, 12:00 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Stefan Richter, (Mon Jul 21, 12:20 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Ingo Molnar, (Mon Jul 21, 12:30 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Ingo Molnar, (Mon Jul 21, 12:44 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, David Miller, (Mon Jul 21, 1:11 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, David Miller, (Mon Jul 21, 1:20 pm)
Re: [GIT]: Networking, David Miller, (Mon Jul 21, 1:32 pm)
Re: [GIT]: Networking, Patrick McHardy, (Mon Jul 21, 1:33 pm)
Re: [crash] kernel BUG at net/core/dev.c:1328!, Stefan Richter, (Mon Jul 21, 2:26 pm)
[TCP bug] stuck distcc connections in latest -git, Ingo Molnar, (Tue Jul 22, 4:21 am)
Re: [TCP bug] stuck distcc connections in latest -git, David Newall, (Tue Jul 22, 6:45 am)
Re: [TCP bug] stuck distcc connections in latest -git, Ingo Molnar, (Tue Jul 22, 6:57 am)
Re: [TCP bug] stuck distcc connections in latest -git, David Newall, (Tue Jul 22, 7:54 am)
Re: [TCP bug] stuck distcc connections in latest -git, Ingo Molnar, (Tue Jul 22, 8:34 am)
Re: [TCP bug] stuck distcc connections in latest -git, Willy Tarreau, (Tue Jul 22, 2:12 pm)
Re: [TCP bug] stuck distcc connections in latest -git, Ingo Molnar, (Wed Jul 23, 1:26 am)
Re: [GIT]: Networking, David Miller, (Wed Jul 23, 4:42 pm)
Re: Kernel WARNING: at net/core/dev.c:1330 __netif_schedul ..., Nick Piggin, (Thu Jul 24, 3:38 am)
Re: [regression] nf_iterate(), BUG: unable to handle kerne ..., Krzysztof Oledzki, (Thu Jul 24, 11:00 am)