From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S942666AbcJ1SrG (ORCPT ); Fri, 28 Oct 2016 14:47:06 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:48123 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S942296AbcJ1SrF (ORCPT ); Fri, 28 Oct 2016 14:47:05 -0400 Date: Fri, 28 Oct 2016 20:44:27 +0200 (CEST) From: Thomas Gleixner To: Oleg Nesterov cc: Andy Lutomirski , Roman Pen , Andy Lutomirski , Peter Zijlstra , Ingo Molnar , Tejun Heo , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH 0/2] kthread: make struct kthread kmalloc'ed In-Reply-To: <20161028161106.GA8933@redhat.com> Message-ID: References: <20161025110508.9052-1-roman.penyaev@profitbricks.com> <20161025140333.GB4326@redhat.com> <20161025154301.GA12015@redhat.com> <20161026141359.GA6893@redhat.com> <20161026155155.GA28832@redhat.com> <20161028161106.GA8933@redhat.com> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 28 Oct 2016, Oleg Nesterov wrote: > On 10/26, Thomas Gleixner wrote: > > > Be careful with anonymous unions. There are a few pitfalls with older > > compilers. That's why I said make it a proper union and fixup the 5 usage > > sites. > > Ah. Then I'd prefer to do this later or in a separate change, unless you > feel strongly. I certainly do not want to update other users at least right > now. > > Yes, these 2 type casts do not look nice, but they are hidden in the trivial > helpers. And, for example, if something goes wrong we can trivially change > this code to use, say, sas_ss_sp. Just we need to update the comments to > explain why it is safe too. > > Finally. I still hope we will kill struct kthread (I mean, unbloat it and > embed into task_struct), and this means that the proper union should touch > more members. Say, sas_* and/or vfork_done+set/clear_child_tid. I'd like > to do this only once if possible. Fair enough. Thanks, tglx