From: Alexandra Winter <wintera@linux.ibm.com>
To: "D. Wythe" <alibuda@linux.alibaba.com>,
Jeongjun Park <aha310510@gmail.com>,
wenjia@linux.ibm.com, jaka@linux.ibm.com,
tonylu@linux.alibaba.com, guwen@linux.alibaba.com,
gbayer@linux.ibm.com
Cc: davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, dust.li@linux.alibaba.com,
linux-s390@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net,v4] net/smc: prevent NULL pointer dereference in txopt_get
Date: Wed, 14 Aug 2024 15:21:58 +0200 [thread overview]
Message-ID: <64c2d755-eb4b-42fa-befb-c4afd7e95f03@linux.ibm.com> (raw)
In-Reply-To: <e2d56814-0664-4c3a-9d5f-3f32dc15ccd4@linux.alibaba.com>
On 14.08.24 15:11, D. Wythe wrote:
> struct smc_sock { /* smc sock container */
> - struct sock sk;
> + union {
> + struct sock sk;
> + struct inet_sock inet;
> + };
I don't see a path where this breaks, but it looks risky to me.
Is an smc_sock always an inet_sock as well? Then can't you go with smc_sock->inet_sock->sk ?
Or only in the IPPROTO SMC case, and in the AF_SMC case it is not an inet_sock?
next prev parent reply other threads:[~2024-08-14 13:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-14 10:49 [PATCH net,v4] net/smc: prevent NULL pointer dereference in txopt_get Jeongjun Park
2024-08-14 13:11 ` D. Wythe
2024-08-14 13:21 ` Alexandra Winter [this message]
2024-08-14 15:05 ` Jeongjun Park
2024-08-15 2:51 ` D. Wythe
2024-08-15 3:15 ` Jeongjun Park
2024-08-15 6:43 ` D. Wythe
2024-08-15 7:03 ` Alexandra Winter
2024-08-15 7:34 ` D. Wythe
2024-08-15 7:56 ` Alexandra Winter
2024-08-15 8:09 ` D. Wythe
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=64c2d755-eb4b-42fa-befb-c4afd7e95f03@linux.ibm.com \
--to=wintera@linux.ibm.com \
--cc=aha310510@gmail.com \
--cc=alibuda@linux.alibaba.com \
--cc=davem@davemloft.net \
--cc=dust.li@linux.alibaba.com \
--cc=edumazet@google.com \
--cc=gbayer@linux.ibm.com \
--cc=guwen@linux.alibaba.com \
--cc=jaka@linux.ibm.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=tonylu@linux.alibaba.com \
--cc=wenjia@linux.ibm.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