Date: Fri, 18 Nov 2016 12:37:58 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 214624] [patch] [netgraph] [panic] fix kernel panic due to loading default netgraph modules into INVARIANTS-enabled kernel Message-ID: <bug-214624-8@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D214624 Bug ID: 214624 Summary: [patch] [netgraph] [panic] fix kernel panic due to loading default netgraph modules into INVARIANTS-enabled kernel Product: Base System Version: 11.0-STABLE Hardware: Any OS: Any Status: New Keywords: patch Severity: Affects Some People Priority: --- Component: kern Assignee: freebsd-bugs@FreeBSD.org Reporter: ports@grosbein.net Keywords: patch Created attachment 177140 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D177140&action= =3Dedit make NG_ABI_VERSION depend on options INVARIANTS It is possible currently to load netgraph.ko and other NETGRAPH-related ker= nel modules built without INVARIANTS support into running kernel build with INVARIANS option. However, actual usage of such combination produces kernel panic: panic: hashdestroy: hashtbl 0xc5ffc440 not empty (malloc type netgraph_node) cpuid =3D 0 KDB: stack backtrace: db_trace_self_wrapper(c0a650f2,fffffff3,d,2dac00,63343430,...) at 0xc050580= a =3D db_trace_self_wrapper+0x2a/frame 0xef4c17e8 kdb_backtrace(c0ab3b11,0,c0a64f71,ef4c18b4,0,...) at 0xc07702ed =3D kdb_backtrace+0x2d/frame 0xef4c1850 vpanic(c0a64f71,ef4c18b4,c0a64f71,ef4c18b4,ef4c18b4,...) at 0xc072e055 =3D vpanic+0x115/frame 0xef4c1884 kassert_panic(c0a64f71,c0a64f9b,c5ffc440,c630c296,c630d99c,...) at 0xc072df= 39 =3D kassert_panic+0xd9/frame 0xef4c18a8 hashdestroy(c5ffc440,c630d99c,f,1,f,...) at 0xc076f232 =3D hashdestroy+0x42= /frame 0xef4c18d0 ng_make_node_common(c6414d5c,ef4c1940,531,c63f6080,c63d4358,...) at 0xc6304= 699 =3D ng_make_node_common+0x239/frame 0xef4c1900 ng_make_node(c63d4338,ef4c1940,0,0,0,...) at 0xc630437b =3D ng_make_node+0x8b/frame 0xef4c1920 ng_mkpeer(c63d4378,c63d4338,0,0,0,...) at 0xc63085df =3D ng_mkpeer+0x1f/fra= me 0xef4c1950 ng_apply_item(1,0,1,ef4c19c8,1,...) at 0xc6306a24 =3D ng_apply_item+0x484/f= rame 0xef4c19a8 ng_snd_item(c63f6080,0,c5f49260,0,ef4c1b98,...) at 0xc630636f =3D ng_snd_item+0x3ff/frame 0xef4c19d8 ngc_send(c62faa3c,0,c6337a00,c5f49350,0,...) at 0xc63e518a =3D ngc_send+0x23a/frame 0xef4c1a64 sosend_generic(c62faa3c,c5f49350,ef4c1b18,0,0,...) at 0xc07bc25b =3D sosend_generic+0x3eb/frame 0xef4c1ad8 kern_sendit(c6279350,5,ef4c1ba0,0,0,...) at 0xc07c2d7a =3D kern_sendit+0x29a/frame 0xef4c1b4c sendit(ef4c1ba0,0,28828fb8,0,c5f49350,...) at 0xc07c30bf =3D sendit+0x19f/f= rame 0xef4c1b88 sys_sendto(c6279350,ef4c1c50,c0a58bb0,4,c627a000,...) at 0xc07c2f18 =3D sys_sendto+0x58/frame 0xef4c1bc0 syscall(ef4c1ce8) at 0xc09cc629 =3D syscall+0x399/frame 0xef4c1cdc Xint0x80_syscall() at 0xc09b7efe =3D Xint0x80_syscall+0x2e/frame 0xef4c1cdc Let's make NG_ABI_VERSION depend not on options NETGRAPH_DEBUG only, but on options INVARIANTS too. Attached patch does this. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-214624-8>