From: sashiko-bot@kernel.org
To: "James Hilliard" <james.hilliard1@gmail.com>
Cc: linux-serial@vger.kernel.org, devicetree@vger.kernel.org,
linux-sunxi@lists.linux.dev, robh@kernel.org,
conor+dt@kernel.org
Subject: Re: [PATCH v10 08/11] serial: 8250_dw: configure the Allwinner H616 UART
Date: Fri, 04 Dec 2026 10:50:01 +0000 [thread overview]
Message-ID: <sashiko-outbox-249631@kernel.org> (raw)
In-Reply-To: <20261204-submit-h616-uart-fifo-v1-v10-8-1a9fb4f79635@gmail.com>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Low] serial: 8250_dw: undocumented omission of DMA setup in
dw8250_sunxi_setup()
--
commit 750893605157ada7473d330ea8fa77963781e099
Author: James Hilliard <james.hilliard1@gmail.com>
serial: 8250_dw: configure the Allwinner H616 UART
This commit adds Allwinner H616 platform data and a dw8250_sunxi_setup()
callback to configure the 256-byte FIFO, RX trigger thresholds, automatic
flow control, software RS485, and SKIP_SET_RATE quirk.
> diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
> index a20adb38e0466..7695755666bcb 100644
> --- a/drivers/tty/serial/8250/8250_dw.c
> +++ b/drivers/tty/serial/8250/8250_dw.c
[ ... ]
> @@ -657,6 +658,31 @@ static int dw8250_setup(struct uart_port *p)
> return dw8250_setup_dma(p);
> }
>
> +static int dw8250_sunxi_setup(struct uart_port *p)
> +{
> + struct dw8250_data *data = to_dw8250_data(p->private_data);
> + struct uart_8250_port *up = up_to_u8250p(p);
> + int ret;
> +
> + p->type = PORT_16550A;
> + p->flags |= UPF_FIXED_TYPE;
> + p->fifosize = data->pdata->fifo_size;
> +
> + up->capabilities = UART_CAP_FIFO | UART_CAP_NOTEMT | UART_CAP_AFE;
> +
> + ret = dw8250_setup_rxtrig(p);
> + if (ret)
> + return ret;
> +
> + /* Use software RS485 with the Allwinner register layout */
> + p->rs485_config = serial8250_em485_config;
> + p->rs485_supported = serial8250_em485_supported;
> + up->rs485_start_tx = serial8250_em485_start_tx;
> + up->rs485_stop_tx = serial8250_em485_stop_tx;
> +
> + return 0;
> +}
[Severity: Low]
Should dw8250_sunxi_setup() or the commit message note that DMA setup is
intentionally omitted?
Other setup paths in 8250_dw.c call dw8250_setup_dma(), and the H616 UART
nodes in sun50i-h616.dtsi declare DMA channels. Without a brief comment
explaining that sunxi stays in PIO mode, a later change could mistake
this for an oversight and attach 8250_dma.
Enabling DMA against sun6i-dma would break H616 UART RX:
sun6i_dma_tx_status() never returns DMA_PAUSED after sun6i_dma_pause(),
causing serial8250_rx_dma_flush() to drop RX data, and a 256-byte FIFO
yields maxburst = 64, which hits an out-of-range shift in find_burst_size().
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261204-submit-h616-uart-fifo-v1-v10-0-1a9fb4f79635@gmail.com?part=8
next prev parent reply other threads:[~2026-12-04 10:50 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-04 10:28 [PATCH v10 00/11] serial: 8250_dw: share RX trigger setup and describe Allwinner UARTs James Hilliard
2026-12-04 10:28 ` [PATCH v10 01/11] serial: 8250_dw: allow port setup to report errors James Hilliard
2026-12-04 10:28 ` [PATCH v10 02/11] serial: 8250_dw: select port setup through platform data James Hilliard
2026-12-04 10:28 ` [PATCH v10 03/11] serial: 8250: widen RX trigger byte counts to 16 bits James Hilliard
2026-12-04 10:46 ` sashiko-bot
2026-12-04 10:28 ` [PATCH v10 04/11] serial: 8250: share the RX trigger conversion helper James Hilliard
2026-12-04 10:28 ` [PATCH v10 05/11] serial: 8250: expose RX trigger controls for custom callbacks James Hilliard
2026-12-04 10:28 ` [PATCH v10 06/11] serial: 8250_dw: derive RX trigger thresholds from the FIFO depth James Hilliard
2026-12-04 10:52 ` sashiko-bot
2026-12-04 10:28 ` [PATCH v10 07/11] dt-bindings: serial: snps-dw-apb-uart: add Allwinner H616 James Hilliard
2026-12-04 10:28 ` [PATCH v10 08/11] serial: 8250_dw: configure the Allwinner H616 UART James Hilliard
2026-12-04 10:50 ` sashiko-bot [this message]
2026-12-04 10:28 ` [PATCH v10 09/11] dt-bindings: serial: snps-dw-apb-uart: add Allwinner A523 James Hilliard
2026-12-04 10:28 ` [PATCH v10 10/11] serial: 8250_dw: discover Allwinner A523 FIFO depths through FCC James Hilliard
2026-12-04 10:28 ` [PATCH v10 11/11] serial: 8250_dw: configure RX trigger thresholds for Octeon James Hilliard
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=sashiko-outbox-249631@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=james.hilliard1@gmail.com \
--cc=linux-serial@vger.kernel.org \
--cc=linux-sunxi@lists.linux.dev \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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