Re: 2.5.74 / oops with ppp_synctty and local_bh_enable

Paul Fulghum (paulkf@microgate.com)
Mon, 7 Jul 2003 10:47:48 -0500


> I'm using the Alcatel SpeedTouch modem. It is working fine. :-)
> Meanwhile, when the pppd process is killed, the following oops appears.
> ...
> Jul 6 15:30:04 tigre01 kernel: Badness in local_bh_enable at
kernel/softirq.c:109
> Jul 6 15:30:04 tigre01 kernel: Call Trace:
> Jul 6 15:30:04 tigre01 kernel: [<c0129265>] local_bh_enable+0x85/0xa0
> Jul 6 15:30:04 tigre01 kernel: [<e982fe73>] ppp_sync_push+0xd3/0x280
[ppp_synctty]
> Jul 6 15:30:04 tigre01 kernel: [<e982f768>] ppp_sync_wakeup+0x28/0x60
[ppp_synctty]
> Jul 6 15:30:04 tigre01 kernel: [<c0226e32>] do_tty_hangup+0x492/0x560

The problem is that do_tty_hangup() in tty_io.h calls the
write wakeup callback with disabled interrupts. The
notes in this function question the validity of disabling
interrupts at that point. I'm not familiar enough with the
locking issues for this function to comment.

At some point ppp_synctty.c was changed to use
spin_lock_bh and spin_unlock_bh in the write wakeup callback.
These macros complain when called with interrupts disabled.

Perhaps changing ppp_synctty.c to use spin_lock_irqsave
and spin_lock_irqrestore is the best fix.

Paul Fulghum, paulkf@microgate.com
Microgate Corporation, www.microgate.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/