From: Arjan van de Ven <arjan@linux.intel.com>
To: Joseph Jezak <josejx@gentoo.org>
Cc: netdev@vger.kernel.org
Subject: Re: [patch] work around/fix deadlock in the bcm43xx driver by making netlink irq safe
Date: Fri, 30 Jun 2006 16:45:44 +0200 [thread overview]
Message-ID: <44A53918.2020700@linux.intel.com> (raw)
In-Reply-To: <44A536BE.6020209@gentoo.org>
Joseph Jezak wrote:
> Can you provide the details to the list? I'll look into getting
> SoftMAC fixed if you do.
>
sure
the basic issue is that bcm43xx does it's rx processing in a softirq, and
holds the bcm->irq_lock during that time. The rx processing calls into the
softmac layer, which in turn calls into netlink.
With this you can get a deadlock that looks like this
cpu 0: user context |cpu1: softirq context
netlink_table_grab takes nl_table_lock as |take bcm->irq_lock in
write_lock_bh, but leaves irqs enabled |bcm43xx_interrupt_tasklet()
|which then in a few steps
|leads to a call to
|bcm43xx_rx
hardirq comes in and the isr tries to take |in bcm43xx_rx, call
bcm->irq_lock but has to wait on cpu 1 |ieee80211_rx_mgt which
|leads to a call to
|wireless_send_event which
|tries to take nl_table_lock
|for read but has to wait
|for cpu0
according to Michael Buesch, the softmac layer should queue the packet
internally for another softirq, similar to what DeviceScape does, so that
the rx softirq can just drop all packets quickly and drop its locks.
next prev parent reply other threads:[~2006-06-30 14:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-30 14:24 [patch] work around/fix deadlock in the bcm43xx driver by making netlink irq safe Arjan van de Ven
[not found] ` <44A536BE.6020209@gentoo.org>
2006-06-30 14:45 ` Arjan van de Ven [this message]
2006-07-08 17:59 ` Larry Finger
2006-07-08 18:32 ` Michael Buesch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=44A53918.2020700@linux.intel.com \
--to=arjan@linux.intel.com \
--cc=josejx@gentoo.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).