Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756805AbeAHLOk (ORCPT + 1 other); Mon, 8 Jan 2018 06:14:40 -0500 Received: from mail-wr0-f194.google.com ([209.85.128.194]:37645 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756139AbeAHLOi (ORCPT ); Mon, 8 Jan 2018 06:14:38 -0500 X-Google-Smtp-Source: ACJfBosfBaBGZ9sbSktUZ+goaSwzpd6E/ytWhmov7iS3jLFHSWpH+uk5K9ilfLHTAJGv9h4haL181m7DgGK52T3CZmc= MIME-Version: 1.0 In-Reply-To: References: From: Marco Franchi Date: Mon, 8 Jan 2018 09:14:36 -0200 Message-ID: Subject: Re: WARNING: CPU: 0 PID: 0 at ./include/linux/netfilter.h:233 arp_rcv To: Andy Duan Cc: "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Fabio Estevam , Marco Antonio Franchi , "fw@strlen.de" , "pablo@netfilter.org" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: 2018-01-08 4:32 GMT-02:00 Andy Duan : > From: Marco Franchi Sent: Friday, January 05, 2018 11:03 PM >>Hi, >> >>I am getting the following warning on a imx6ul-evk board running linux-next >>20180105: >> >>[ 9.233290] ------------[ cut here ]------------ >>[ 9.242068] WARNING: CPU: 0 PID: 0 at >>./include/linux/netfilter.h:233 arp_rcv+0x1f8/0x228 >>[ 9.250381] Modules linked in: >>[ 9.253633] CPU: 0 PID: 0 Comm: swapper/0 Not tainted >>4.15.0-rc6-next-20180104-dirty #2 >>[ 9.261764] Hardware name: Freescale i.MX6 Ultralite (Device Tree) >>[ 9.268065] Backtrace: >>[ 9.270719] [] (dump_backtrace) from [] >>(show_stack+0x18/0x1c) >>[ 9.278438] r7:00000000 r6:60000153 r5:00000000 r4:c1079878 >>[ 9.284258] [] (show_stack) from [] >>(dump_stack+0xb4/0xe8) >>[ 9.291641] [] (dump_stack) from [] >>(__warn+0xf0/0x11c) >>[ 9.298763] r9:d8053000 r8:000000e9 r7:00000009 r6:c0da3bdc >>r5:00000000 r4:00000000 >>[ 9.306662] [] (__warn) from [] >>(warn_slowpath_null+0x44/0x50) >>[ 9.314383] r8:d8053000 r7:00000608 r6:c08873f8 r5:000000e9 r4:c0da3bdc >>[ 9.321243] [] (warn_slowpath_null) from [] >>(arp_rcv+0x1f8/0x228) >>[ 9.329215] r6:c0887200 r5:c107ac58 r4:d899b240 >>[ 9.333999] [] (arp_rcv) from [] >>(__netif_receive_skb_core+0x878/0xbd4) >>[ 9.342491] r6:c0887200 r5:c100ac8c r4:d899b240 >>[ 9.347265] [] (__netif_receive_skb_core) from >>[] (__netif_receive_skb+0x2c/0x8c) >>[ 9.356643] r10:00000080 r9:d8053000 r8:e0a26000 r7:c107ab0d >>r6:c1008908 r5:d899b240 >>[ 9.364598] r4:c10099c4 >>[ 9.367288] [] (__netif_receive_skb) from [] >>(netif_receive_skb_internal+0x7c/0x354) >>[ 9.376904] r5:d899b240 r4:c10099c4 >>[ 9.380635] [] (netif_receive_skb_internal) from >>[] (napi_gro_receive+0x88/0xa4) >>[ 9.389918] r8:e0a26000 r7:00000001 r6:d899b240 r5:d899b240 r4:00000003 >>[ 9.396784] [] (napi_gro_receive) from [] >>(fec_enet_rx_napi+0x3a8/0x9b8) >>[ 9.405357] r5:d8054000 r4:00000000 >>[ 9.409093] [] (fec_enet_rx_napi) from [] >>(net_rx_action+0x220/0x334) >>[ 9.417431] r10:dbbdfa00 r9:c1001d94 r8:00000040 r7:0000012c >>r6:ffff8e6b r5:00000001 >>[ 9.425384] r4:d8053710 >>[ 9.428075] [] (net_rx_action) from [] >>(__do_softirq+0x128/0x2a0) >>[ 9.436063] r10:40000003 r9:c1003080 r8:00000100 r7:c100308c >>r6:c1000000 r5:00000003 >>[ 9.444018] r4:00000000 >>[ 9.446708] [] (__do_softirq) from [] >>(irq_exit+0x14c/0x1a8) >>[ 9.454262] r10:e080a000 r9:d8004400 r8:00000001 r7:00000000 >>r6:c1008a98 r5:00000000 >>[ 9.462218] r4:ffffe000 >>[ 9.464911] [] (irq_exit) from [] >>(__handle_domain_irq+0x74/0xe8) >>[ 9.472879] r5:00000000 r4:c0f7cc24 >>[ 9.476614] [] (__handle_domain_irq) from [] >>(gic_handle_irq+0x64/0xc4) >>[ 9.485121] r9:c1028344 r8:c1001e98 r7:00000000 r6:000003ff >>r5:000003eb r4:e080a00c >>[ 9.493016] [] (gic_handle_irq) from [] >>(__irq_svc+0x70/0x98) >>[ 9.500632] Exception stack(0xc1001e98 to 0xc1001ee0) >>[ 9.505822] 1e80: >> 00000001 00000001 >>[ 9.514157] 1ea0: 00000000 c100bf80 25963796 00000002 00000002 >>dbbde5c8 26545294 00000002 >>[ 9.522491] 1ec0: 00000000 c1001f14 c1001eb8 c1001ee8 c01724fc >>c0724464 20000153 ffffffff >>[ 9.530824] r10:00000000 r9:c1000000 r8:26545294 r7:c1001ecc >>r6:ffffffff r5:20000153 >>[ 9.538778] r4:c0724464 >>[ 9.541470] [] (cpuidle_enter_state) from [] >>(cpuidle_enter+0x1c/0x20) >>[ 9.549893] r10:c100f6a8 r9:dbbde5c8 r8:c0f7c5c0 r7:c1008978 >>r6:00000001 r5:c100892c >>[ 9.557857] r4:c1000000 r3:dbbde5c8 >>[ 9.561589] [] (cpuidle_enter) from [] >>(call_cpuidle+0x28/0x44) >>[ 9.569399] [] (call_cpuidle) from [] >>(do_idle+0x1bc/0x230) >>[ 9.576861] [] (do_idle) from [] >>(cpu_startup_entry+0x20/0x24) >>[ 9.584587] r10:c0f63a50 r9:c1008908 r8:c107b480 r7:c1008900 >>r6:c107b480 r5:00000002 >>[ 9.592546] r4:000000c4 r3:c0f75354 >>[ 9.596283] [] (cpu_startup_entry) from [] >>(rest_init+0x210/0x25c) >>[ 9.604372] [] (rest_init) from [] >>(start_kernel+0x390/0x418) >>[ 9.611998] r5:ffffffff r4:c107b4cc >>[ 9.615723] [] (start_kernel) from [<00000000>] ( (null)) >>[ 9.622235] r10:10c5387d r9:410fc075 r8:83000000 r7:00000000 >>r6:10c0387d r5:00000051 >>[ 9.630191] r4:c0f0032c >>[ 9.632851] ---[ end trace 2d5d5f79c0c8da59 ]--- >> >>Does anyone know how to fix it? >> >>Thanks > > If you enable kernel config "CONFIG_NETFILTER_FAMILY_ARP" can fix the warning. > It is introduced by below commit. > > commit 8de98f058360722a1a9febe3970de6dcd4d91513 > Author: Florian Westphal > Date: Thu Dec 7 16:28:26 2017 +0100 > > netfilter: don't allocate space for arp/bridge hooks unless needed > > no need to define hook points if the family isn't supported. > Because we need these hooks for either nftables, arp/ebtables > or the 'call-iptables' hack we have in the bridge layer add two > new dependencies, NETFILTER_FAMILY_{ARP,BRIDGE}, and have the > users select them. > > Signed-off-by: Florian Westphal > Signed-off-by: Pablo Neira Ayuso > > diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h > index ce4e91df..0e46cb4 100644 > --- a/include/linux/netfilter.h > +++ b/include/linux/netfilter.h > @@ -213,12 +213,16 @@ static inline int nf_hook(u_int8_t pf, unsigned int hook, struct net *net, > case NFPROTO_IPV6: > hook_head = rcu_dereference(net->nf.hooks_ipv6[hook]); > break; > +#ifdef CONFIG_NETFILTER_FAMILY_ARP > case NFPROTO_ARP: > hook_head = rcu_dereference(net->nf.hooks_arp[hook]); > break; > +#endif > +#ifdef CONFIG_NETFILTER_FAMILY_BRIDGE > case NFPROTO_BRIDGE: > hook_head = rcu_dereference(net->nf.hooks_bridge[hook]); > break; > +#endif > #if IS_ENABLED(CONFIG_DECNET) > case NFPROTO_DECNET: > hook_head = rcu_dereference(net->nf.hooks_decnet[hook]); Hi Andy, I applied the NETILTER_FAMILY_ARP as suggested and works. Thank you