Date: Thu, 25 May 2017 17:31:58 +0200 From: Vincenzo Maffione <v.maffione@gmail.com> To: Harry Schmalzbauer <freebsd@omnilan.de> Cc: freebsd-net <freebsd-net@freebsd.org> Subject: Re: [panic] netmap(4) and if_lagg(4) Message-ID: <CA%2B_eA9gcMD1QyG35p5UY8kz6n1kF%2B56Arz3q1T8HVBfMv3XN0w@mail.gmail.com> In-Reply-To: <5926EE96.1010000@omnilan.de> References: <58CBCD7A.8060301@omnilan.de> <CA%2B_eA9iCT7evWUcZMA_ViKfrZnSHp3OpBTS5c4iJ9=ZjO-Pfgw@mail.gmail.com> <58CC23F5.7060507@omnilan.de> <CA%2B_eA9iajZOUFsnWKdodN7zMvst8wn0xViM4xxEx%2B41jw_0B3g@mail.gmail.com> <58CFA394.8070901@omnilan.de> <CA%2B_eA9jf_VjcYUZynu5CXx-ps5z7PSxOky=QLpR-miqtxmMU5w@mail.gmail.com> <5926EE96.1010000@omnilan.de>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi, This is a (silly) bug that is not present anymore in the upstream code https://github.com/luigirizzo/netmap/blob/master/sys/dev/netmap/netmap_free= bsd.c#L410-L417 that is txq and rxq for generic adapter cannot be 0. So I would say the problem is outdated code in the FreeBSD version you are using. Which version you are using exactly? Maybe we can try to push a fix. Cheers, Vincenzo 2017-05-25 16:47 GMT+02:00 Harry Schmalzbauer <freebsd@omnilan.de>: > Bez=C3=BCglich Vincenzo Maffione's Nachricht vom 20.03.2017 15:01 (localt= ime): > > 2017-03-20 10:40 GMT+01:00 Harry Schmalzbauer <freebsd@omnilan.de>: > > > >> Bez=C3=BCglich Vincenzo Maffione's Nachricht vom 17.03.2017 22:28 > (localtime): > > =E2=80=A6 > >> I'll try to provide more info about the panic this week. Like discuss= ed > >> offlist, the panic happend on a machine with the mentioned fix (latest > >> stable). > >> Perhaps this panic can be fixed, especialy for the vlan children. > >> > > > > Ok, so if you create a vlan on an interface, and use netmap over the > vlan, > > you get a deterministic crash? Does the crash happen when you start > > transmitting, receiving or both? > > > > Sorry for the long delay. > > I now have a crash dump and could provide more info if someone can > afford having a look at the lagg panic. > The panic with em0.vlan vanisehd with latest -stable (11.1-prerelease), > but using lagg reproducably panics. > > Unread portion of the kernel message buffer: > 066.051358 [ 254] generic_find_num_desc called, in tx 1024 rx 1024 > 066.058166 [ 262] generic_find_num_queues called, in txq 0 rxq 0 > 066.064756 [1673] netmap_interp_ringid deprecated API, old ringid > 0x0 -> ringid 0 reg 1 > > > Fatal trap 12: page fault while in kernel mode > cpuid =3D 1; apic id =3D 01 > fault virtual address =3D 0xc > fault code =3D supervisor read data, page not present > instruction pointer =3D 0x20:0xffffffff80426894 > stack pointer =3D 0x28:0xfffffe03afccb750 > frame pointer =3D 0x28:0xfffffe03afccb770 > code segment =3D base 0x0, limit 0xfffff, type 0x1b > =3D DPL 0, pres 1, long 1, def32 0, gran 1 > processor eflags =3D interrupt enabled, resume, IOPL =3D 0 > current process =3D 12 (irq269: igb0:que 1) > trap number =3D 12 > panic: page fault > cpuid =3D 1 > KDB: stack backtrace: > #0 0xffffffff805d8277 at kdb_backtrace+0x67 > #1 0xffffffff80596d06 at vpanic+0x186 > #2 0xffffffff80596b73 at panic+0x43 > #3 0xffffffff80898472 at trap_fatal+0x322 > #4 0xffffffff808984c9 at trap_pfault+0x49 > #5 0xffffffff80897d06 at trap+0x286 > #6 0xffffffff8087dfa1 at calltrap+0x8 > #7 0xffffffff8069dc50 at vlan_input+0x1f0 > #8 0xffffffff8068eb08 at ether_demux+0x128 > #9 0xffffffff8068f7ab at ether_nh_input+0x31b > #10 0xffffffff806ab3f0 at netisr_dispatch_src+0xa0 > #11 0xffffffff8068edb6 at ether_input+0x26 > #12 0xffffffff8039f808 at igb_rxeof+0x738 > #13 0xffffffff8039ebcf at igb_msix_que+0x10f > #14 0xffffffff8055e66c at intr_event_execute_handlers+0xec > #15 0xffffffff8055e956 at ithread_loop+0xd6 > #16 0xffffffff8055bcc5 at fork_exit+0x85 > #17 0xffffffff8087e4de at fork_trampoline+0xe > Uptime: 1m37s > Dumping 1535 out of 15529 > MB:..2%..11%..21%..31%..41%..51%..61%..71%..81%..91% > =E2=80=A6 > Reading symbols from /usr/lib/debug/boot/kernel/uhid.ko.debug...done. > Loaded symbols for /usr/lib/debug/boot/kernel/uhid.ko.debug > #0 doadump (textdump=3D<value optimized out>) at pcpu.h:222 > 222 pcpu.h: No such file or directory. > in pcpu.h > (kgdb) list *0xffffffff80426894 > 0xffffffff80426894 is in generic_rx_handler > (/usr/local/share/deploy-tools/RELENG_11/src/sys/dev/ > netmap/netmap_generic.c:628). > 623 struct netmap_adapter *na =3D NA(ifp); > 624 struct netmap_generic_adapter *gna =3D (struct > netmap_generic_adapter *)na; > 625 u_int work_done; > 626 u_int rr =3D MBUF_RXQ(m); // receive ring number > 627 > 628 if (rr >=3D na->num_rx_rings) { > 629 rr =3D rr % na->num_rx_rings; // XXX expensive... > 630 } > 631 > 632 /* limit the size of the queue */ > > Thanks, > > -harry > --=20 Vincenzo Maffione
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2B_eA9gcMD1QyG35p5UY8kz6n1kF%2B56Arz3q1T8HVBfMv3XN0w>