Re: [PATCH 2/3] netpoll: netconsole

From: Mitchell Blank Jr
Date: Wed Sep 10 2003 - 10:52:55 EST


Matt Mackall wrote:
> And no, I don't think there's much that can be done to fix it, short
> of putting in deadlock avoidance of some sort or auditing drivers. We
> run a risk of infinite recursion if we manage to avoid the deadlock
> anyway.

No, we won't infinately recurse - read the code around
"down_trylock(&console_sem)" in printk(). Basically if printk() gets
called recursively the data will just be written to the buffer and
the console driver won't get called until later.

The netconsole problem is only if the net driver calls printk() with
its spinlock held (but when not called from netconsole). Then printk()
won't know that it's unsafe to re-enter the network driver.

-Mitch
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/