From mboxrd@z Thu Jan 1 00:00:00 1970 From: Benjamin LaHaise Subject: Re: [PATCH RFC] fs/aio: fix sleeping while TASK_INTERRUPTIBLE Date: Tue, 13 Jan 2015 11:06:33 -0500 Message-ID: <20150113160633.GC25742@kvack.org> References: <20141223001619.GA26385@ret.masoncoding.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii To: Chris Mason , linux-fsdevel@vger.kernel.org, linux-aio@kvack.org, Peter Zijlstra Return-path: Content-Disposition: inline In-Reply-To: <20141223001619.GA26385@ret.masoncoding.com> Sender: owner-linux-aio@kvack.org List-Id: linux-fsdevel.vger.kernel.org Hi Chris, On Mon, Dec 22, 2014 at 07:16:25PM -0500, Chris Mason wrote: > The 3.19 merge window brought in a great new warning to catch someone > calling might_sleep with their state != TASK_RUNNING. The idea was to > find buggy code locking mutexes after calling prepare_to_wait(), kind > of like this: ... > This has been lightly tested and hasn't been benchmarked, so RFC for > now. > > Signed-off-by: Chris Mason > Reported-by: The code of Peter Zijlstra After mulling this over, I think your patch is probably the safest for us to apply at present as it is also the most amenable to backporting. Are you okay with removing the RFC status? I still have my concerns about possible task wakeups causing problems with filesystem code if the copy_to_user() takes a page fault, but those can be addressed separately. Kent's closures are an option for the future, but I think it would be more appropriate for that new code to be introduced in the next merge window. -ben -- "Thought is the essence of where you are now." -- To unsubscribe, send a message with 'unsubscribe linux-aio' in the body to majordomo@kvack.org. For more info on Linux AIO, see: http://www.kvack.org/aio/ Don't email: aart@kvack.org