From patchwork Wed May 13 10:42:49 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Pirko X-Patchwork-Id: 471806 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id A157214016A for ; Wed, 13 May 2015 20:43:01 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934035AbbEMKm5 (ORCPT ); Wed, 13 May 2015 06:42:57 -0400 Received: from mail-wi0-f171.google.com ([209.85.212.171]:33822 "EHLO mail-wi0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933478AbbEMKm4 (ORCPT ); Wed, 13 May 2015 06:42:56 -0400 Received: by wicmc15 with SMTP id mc15so75351518wic.1 for ; Wed, 13 May 2015 03:42:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=xCqYqqZ/RTvnTO5FsgW8pDWsmXkvrPaLvvIjZOvAXV0=; b=Is0OsCMWaxFdOUDGTyXT/zteATpqHKTiXoG/QMe2UlujfBDVJ8mxOGuseL4xQASiH2 6bbB81tdfhbndp7gORYBYkMKDUIB5Q6tGL4HnVCngWE7bSfRl6Rht49il074RlCAKFVQ Hf32Lhq2DlFiZjGzoJSvnTx5dcmXf3h2RxvEUoEnbUKr2WO8UAjAeb0j7PKZ3sjaz9AT Z1ZvoUuFeaTGS7892zXee2al9IpLs7MSpIWcZddB3ZRVj0Xu1iAfh+wn40Va07wLTHuX O5MvPWN6kffBD9wQILNUjoWsyUZ8VT0t7imb1nmx7rm0FLr6dCqIXSRNANcY88gzEacS 9UKQ== X-Gm-Message-State: ALoCoQlKua6RRqcJdHThzX96Xxd0aHYYdwSObs2z5gkQ9uuDQYC/QgujmDRMR7HLepTT1rvmbRgj X-Received: by 10.194.109.229 with SMTP id hv5mr39590295wjb.119.1431513775085; Wed, 13 May 2015 03:42:55 -0700 (PDT) Received: from localhost (b.pirko.cz. [31.31.77.168]) by mx.google.com with ESMTPSA id b5sm7391112wiw.8.2015.05.13.03.42.53 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 May 2015 03:42:54 -0700 (PDT) Date: Wed, 13 May 2015 12:42:49 +0200 From: Jiri Pirko To: Or Gerlitz Cc: Scott Feldman , "netdev@vger.kernel.org" Subject: Re: gone with the spring cleanup.. Message-ID: <20150513104249.GB2136@nanopsycho.mtl.com> References: <5553158D.7000108@mellanox.com> <20150513103812.GA2136@nanopsycho.mtl.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20150513103812.GA2136@nanopsycho.mtl.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Wed, May 13, 2015 at 12:38:12PM CEST, jiri@resnulli.us wrote: >Wed, May 13, 2015 at 11:12:45AM CEST, ogerlitz@mellanox.com wrote: >>Hi Scott, Jiri >> >>So, following the spring cleanup, my builder (which turns to have pretty old >>GCC 4.4.6) isn't functional anymore w.r.t net-next... I checked on different >>station and it works on GCC 4.9.2. >> >>I would love us to get this fixed, please let me know if you need more info, >>below is the build verbose command line build error. >> >>Few more pieces of info, changing -std=gnu89to -std=gnu99didn't help. Also >>the command line where it does work (4.9.2) uses -std=gnu89 > >Looks like the problem might be in named structures which suppose to be >anonymous. Would you try following patch: oh, switchdev_obj_vlan and switchdev_obj_ipv4_fib is used in rocker.. So better: --- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/include/net/switchdev.h b/include/net/switchdev.h index 3b217b4..32ce31d 100644 --- a/include/net/switchdev.h +++ b/include/net/switchdev.h @@ -49,24 +49,28 @@ enum switchdev_obj_id { SWITCHDEV_OBJ_IPV4_FIB, }; +struct switchdev_obj_vlan { + u16 flags; + u16 vid_start; + u16 vid_end; +}; + +struct switchdev_obj_ipv4_fib { + u32 dst; + int dst_len; + struct fib_info *fi; + u8 tos; + u8 type; + u32 nlflags; + u32 tb_id; +}; + struct switchdev_obj { enum switchdev_obj_id id; enum switchdev_trans trans; union { - struct switchdev_obj_vlan { /* PORT_VLAN */ - u16 flags; - u16 vid_start; - u16 vid_end; - } vlan; - struct switchdev_obj_ipv4_fib { /* IPV4_FIB */ - u32 dst; - int dst_len; - struct fib_info *fi; - u8 tos; - u8 type; - u32 nlflags; - u32 tb_id; - } ipv4_fib; + struct switchdev_obj_vlan vlan; + struct switchdev_obj_ipv4_fib ipv4_fib; }; };