From: Tuo Li <islituo@gmail.com>
To: Markus Elfring <Markus.Elfring@web.de>,
netdev@vger.kernel.org, Andrew Lunn <andrew@lunn.ch>,
Ayush Sawal <ayush.sawal@chelsio.com>,
"David S. Miller" <davem@davemloft.net>,
Dragos Tatulea <dtatulea@nvidia.com>,
Eric Dumazet <edumazet@google.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Mina Almasry <almasrymina@google.com>,
Simon Horman <horms@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>, Jia-Ju Bai <baijiaju1990@gmail.com>
Subject: Re: [PATCH] chcr_ktls: fix a possible null-pointer dereference in chcr_ktls_dev_add()
Date: Thu, 14 Nov 2024 18:37:01 +0800 [thread overview]
Message-ID: <1fcd2645-e280-4505-aa75-f5a6510b5940@gmail.com> (raw)
In-Reply-To: <55a08c90-df62-41cd-8ab9-89dc8199fbfb@web.de>
On 2024/11/8 23:00, Markus Elfring wrote:
> …
>> Consider the following execution scenario:
>>
>> chcr_ktls_cpl_act_open_rpl() //641
>> u_ctx = adap->uld[CXGB4_ULD_KTLS].handle; //686
>> if (u_ctx) { //687
>> complete(&tx_info->completion); //704
>>
>> The variable u_ctx is checked by an if statement at Line 687, which means
>> it can be NULL. Then, complete() is called at Line 704, which will wake
>> up wait_for_completion_xxx().
> …
>
> To which software revision would you like to refer here?
>
> How does the presented information fit to a statement like the following?
> https://elixir.bootlin.com/linux/v6.12-rc6/source/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c#L442
>
> if (u_ctx && u_ctx->detach)
> goto out;
We have run our tool on Linux 6.11, and the line numbers correspond to the
code in that version.
> Would you eventually like to trace the control flow back any further
> for the data structure member “handle”?
>
I have traced the control flow further for the data structure member
'handle,' but I have not found where the member is assigned a NULL value. I
am not sure if I might have overlooked something.
next prev parent reply other threads:[~2024-11-14 10:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-30 13:23 Tuo Li
2024-11-04 16:07 ` Simon Horman
2024-11-04 23:32 ` Tuo Li
2024-11-08 13:34 ` Simon Horman
2024-11-14 10:30 ` Tuo Li
2024-11-08 15:00 ` Markus Elfring
2024-11-14 10:37 ` Tuo Li [this message]
2024-11-14 12:26 ` Markus Elfring
2024-11-14 14:22 ` Tuo Li
2024-11-15 9:15 ` Markus Elfring
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=1fcd2645-e280-4505-aa75-f5a6510b5940@gmail.com \
--to=islituo@gmail.com \
--cc=Markus.Elfring@web.de \
--cc=almasrymina@google.com \
--cc=andrew@lunn.ch \
--cc=ayush.sawal@chelsio.com \
--cc=baijiaju1990@gmail.com \
--cc=davem@davemloft.net \
--cc=dtatulea@nvidia.com \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jacob.e.keller@intel.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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
all inboxes | Powered by JetHome®