From: Jeff Garzik <jgarzik@pobox.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Francois Romieu <romieu@fr.zoreil.com>,
mingo@elte.hu, jgarzik@redhat.com, linux-kernel@vger.kernel.org,
akpm@osdl.org, davem@redhat.com
Subject: Re: [lock validator] drivers/net/8139too.c: deadlock?
Date: Thu, 26 Jan 2006 21:44:37 -0500 [thread overview]
Message-ID: <43D98915.6040004@pobox.com> (raw)
In-Reply-To: <E1F2JFb-0007MW-00@gondolin.me.apana.org.au>
Herbert Xu wrote:
> You've got it.
>
> rx_poll => rtl8139_rx => netif_receive_skb => ... => tcp_v4_rcv
>
> In fact once we're at netif_receive_skb it's easy to see how we'll grab
> xmit_lock again.
>
> Prescription: Move TX timeout handling into a work queue.
This was my recommendation as well.
Using a work queue not only solves this locking problem, but it also
enables the possibility of sleeping, a common operation during the
hardware resets that often occur during ->tx_timeout()
Anyone who wants to make this change in a driver, don't forget that this
could race with other operations, notably dev->stop() or suspend.
Jeff
next prev parent reply other threads:[~2006-01-27 2:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-26 22:43 [lock validator] drivers/net/8139too.c: deadlock? Ingo Molnar
2006-01-27 0:35 ` Francois Romieu
2006-01-27 2:22 ` Herbert Xu
2006-01-27 2:44 ` Jeff Garzik [this message]
2006-01-31 0:24 ` [PATCH] 8139too: fix a TX timeout watchdog thread against NAPI softirq race Francois Romieu
2006-01-31 18:49 ` Ingo Molnar
2006-01-31 18:57 ` Ingo Molnar
2006-02-01 0:55 ` Andrew Morton
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=43D98915.6040004@pobox.com \
--to=jgarzik@pobox.com \
--cc=akpm@osdl.org \
--cc=davem@redhat.com \
--cc=herbert@gondor.apana.org.au \
--cc=jgarzik@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=romieu@fr.zoreil.com \
/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.