Kernel crash when hardware flow offloading is enabled
Username: BertLammers
Origin: https://bugs.openwrt.org/index.php?do=details&task_id=1994
Using device Xiaomi Mir3G and OpenWrt SNAPSHOT, r8631+22-f381cbcb
Device restarts regularly (on average 1 or 2 times a day) when hardware flow offloading is enabled. The issue don’t seem to occur when only software flow offloading is enabled.
cat /sys/kernel/debug/crashlog:
<3>[394940.982588] CM_ERROR=2002b481 COH_RD_ERR <CCA=5 TR=mmio MCmd=Coherent Read Share STag=0 SPort=1
<3>[394940.982588] >
<3>[394940.992997] CM_ADDR =1c000000
<3>[394940.996034] CM_OTHER=00000000 None
<1>[394940.999504] Data bus error, epc == 80385b78, ra == 803875dc
<4>[394941.005138] Oops[#1]:
<4>[394941.007489] CPU: 2 PID: 0 Comm: swapper/2 Not tainted 4.14.82 #0
<4>[394941.013557] task: 8fc444c0 task.stack: 8fc66000
<4>[394941.018150] $ 0 : 00000000 00000001 0a992c52 00000000
<4>[394941.023448] $ 4 : 8d1e1c10 9c000004 8d1e1c1c 0e1ef713
<4>[394941.028744] $ 8 : 00000001 00c5f000 8fc02e00 00000001
<4>[394941.034042] $12 : 000f087f 86591380 86591380 171e46bc
<4>[394941.039340] $16 : 8086e9c0 80596d80 8fd90fc0 00000003
<4>[394941.044636] $20 : 00000001 00000000 00000000 00000000
<4>[394941.049932] $24 : 00000000 00000001
<4>[394941.055230] $28 : 8fc66000 8fc11cd8 80596d80 803875dc
<4>[394941.060530] Hi : 00926b02
<4>[394941.063478] Lo : 65497170
<4>[394941.066449] epc : 80385b78 ip_send_check+0×50/0×80 <4>[394941.071482] ra : 803875dc
ip_local_out+0x3c/0xc8
<4>[394941.076591] Status: 11007c03 KERNEL EXL
IE
<4>[394941.080849] Cause : 5080001c (ExcCode 07)
<4>[394941.084922] PrId : 0001992f (MIPS 1004Kc)
<4>[394941.089078] Modules linked in: pppoe ppp_async pppox ppp_generic nf_conntrack_ipv6 mt76x2e mt76x2_common mt76x02_lib mt7603e mt76 mac80211 iptable_nat ipt_REJECT ipt_MASQUERADE cfg80211 xt_time xt_tcpudp xt_tcpmss xt_statistic xt_state xt_recent xt_nat xt_multiport xt_mark xt_mac xt_limit xt_length xt_hl xt_helper xt_ecn xt_dscp xt_conntrack xt_connmark xt_connlimit xt_connbytes xt_comment xt_TCPMSS xt_REDIRECT xt_LOG xt_HL xt_FLOWOFFLOAD xt_DSCP xt_CT xt_CLASSIFY wireguard slhc nf_reject_ipv4 nf_nat_redirect nf_nat_masquerade_ipv4 nf_conntrack_ipv4 nf_nat_ipv4 nf_nat nf_log_ipv4 nf_flow_table_hw nf_flow_table nf_defrag_ipv6 nf_defrag_ipv4 nf_conntrack_rtcache iptable_raw iptable_mangle iptable_filter ipt_ECN ip_tables crc_ccitt compat fuse sch_cake nf_conntrack act_skbedit act_mirred em_u32 cls_u32
<4>[394941.159842] cls_tcindex cls_flow cls_route cls_fw sch_tbf sch_htb sch_hfsc sch_ingress ledtrig_usbport ip6t_REJECT nf_reject_ipv6 nf_log_ipv6 nf_log_common ip6table_mangle ip6table_filter ip6_tables x_tables ifb ip6_udp_tunnel udp_tunnel usb_storage leds_gpio xhci_mtk xhci_plat_hcd xhci_pci xhci_hcd sd_mod scsi_mod gpio_button_hotplug usbcore nls_base usb_common
<4>[394941.192038] Process swapper/2 (pid: 0, threadinfo=8fc66000, task=8fc444c0, tls=00000000)
<4>[394941.200176] Stack : 8fd91100 803bba10 8fc11dc8 00000130 8086e9c0 8d453c00 8086e9c0 8d453c00
<4>[394941.208596] 8fd911d8 80388784 8fc11d90 00000000 8086e9c0 80596d80 8fd90fc0 8038768c
<4>[394941.217020] 8086e780 80570000 8e30f214 00000003 8086e780 80570000 8e30f214 803887dc
<4>[394941.225442] 8086e780 80570000 8e30f214 00000003 00000001 803bc430 81231db0 00000000
<4>[394941.233864] 81231d80 805761b8 8fd90fc0 80590000 8fd91030 00000000 00000000 80570000
<4>[394941.242285] ...
<4>[394941.244810] Call Trace:
<4>[394941.247340] [<80385b78>] ip_send_check+0×50/0×80 <4>[394941.252034] [<803875dc>]
ip_local_out+0x3c/0xc8
<4>[394941.256803] [<8038768c>] ip_local_out+0×24/0×78 <4>[394941.261404] [<803887dc>] ip_send_skb+0×14/0x3c
<4>[394941.265925] [<803bc430>] icmp_send+0×420/0x4d4
<4>[394941.270436] [<8037d1fc>] ipv4_link_failure+0×20/0x6c
<4>[394941.275464] [<803b96b8>] arp_error_report+0×40/0×54 <4>[394941.280435] [<80349b40>] neigh_invalidate+0xe0/0×150 <4>[394941.285466] [<8034f990>] neigh_timer_handler+0x1c4/0x2d8
<4>[394941.290859] [<800864f4>] call_timer_fn.isra.3+0×24/0×84 <4>[394941.296146] [<80086710>] run_timer_softirq+0x1bc/0×248 <4>[394941.301368] [<80466058>] __do_softirq+0×128/0x2ec
<4>[394941.306150] [<80032a94>] irq_exit+0xac/0xc8
<4>[394941.310410] [<80243b7c>] plat_irq_dispatch+0xfc/0×138 <4>[394941.315530] [<8000b5e8>] except_vec_vi_end+0xb8/0xc4
<4>[394941.320568] [<8000cfb0>] r4k_wait_irqoff+0x1c/0×24 <4>[394941.325448] [<800665dc>] do_idle+0xe4/0×168 <4>[394941.329698] [<80066858>] cpu_startup_entry+0×24/0x2c
<4>[394941.334740] [<800180b4>] not_nmi+0x8c/0x1d8
<4>[394941.338991] Code: 00481021 8ca30000 24a50004 <00621021> 0043182b 14c5fffb 00431021 00021c00 00621821
<4>[394941.348805]
<4>[394941.350616] —[ end trace 2751015d45562c0d ]—