From: Joe Malicki <jmalicki@metacarta.com>
To: Jarek Poplawski <jarkao2@o2.pl>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] AF_UNIX recv/shutdown race
Date: Mon, 20 Nov 2006 07:46:27 -0500 [thread overview]
Message-ID: <4561A3A3.7020102@metacarta.com> (raw)
In-Reply-To: <20061120120517.GD1001@ff.dom.local>
Jarek Poplawski wrote:
> On 20-11-2006 00:40, jmalicki@metacarta.com wrote:
> ...
>
>>@@ -650,7 +651,7 @@ static int unix_autobind(struct socket *
>> struct unix_address * addr;
>> int err;
>>
>>- mutex_lock(&u->readlock);
>>+ unix_state_rlock(sk);
>
>
> Here follows:
> err = 0;
> if (u->addr)
> goto out;
>
> err = -ENOMEM;
> addr = kzalloc(sizeof(*addr) + sizeof(short) + 16, GFP_KERNEL);
> if (!addr)
> goto out;
>
> Are you sure you can use spin_lock here?
>
> Jarek P.
You're absolutely right, I was mistaken (was being too blind about
that). I'm testing a new version now that's much more localized that
shouldn't have that problem.
Joe Malicki
prev parent reply other threads:[~2006-11-20 12:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-19 23:40 [PATCH] AF_UNIX recv/shutdown race jmalicki
2006-11-20 12:05 ` Jarek Poplawski
2006-11-20 12:46 ` Joe Malicki [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=4561A3A3.7020102@metacarta.com \
--to=jmalicki@metacarta.com \
--cc=jarkao2@o2.pl \
--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).