From mboxrd@z Thu Jan 1 00:00:00 1970 From: Randy Dunlap Subject: Re: [patch 1/1] lib/test_bpf.c: don't use gcc union shortcut Date: Thu, 22 May 2014 11:01:39 -0700 Message-ID: <537E3B83.5050307@infradead.org> References: <20140522171646.843C831C19E@corp2gmr1-1.hot.corp.google.com> <20140522105849.182e99b7cb973a7ba95375db@linux-foundation.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: "David S. Miller" , Network Development , Daniel Borkmann To: Andrew Morton , Alexei Starovoitov Return-path: Received: from merlin.infradead.org ([205.233.59.134]:51534 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750870AbaEVSBq (ORCPT ); Thu, 22 May 2014 14:01:46 -0400 In-Reply-To: <20140522105849.182e99b7cb973a7ba95375db@linux-foundation.org> Sender: netdev-owner@vger.kernel.org List-ID: On 05/22/2014 10:58 AM, Andrew Morton wrote: > On Thu, 22 May 2014 10:36:40 -0700 Alexei Starovoitov wrote: > >> On Thu, May 22, 2014 at 10:16 AM, wrote: >>> From: Andrew Morton >>> Subject: lib/test_bpf.c: don't use gcc union shortcut >>> >>> Older gcc's (mine is gcc-4.4.4) make a mess of this. >>> >>> lib/test_bpf.c:74: error: unknown field 'insns' specified in initializer >>> lib/test_bpf.c:75: warning: missing braces around initializer >>> lib/test_bpf.c:75: warning: (near initialization for 'tests[0]..insns[0]') >>> lib/test_bpf.c:76: error: extra brace group at end of initializer >>> lib/test_bpf.c:76: error: (near initialization for 'tests[0].') >>> lib/test_bpf.c:76: warning: excess elements in union initializer >>> lib/test_bpf.c:76: warning: (near initialization for 'tests[0].') >>> lib/test_bpf.c:77: error: extra brace group at end of initializer >>> >>> Cc: Alexei Starovoitov >>> Cc: David S. Miller >>> Signed-off-by: Andrew Morton >> >> I didn't know we still want to support such old versions. >> gcc 4.4 was released in 2009. > > Well, gcc-4.4 fails but I don't know about later versions. > >> What is the official cutoff for gcc ? > > We're really slack about tracking this. Documentation/Changes says gcc-3.2! and has some 4.1 and 4.3 testing (and later) in it. -- ~Randy