Re: remove cpu hotplug bustification in cpufreq.

From: Linus Torvalds
Date: Sat Jul 22 2006 - 20:09:15 EST




On Sat, 22 Jul 2006, Dave Jones wrote:
>
> This stuff makes my head hurt. Someone who is motivated
> enough to fix up hotplug-cpu can fix this up later.
> In the meantime, this patch should cure the lockdep
> warnings that seem to trigger very easily.

It doesn't seem to fix all problems. On CPU unplug, I still get deadlocks
through some workqueue:

[<c03af64a>] __mutex_lock_slowpath+0x4d/0x7b
[<c03af687>] .text.lock.mutex+0xf/0x14
[<c0137591>] __lock_cpu_hotplug+0x36/0x56
[<c01375ca>] lock_cpu_hotplug+0xa/0xc
[<c012f7c2>] flush_workqueue+0x2d/0x61
[<c012f83b>] flush_scheduled_work+0xd/0xf
...

and the nasty part is that this can apparently hit _any_ process that
wants to flush workqueues (in one particular case, it was through
tty_release() -> release_dev() in drivers/char/tty.c).

The whole CPU hotplug locking seems to be broken.

Linus
-
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/