From: Praveen Talari <praveen.talari@oss.qualcomm.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: konrad.dybcio@oss.qualcomm.com, Jiri Slaby <jirislaby@kernel.org>,
chandana.chiluveru@oss.qualcomm.com,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-serial@vger.kernel.org,
Praveen Talari <ptalari@qualcomm.com>
Subject: Re: [PATCH] serial: qcom-geni: Drop unsafe rx_buf realloc from setup_fifos()
Date: Mon, 24 Aug 2026 19:39:38 +0530 [thread overview]
Message-ID: <5d4e4e0b-3180-4ad9-90ad-2cb0482fc87b@oss.qualcomm.com> (raw)
In-Reply-To: <2026082458-lung-knelt-e760@gregkh>
Hi
On 24-08-2026 18:26, Greg Kroah-Hartman wrote:
> On Mon, Aug 24, 2026 at 04:15:14PM +0530, Praveen Talari wrote:
>> The RX buffer is allocated once during probe using a fixed DMA_RX_BUF_SIZE
>> and is DMA-mapped for the lifetime of the port. However, setup_fifos()
>> attempts to reallocate rx_buf whenever the reported RX FIFO depth changes.
>> Since the DMA mapping is not re-established after reallocation, the buffer
>> pointer may change while the DMA engine continues using the stale DMA
>> address. This can result in RX DMA targeting memory that no longer
>> corresponds to the active buffer, leading to invalid DMA accesses and
>> potential memory corruption.
>>
>> The RX FIFO depth is unrelated to the size of rx_buf. The buffer is
>> allocated independently using DMA_RX_BUF_SIZE and all RX DMA paths consume
>> it at that fixed size. As such, resizing the buffer based on FIFO depth
>> changes provides no functional benefit.
>>
>> Signed-off-by: Praveen Talari <ptalari@qualcomm.com>
>> ---
>> Signed-off-by: Praveen Talari <praveen.talari@oss.qualcomm.com>
> Why is this signed-off-by twice, with different email addresses?
Apologies, that was a mistake while updating the commit message. Only
praveen.talari@oss.qualcomm.com should be present for upstream
submissions. I'll fix it in the next revision
Thanks,
Praveen Talari
>
> confused,
>
> greg k-h
prev parent reply other threads:[~2026-08-24 14:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-24 10:45 Praveen Talari
2026-08-24 12:56 ` Greg Kroah-Hartman
2026-08-24 14:09 ` Praveen Talari [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=5d4e4e0b-3180-4ad9-90ad-2cb0482fc87b@oss.qualcomm.com \
--to=praveen.talari@oss.qualcomm.com \
--cc=chandana.chiluveru@oss.qualcomm.com \
--cc=gregkh@linuxfoundation.org \
--cc=jirislaby@kernel.org \
--cc=konrad.dybcio@oss.qualcomm.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=ptalari@qualcomm.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®