From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752933AbdK3Pzf (ORCPT ); Thu, 30 Nov 2017 10:55:35 -0500 Received: from foss.arm.com ([217.140.101.70]:56640 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752340AbdK3Pze (ORCPT ); Thu, 30 Nov 2017 10:55:34 -0500 Subject: Re: [BUILD FAILURE] nfs4state.c fails to compile with gcc 4.5.4 To: Arnd Bergmann , Andrew Morton Cc: Linus Torvalds , Steven Rostedt , LKML , Trond Myklebust , Anna Schumaker , Christoffer Dall References: <20171129215853.20172851@vmware.local.home> <20171129193927.e4248d8a797b90aa03edd0ff@linux-foundation.org> From: Marc Zyngier Organization: ARM Ltd Message-ID: Date: Thu, 30 Nov 2017 15:55:31 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 30/11/17 12:28, Arnd Bergmann wrote: > On Thu, Nov 30, 2017 at 4:39 AM, Andrew Morton > wrote: >> On Wed, 29 Nov 2017 19:27:45 -0800 Linus Torvalds wrote: >> >>> On Wed, Nov 29, 2017 at 6:58 PM, Steven Rostedt wrote: >>>> >>>> Seems it can't handle the initialization of an anonymous struct within >>>> an anonymous union. >>> >>> I think we've seen this before, and I think there was some trick to >>> make it work with older gcc versions. >>> >>> Maybe the unnamed entry that gets initialized had to be declared >>> first, and the initializer needed an extra set of braces? >>> >>> Something like that. >>> >>> But maybe the answer is just to say "4.5.4 is really old". >>> >>> Doing some log digging gives me >>> >>> ee9d3429c0e4 ("net/sched/sch_red.c: work around gcc-4.4.4 anon >>> union initializer issue") >>> aa4bf44dc851 ("userns: use union in {g,u}idmap struct") >>> 6c09ffd02725 ("irqchip/gic-v4: Fix building with ancient gcc") >>> c848c49a62b3 ("drivers/media/cec/cec-adap.c: fix build with gcc-4.4.4") >>> >>> but they aren't necessarily _exactly_ the same issue. >> >> Yeah, I'm the world expert at working around this gcc bug but the nfs4 >> one had me stumped when I looked at it, so I shelved it for revisiting >> later. >> >> It would be nice to fix it, given that this is the only (known) site in >> the kernel which rules out these compiler versions. > > There are more in drivers/irqchip/irq-gic-v4.c and virt/kvm/arm/vgic/, but > they are not built on x86. I've fixed it before, but it seems to be coming > back each time a new GIC variant gets added. > > If anyone cares, I can find the remaining patches I have for this and > send them again. If you have patches for either GIC or the vgic, I'll happily take them. Thanks, M. -- Jazz is not dead. It just smells funny...