[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <1156249687.14883.68.camel@localhost.localdomain>
Date: Tue, 22 Aug 2006 17:58:07 +0530
From: Sharyathi Nagesh <sharyath@...ibm.com>
To: Heiko Carstens <heiko.carstens@...ibm.com>,
linux-kernel@...r.kernel.org
Cc: zhuyaof@...ibm.com, Srivatsa Vaddagiri <vatsa@...ibm.com>,
Andrew Morton <akpm@...l.org>,
Arjan van de Ven <arjan@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...e.hu>
Subject: Re: [patch] pi-futex: missing pi_waiters plist initialization
On Mon, 2006-07-24 at 13:21 +0200, Heiko Carstens wrote:
> From: Heiko Carstens <heiko.carstens@...ibm.com>
>
> Initialize init task's pi_waiters plist. Otherwise cpu hotplug of cpu 0
> might crash, since rt_mutex_getprio() accesses an uninitialized list head.
>
> call chain which led to crash:
>
> take_cpu_down
> sched_idle_next
> __setscheduler
> rt_mutex_getprio
>
> Using PLIST_HEAD_INIT in the INIT_TASK macro doesn't work unfortunately, since
> the pi_waiters member is only conditionally present.
Hi
I felt it would be more appropriate to put initialization of
pi_waiters in fork_init function rather than in sched_init function as
other init_task related initialization or happening in fork_init(). As
well we have rt_mutex_init_task() function in fork.c which can be reused
for initializing pi_waiters field of init_task.
Please go through the patch and let me know of your opinion.
Thanks
Sharyathi Nagesh
View attachment "pi_waiters.patch" of type "text/x-patch" (1289 bytes)
Powered by blists - more mailing lists