From: Jiri Slaby <jirislaby@gmail.com>
To: Andrew Morton <akpm@osdl.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/5] Char: isicom, fix probe race
Date: Tue, 19 Dec 2006 00:48:33 +0100 [thread overview]
Message-ID: <458728D1.9090209@gmail.com> (raw)
In-Reply-To: <20061218152730.0d86c4c7.akpm@osdl.org>
Andrew Morton wrote:
> On Sat, 16 Dec 2006 02:09:48 +0100 (CET)
> Jiri Slaby <jirislaby@gmail.com> wrote:
>
>> isicom, fix probe race
>>
>> Fix two race conditions in the probe function with mutex.
>>
>> ...
>>
>> static int __devinit isicom_probe(struct pci_dev *pdev,
>> const struct pci_device_id *ent)
>> {
>> + static DEFINE_MUTEX(probe_lock);
>
> hm. How can isicom_probe() race with itself? Even with the dreaded
> multithreaded-pci-probing? It's only called once, by a single thread.
>
> Confused.
Yeah, I'm a little bit too now. One of developers want me to do this some time
ago and I did it without deep thinking about that. Now, I did it again and as
you wrote, it's completely unreasonable. Please, throw it
(char-isicom-fix-probe-race.patch) away.
thanks,
--
http://www.fi.muni.cz/~xslaby/ Jiri Slaby
faculty of informatics, masaryk university, brno, cz
e-mail: jirislaby gmail com, gpg pubkey fingerprint:
B674 9967 0407 CE62 ACC8 22A0 32CC 55C3 39D4 7A7E
next prev parent reply other threads:[~2006-12-18 23:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-16 1:09 [PATCH 1/5] Char: isicom, fix locking in isr Jiri Slaby
2006-12-16 1:09 ` [PATCH 4/5] Char: isicom, check card state " Jiri Slaby
2006-12-16 1:09 ` [PATCH 2/5] Char: isicom, fix probe race Jiri Slaby
2006-12-18 23:27 ` Andrew Morton
2006-12-18 23:48 ` Jiri Slaby [this message]
2006-12-16 1:09 ` [PATCH 3/5] Char: isicom, augment card_reset Jiri Slaby
2006-12-16 1:09 ` [PATCH 5/5] Char: isicom, support higher rates Jiri Slaby
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=458728D1.9090209@gmail.com \
--to=jirislaby@gmail.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@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