From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Zhaoyang Yu <2426767509@qq.com>
Cc: gregkh@linuxfoundation.org, jirislaby@kernel.org,
kees@kernel.org, fourier.thomas@gmail.com,
linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org,
gszhai@bjtu.edu.cn, 23120469@bjtu.edu.cn, stable@vger.kernel.org
Subject: Re: [PATCH v2] tty: serial: pch_uart: add check for dma_alloc_coherent()
Date: Tue, 14 Apr 2026 20:13:31 +0300 [thread overview]
Message-ID: <ad51u1C0PWZPdFi3@ashevche-desk.local> (raw)
In-Reply-To: <tencent_E328416B7CFD436F6029F2DF02AD7ED89C08@qq.com>
On Thu, Apr 09, 2026 at 01:41:58PM +0800, Zhaoyang Yu wrote:
> Add a check for dma_alloc_coherent() failure to prevent a potential
> NULL pointer dereference in dma_handle_rx(). Properly release DMA
> channels and the PCI device reference using a goto ladder if the
> allocation fails.
As a fix for backporting it's good enough, ideally should be converted to one
from 8250 family as it was done, for example, for Intel MID (see a history of
8250_mid.c for the details).
FWIW, the HW one may test this on is Intel Minnowboard v1 which uses EG20T PCH.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2026-04-14 17:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-09 5:41 [PATCH v2] tty: serial: pch_uart: add check for dma_alloc_coherent() Zhaoyang Yu
2026-04-14 17:13 ` Andy Shevchenko [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-04-09 5:29 Zhaoyang Yu
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=ad51u1C0PWZPdFi3@ashevche-desk.local \
--to=andriy.shevchenko@linux.intel.com \
--cc=23120469@bjtu.edu.cn \
--cc=2426767509@qq.com \
--cc=fourier.thomas@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=gszhai@bjtu.edu.cn \
--cc=jirislaby@kernel.org \
--cc=kees@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=stable@vger.kernel.org \
/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