From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
To: Dan Carpenter <dan.carpenter@linaro.org>
Cc: Amol Maheshwari <amahesh@qti.qualcomm.com>,
Arnd Bergmann <arnd@arndb.de>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Abel Vesa <abel.vesa@linaro.org>,
Sukrut Bellary <sukrut.bellary@linux.com>,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org,
Shuah Khan <skhan@linuxfoundation.org>
Subject: Re: [PATCH v2] misc: fastrpc: Fix double free of 'buf' in error path
Date: Fri, 16 Aug 2024 09:42:00 +0100 [thread overview]
Message-ID: <7fd85a5d-125c-4d52-bc86-94d98db6de7b@linaro.org> (raw)
In-Reply-To: <a301b77e-b833-482e-afa1-5306bd8fc8e7@stanley.mountain>
On 15/08/2024 10:25, Dan Carpenter wrote:
> On Mon, Jun 12, 2023 at 11:58:01AM +0100, Srinivas Kandagatla wrote:
>>
>> On Fri, 02 Jun 2023 04:36:02 -0700, Sukrut Bellary wrote:
>>> smatch warning:
>>> drivers/misc/fastrpc.c:1926 fastrpc_req_mmap() error: double free of 'buf'
>>>
>>> In fastrpc_req_mmap() error path, the fastrpc buffer is freed in
>>> fastrpc_req_munmap_impl() if unmap is successful.
>>>
>>> But in the end, there is an unconditional call to fastrpc_buf_free().
>>> So the above case triggers the double free of fastrpc buf.
>>>
>>> [...]
>>
>> Applied, thanks!
>>
>> [1/1] misc: fastrpc: Fix double free of 'buf' in error path
>> commit: 5b3006fffce89706a12741d7f657869ca2be1640
>>
>
> This patch wasn't actually applied. I'm not sure what went wrong.
Am not sure either, its now applied!
thanks for checking this.
--srini
>
> regards,
> dan carpenter
>
next prev parent reply other threads:[~2024-08-16 8:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-02 11:36 [PATCH v2] misc: fastrpc: Fix double free of 'buf' in error path Sukrut Bellary
2023-06-12 10:57 ` Srinivas Kandagatla
2023-06-12 10:58 ` Srinivas Kandagatla
2024-08-15 9:25 ` Dan Carpenter
2024-08-16 8:42 ` Srinivas Kandagatla [this message]
2024-08-16 8:42 ` Srinivas Kandagatla
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=7fd85a5d-125c-4d52-bc86-94d98db6de7b@linaro.org \
--to=srinivas.kandagatla@linaro.org \
--cc=abel.vesa@linaro.org \
--cc=amahesh@qti.qualcomm.com \
--cc=arnd@arndb.de \
--cc=dan.carpenter@linaro.org \
--cc=gregkh@linuxfoundation.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=skhan@linuxfoundation.org \
--cc=sukrut.bellary@linux.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