All of lore.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: Michael Chan <michael.chan@broadcom.com>
Cc: kbuild-all@01.org, davem@davemloft.net, netdev@vger.kernel.org,
	Sathya Perla <sathya.perla@broadcom.com>
Subject: Re: [PATCH net-next 11/14] bnxt_en: add support for Flower based vxlan encap/decap offload
Date: Mon, 30 Oct 2017 02:22:42 +0800	[thread overview]
Message-ID: <201710300233.CId6BGMS%fengguang.wu@intel.com> (raw)
In-Reply-To: <1509033092-1887-12-git-send-email-michael.chan@broadcom.com>

[-- Attachment #1: Type: text/plain, Size: 5493 bytes --]

Hi Sathya,

I love your patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Michael-Chan/bnxt_en-Updates-for-net-next/20171029-105709
config: x86_64-randconfig-it0-10300113 (attached as .config)
compiler: gcc-4.9 (Debian 4.9.4-2) 4.9.4
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All warnings (new ones prefixed by >>):

   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c: In function 'bnxt_tc_resolve_tunnel_hdrs':
   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:882:10: error: implicit declaration of function 'vlan_dev_priv' [-Werror=implicit-function-declaration]
      struct vlan_dev_priv *vlan = vlan_dev_priv(dst_dev);
             ^
   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:882:32: warning: initialization makes pointer from integer without a cast
      struct vlan_dev_priv *vlan = vlan_dev_priv(dst_dev);
                                   ^
   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:884:11: error: dereferencing pointer to incomplete type
      if (vlan->real_dev != real_dst_dev) {
              ^
   In file included from include/linux/swab.h:4:0,
                    from include/uapi/linux/byteorder/little_endian.h:12,
                    from include/linux/byteorder/little_endian.h:4,
                    from arch/x86/include/uapi/asm/byteorder.h:4,
                    from include/asm-generic/bitops/le.h:5,
                    from arch/x86/include/asm/bitops.h:517,
                    from include/linux/bitops.h:37,
                    from include/linux/kernel.h:10,
                    from include/linux/list.h:8,
                    from include/linux/timer.h:4,
                    from include/linux/netdevice.h:28,
                    from drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:10:
   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:892:39: error: dereferencing pointer to incomplete type
      l2_info->inner_vlan_tci = htons(vlan->vlan_id);
                                          ^
   include/uapi/linux/swab.h:100:54: note: in definition of macro '__swab16'
    #define __swab16(x) (__u16)__builtin_bswap16((__u16)(x))
                                                         ^
   include/linux/byteorder/generic.h:134:21: note: in expansion of macro '__cpu_to_be16'
    #define ___htons(x) __cpu_to_be16(x)
                        ^
   include/linux/byteorder/generic.h:140:18: note: in expansion of macro '___htons'
    #define htons(x) ___htons(x)
                     ^
>> drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:892:29: note: in expansion of macro 'htons'
      l2_info->inner_vlan_tci = htons(vlan->vlan_id);
                                ^
   drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c:893:34: error: dereferencing pointer to incomplete type
      l2_info->inner_vlan_tpid = vlan->vlan_proto;
                                     ^
   cc1: some warnings being treated as errors

vim +/htons +892 drivers/net//ethernet/broadcom/bnxt/bnxt_tc.c

   855	
   856	static int bnxt_tc_resolve_tunnel_hdrs(struct bnxt *bp,
   857					       struct ip_tunnel_key *tun_key,
   858					       struct bnxt_tc_l2_key *l2_info,
   859					       struct net_device *real_dst_dev)
   860	{
   861		struct flowi4 flow = { {0} };
   862		struct net_device *dst_dev;
   863		struct neighbour *nbr;
   864		struct rtable *rt;
   865		int rc;
   866	
   867		flow.flowi4_proto = IPPROTO_UDP;
   868		flow.fl4_dport = tun_key->tp_dst;
   869		flow.daddr = tun_key->u.ipv4.dst;
   870	
   871		rt = ip_route_output_key(dev_net(real_dst_dev), &flow);
   872		if (IS_ERR(rt)) {
   873			netdev_info(bp->dev, "no route to %pI4b", &flow.daddr);
   874			return -EOPNOTSUPP;
   875		}
   876	
   877		/* The route must either point to the real_dst_dev or a dst_dev that
   878		 * uses the real_dst_dev.
   879		 */
   880		dst_dev = rt->dst.dev;
   881		if (is_vlan_dev(dst_dev)) {
   882			struct vlan_dev_priv *vlan = vlan_dev_priv(dst_dev);
   883	
   884			if (vlan->real_dev != real_dst_dev) {
   885				netdev_info(bp->dev,
   886					    "dst_dev(%s) doesn't use PF-if(%s)",
   887					    netdev_name(dst_dev),
   888					    netdev_name(real_dst_dev));
   889				rc = -EOPNOTSUPP;
   890				goto put_rt;
   891			}
 > 892			l2_info->inner_vlan_tci = htons(vlan->vlan_id);
   893			l2_info->inner_vlan_tpid = vlan->vlan_proto;
   894			l2_info->num_vlans = 1;
   895		} else if (dst_dev != real_dst_dev) {
   896			netdev_info(bp->dev,
   897				    "dst_dev(%s) for %pI4b is not PF-if(%s)",
   898				    netdev_name(dst_dev), &flow.daddr,
   899				    netdev_name(real_dst_dev));
   900			rc = -EOPNOTSUPP;
   901			goto put_rt;
   902		}
   903	
   904		nbr = dst_neigh_lookup(&rt->dst, &flow.daddr);
   905		if (!nbr) {
   906			netdev_info(bp->dev, "can't lookup neighbor for %pI4b",
   907				    &flow.daddr);
   908			rc = -EOPNOTSUPP;
   909			goto put_rt;
   910		}
   911	
   912		tun_key->u.ipv4.src = flow.saddr;
   913		tun_key->ttl = ip4_dst_hoplimit(&rt->dst);
   914		neigh_ha_snapshot(l2_info->dmac, nbr, dst_dev);
   915		ether_addr_copy(l2_info->smac, dst_dev->dev_addr);
   916		neigh_release(nbr);
   917		ip_rt_put(rt);
   918	
   919		return 0;
   920	put_rt:
   921		ip_rt_put(rt);
   922		return rc;
   923	}
   924	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 34115 bytes --]

  parent reply	other threads:[~2017-10-29 18:23 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-26 15:51 [PATCH net-next 00/14] bnxt_en: Updates for net-next Michael Chan
2017-10-26 15:51 ` [PATCH net-next 01/14] bnxt_en: Update firmware interface to 1.8.3.1 Michael Chan
2017-10-26 15:51 ` [PATCH net-next 02/14] bnxt_en: Add PCIe device ID for bcm58804 Michael Chan
2017-10-26 15:51 ` [PATCH net-next 03/14] bnxt_en: adding PCI ID for SMARTNIC VF support Michael Chan
2017-10-26 15:51 ` [PATCH net-next 04/14] bnxt_en: Check for zero length value in bnxt_get_nvram_item() Michael Chan
2017-10-26 15:51 ` [PATCH net-next 05/14] bnxt_en: Get firmware package version one time Michael Chan
2017-10-26 15:51 ` [PATCH net-next 06/14] bnxt_en: Optimize .ndo_set_mac_address() for VFs Michael Chan
2017-10-26 15:51 ` [PATCH net-next 07/14] bnxt_en: Check maximum supported MTU from firmware Michael Chan
2017-10-26 15:51 ` [PATCH net-next 08/14] bnxt_en: Add ethtool reset method Michael Chan
2017-10-26 15:51 ` [PATCH net-next 09/14] bnxt_en: Reorganize the coalescing parameters Michael Chan
2017-10-26 15:51 ` [PATCH net-next 10/14] bnxt_en: Refactor and simplify coalescing code Michael Chan
2017-10-26 15:51 ` [PATCH net-next 11/14] bnxt_en: add support for Flower based vxlan encap/decap offload Michael Chan
2017-10-28  3:18   ` Jakub Kicinski
2017-10-28  3:28     ` Michael Chan
2017-10-28  3:32       ` Jakub Kicinski
2017-10-29  8:46   ` kbuild test robot
2017-10-29 18:22   ` kbuild test robot [this message]
2017-10-29 20:15     ` Michael Chan
2017-10-26 15:51 ` [PATCH net-next 12/14] bnxt_en: add hwrm FW cmds for cfa_encap_record and decap_filter Michael Chan
2017-10-26 15:51 ` [PATCH net-next 13/14] bnxt_en: query cfa flow stats periodically to compute 'lastused' attribute Michael Chan
2017-10-26 15:51 ` [PATCH net-next 14/14] bnxt_en: alloc tc_info{} struct only when tc flower is enabled Michael Chan
2017-10-27 15:03 ` [PATCH net-next 00/14] bnxt_en: Updates for net-next David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201710300233.CId6BGMS%fengguang.wu@intel.com \
    --to=lkp@intel.com \
    --cc=davem@davemloft.net \
    --cc=kbuild-all@01.org \
    --cc=michael.chan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=sathya.perla@broadcom.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.