From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934268AbcJ0NtU (ORCPT ); Thu, 27 Oct 2016 09:49:20 -0400 Received: from mx1.redhat.com ([209.132.183.28]:42506 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933084AbcJ0NtR (ORCPT ); Thu, 27 Oct 2016 09:49:17 -0400 Date: Thu, 27 Oct 2016 15:10:28 +0200 From: Oleg Nesterov To: Josh Poimboeuf Cc: Andy Lutomirski , Roman Pen , Andy Lutomirski , Peter Zijlstra , Thomas Gleixner , Ingo Molnar , Tejun Heo , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v3 1/1] kthread: allocate kthread structure using kmalloc Message-ID: <20161027131027.GB1016@redhat.com> References: <20161025110508.9052-1-roman.penyaev@profitbricks.com> <20161025140333.GB4326@redhat.com> <20161025154301.GA12015@redhat.com> <20161026141359.GA6893@redhat.com> <20161027025633.x4suabgcogrualso@treble> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20161027025633.x4suabgcogrualso@treble> User-Agent: Mutt/1.5.18 (2008-05-17) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 27 Oct 2016 13:12:03 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/26, Josh Poimboeuf wrote: > > On Wed, Oct 26, 2016 at 04:14:00PM +0200, Oleg Nesterov wrote: > > +/* > > + * TODO: kill it and use to_kthread(). But we still need the users > > + * like kthread_stop() which has to sync with the exiting kthread. > > + */ > > static struct kthread *to_live_kthread(struct task_struct *k) > > Now that the kthread struct is no longer on the stack, are the > try_get_task_stack() and its corresponding put_task_stack()'s still > needed? It seems you missed this part Of course, with this patch we are ready to remove put_task_stack() from kthread.c right now. The next change should kill to_live_kthread() altogether. in the same email ;) Oleg.