From: Manfred Spraul <manfred@colorfullife.com>
To: Muli Ben-Yehuda <mulix@mulix.org>
Cc: Oliver Neukum <oliver@neukum.name>, linux-kernel@vger.kernel.org
Subject: Re: question on context of kfree_skb()
Date: Mon, 30 Dec 2002 23:32:49 +0100 [thread overview]
Message-ID: <3E10C991.4060807@colorfullife.com> (raw)
Mulix wrote:
>dev_kfree_skb_any() should be called when you could be either
>executing in interrupt context or not.
>
dev_kfree_skb_any() can misdetect the context: You must not use the
function if you hold an irq spinlock and you might be running from BH or
process context.
cpu 1: cpu 2:
acquire one of the networking bh lock
acquire the driver spin_lock_irq()
hardware interrupt
try to acquire the driver irq spinlock
--> spin.
dev_kfree_skb_any(): !in_irq(), calls kfree_skb
kfree_skb tries to acquire the network lock that
cpu 1 owns
--> spin.
And deadlock.
--
Manfred
next reply other threads:[~2002-12-30 22:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-30 22:32 Manfred Spraul [this message]
2002-12-31 0:57 ` question on context of kfree_skb() Oliver Neukum
2002-12-31 9:31 ` Manfred Spraul
-- strict thread matches above, loose matches on Subject: below --
2002-12-30 18:32 Oliver Neukum
2002-12-30 22:26 ` Muli Ben-Yehuda
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=3E10C991.4060807@colorfullife.com \
--to=manfred@colorfullife.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mulix@mulix.org \
--cc=oliver@neukum.name \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.