Date: Sat, 5 Dec 2009 21:40:03 GMT From: Benjamin Kaduk <kaduk@MIT.EDU> To: freebsd-net@FreeBSD.org Subject: Re: kern/140036: [iwn] [lor] lock order reversal with iwn0_com_lock and iwn0 softc lock Message-ID: <200912052140.nB5Le3FR048933@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/140036; it has been noted by GNATS. From: Benjamin Kaduk <kaduk@MIT.EDU> To: Bernhard Schmidt <bschmidt@techwires.net> Cc: bug-followup@freebsd.org Subject: Re: kern/140036: [iwn] [lor] lock order reversal with iwn0_com_lock and iwn0 softc lock Date: Sat, 5 Dec 2009 16:30:35 -0500 (EST) On Sat, 5 Dec 2009, Benjamin Kaduk wrote: > > I'll update and revert my change to net80211/ieee80211_proto.c and > see what changes. Okay, now I only get a LOR on beacon miss (no panic): lock order reversal: 1st 0xffffff8000309010 iwn0 (network driver) @ /usr/devel/iwn/freebsd/sys/modules/iwn/../../dev/iwn/if_iwn.c:2655 2nd 0xffffff800033d018 iwn0_com_lock (iwn0_com_lock) @ /usr/src/sys/net80211/ieee80211_proto.c:1365 KDB: stack backtrace: db_trace_self_wrapper() at db_trace_self_wrapper+0x2a _witness_debugger() at _witness_debugger+0x2e witness_checkorder() at witness_checkorder+0x81e _mtx_lock_flags() at _mtx_lock_flags+0x78 ieee80211_beacon_miss() at ieee80211_beacon_miss+0x2e iwn_notif_intr() at iwn_notif_intr+0x33a iwn_intr() at iwn_intr+0x334 intr_event_execute_handlers() at intr_event_execute_handlers+0x66 ithread_loop() at ithread_loop+0xb2 fork_exit() at fork_exit+0x12a fork_trampoline() at fork_trampoline+0xe --- trap 0, rip = 0, rsp = 0xffffff803a97ed30, rbp = 0 --- I kind of expect that it's a bad idea to drop the softc lock around the call to ieee80211_beacom_miss() from iwn_notif_intr(), but don't see an easy alternative. More concerning, though, is the firmware error that was logged some twenty seconds after the beacon miss, leaving networking in an unuseable state: firmware error log: error type = "SYSASSERT" (0x00000005) program counter = 0x00001E28 source line = 0x00000696 error data = 0x0000000100000696 branch link = 0x000008FA000008FA interrupt link = 0x000008B200000000 time = 2190683577 driver status: tx ring 0: qid=0 cur=99 queued=0 tx ring 1: qid=1 cur=0 queued=0 tx ring 2: qid=2 cur=0 queued=0 tx ring 3: qid=3 cur=7 queued=0 tx ring 4: qid=4 cur=186 queued=0 tx ring 5: qid=5 cur=0 queued=0 tx ring 6: qid=6 cur=0 queued=0 tx ring 7: qid=7 cur=0 queued=0 tx ring 8: qid=8 cur=0 queued=0 tx ring 9: qid=9 cur=0 queued=0 tx ring 10: qid=10 cur=0 queued=0 tx ring 11: qid=11 cur=0 queued=0 tx ring 12: qid=12 cur=0 queued=0 tx ring 13: qid=13 cur=0 queued=0 tx ring 14: qid=14 cur=0 queued=0 tx ring 15: qid=15 cur=0 queued=0 tx ring 16: qid=16 cur=0 queued=0 tx ring 17: qid=17 cur=0 queued=0 tx ring 18: qid=18 cur=0 queued=0 tx ring 19: qid=19 cur=0 queued=0 rx ring: cur=26 Hm, maybe I should move this to not-this-ticket ... -Ben
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200912052140.nB5Le3FR048933>