From: Dan Dennedy <dan@dennedy.org>
To: linux1394-devel@lists.sourceforge.net
Cc: Andy Wingo <wingo@pobox.com>, linux-kernel@vger.kernel.org
Subject: Re: [patch] raw1394: fix locking in the presence of SMP and interrupts
Date: Sun, 9 Oct 2005 11:05:48 -0700 [thread overview]
Message-ID: <200510091105.48336.dan@dennedy.org> (raw)
In-Reply-To: <1128530142.12591.26.camel@localhost.localdomain>
On Wednesday 05 October 2005 09:35 am, Andy Wingo wrote:
> In raw1394.c:handle_iso_listen(), don't grab host_info_lock at all --
> we're not accessing host_info_list or host_count, and holding this lock
> while trying to tasklet_kill the iso tasklet this can cause an ABBA
> deadlock if ohci:dma_rcv_tasklet is running and tries to grab
> host_info_lock in raw1394.c:receive_iso. Test program attached reliably
> deadlocks all SMP machines I have been able to test without this patch.
I have to admit being surprised to see this because I have been using an SMP
machine for a few years and not noticed a consistent or reproducible problem
here. However, I have to admit the majority of my isochronous usage on kernel
2.6 has been using the new API and implementation (aka rawiso and
libiec61883). So, I tested your program on my dual Athlon running a 2.6.12
SMP kernel, and it worked fine a few times when run manually. Then, I put it
into a shell loop:
I="0"; while [ $I -lt 1000 ]; do ./raw1394reader_nothreads; \
echo ran iteration $I; I=`expr $I + 1`; done
Eventually, it did deadlock. So, I applied the patch, and the above looping
test ran fine 3 times.Works for me.
prev parent reply other threads:[~2005-10-09 18:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-05 16:35 [patch] raw1394: fix locking in the presence of SMP and interrupts Andy Wingo
2005-10-09 18:05 ` Dan Dennedy [this message]
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=200510091105.48336.dan@dennedy.org \
--to=dan@dennedy.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux1394-devel@lists.sourceforge.net \
--cc=wingo@pobox.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox