From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753388AbcJUFjq (ORCPT ); Fri, 21 Oct 2016 01:39:46 -0400 Received: from merlin.infradead.org ([205.233.59.134]:43364 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750949AbcJUFjo (ORCPT ); Fri, 21 Oct 2016 01:39:44 -0400 Date: Fri, 21 Oct 2016 07:39:20 +0200 From: Peter Zijlstra To: Roman Pen Cc: Andy Lutomirski , Josh Poimboeuf , Borislav Petkov , Brian Gerst , Denys Vlasenko , "H . Peter Anvin" , Thomas Gleixner , Ingo Molnar , Tejun Heo , linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] sched: do not call workqueue sleep hook if task is already dead Message-ID: <20161021053920.GW3102@twins.programming.kicks-ass.net> References: <20160921154350.13128-1-roman.penyaev@profitbricks.com> <20160921154350.13128-2-roman.penyaev@profitbricks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160921154350.13128-2-roman.penyaev@profitbricks.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 21, 2016 at 05:43:50PM +0200, Roman Pen wrote: > If panic_on_oops is not set and oops happens inside workqueue kthread, > kernel kills this kthread. Current patch fixes recursive GPF which > happens in that case with the following stack: > The root cause is that zeroed task->vfork_done member is accessed from > wq_worker_sleeping() hook. This is the kthread_data() -> to_kthread() thing? Could've done with spelling out, now you had me searching all over :/ Urgh what a mess..