From: David Miller <davem@davemloft.net>
To: tom@herbertland.com
Cc: jchapman@katalix.com, netdev@vger.kernel.org
Subject: Re: [PATCH net-next] kcm: do not attach sockets if sk_user_data is already used
Date: Tue, 16 Jan 2018 14:00:52 -0500 (EST) [thread overview]
Message-ID: <20180116.140052.88231511056432866.davem@davemloft.net> (raw)
In-Reply-To: <CALx6S35gZbfY-SwLjrvdazMWAMpC+fVhO8+O7C0QzoVaTdtKjg@mail.gmail.com>
From: Tom Herbert <tom@herbertland.com>
Date: Tue, 16 Jan 2018 09:36:41 -0800
> sk_user_data is set with the sk_callback lock held in code below.
> Should be able to take the lock earlier can do this check under the
> lock.
csock, and this csk, is obtained from an arbitrary one of the
process's FDs. It can be any socket type or family, and that socket's
family might set sk_user_data without the callback lock.
The only socket type check is making sure it is not another PF_KCM
socket. So that doesn't help with this problem.
next prev parent reply other threads:[~2018-01-16 19:00 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-14 11:32 [PATCH net-next] kcm: do not attach sockets if sk_user_data is already used James Chapman
2018-01-16 10:44 ` Guillaume Nault
2018-01-16 17:10 ` Eric Dumazet
2018-01-16 17:36 ` Tom Herbert
2018-01-16 19:00 ` David Miller [this message]
2018-01-17 11:13 ` James Chapman
2018-01-17 19:25 ` David Miller
2018-01-18 15:18 ` Guillaume Nault
2018-01-18 15:40 ` James Chapman
2018-01-18 16:29 ` Guillaume Nault
2018-01-18 17:30 ` James Chapman
2018-01-18 17:46 ` Tom Herbert
2018-01-18 18:08 ` Eric Dumazet
2018-01-18 19:26 ` Tom Herbert
2018-01-18 19:46 ` Eric Dumazet
2018-01-18 17:40 ` Tom Herbert
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=20180116.140052.88231511056432866.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=jchapman@katalix.com \
--cc=netdev@vger.kernel.org \
--cc=tom@herbertland.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;
as well as URLs for NNTP newsgroup(s).