* [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support
@ 2026-11-27 6:53 Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 1/2] dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible Binbin Zhou
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Binbin Zhou @ 2026-11-27 6:53 UTC (permalink / raw)
To: Binbin Zhou, Huacai Chen, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Greg Kroah-Hartman, Jiri Slaby, Haowei Zheng
Cc: Huacai Chen, Xuerui Wang, loongarch, devicetree, linux-serial,
Binbin Zhou
Hi all:
This series add UART support for Loongson-2K3000.
Thanks.
Binbin
========
V2:
- Add Reviewed-by tag;
- Remove the original patch for the Loongson-2K0300 UART;
- Add ls2k3000-uart to the existing enum instead of adding a separate
two-item block.
Link to V1:
https://lore.kernel.org/all/cover.1793776192.git.zhoubinbin@loongson.cn/
Binbin Zhou (2):
dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible
serial: 8250_loongson: Add Loongson-2K3000 UART support
Documentation/devicetree/bindings/serial/8250.yaml | 1 +
drivers/tty/serial/8250/8250_loongson.c | 7 +++++++
2 files changed, 8 insertions(+)
base-commit: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4
--
2.52.0
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH v2 1/2] dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible
2026-11-27 6:53 [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support Binbin Zhou
@ 2026-11-27 6:53 ` Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 2/2] serial: 8250_loongson: Add Loongson-2K3000 UART support Binbin Zhou
2026-11-27 6:57 ` [PATCH v2 0/2] serial: 8250: " sashiko-bot
2 siblings, 0 replies; 4+ messages in thread
From: Binbin Zhou @ 2026-11-27 6:53 UTC (permalink / raw)
To: Binbin Zhou, Huacai Chen, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Greg Kroah-Hartman, Jiri Slaby, Haowei Zheng
Cc: Huacai Chen, Xuerui Wang, loongarch, devicetree, linux-serial,
Binbin Zhou
The Loongson-2K3000 UART does not require MCR/MSR signal inversion,
unlike earlier Loongson UARTs. Add a dedicated compatible so the driver
can distinguish it from the existing Loongson UART variants.
Reviewed-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Haowei Zheng <zhenghaowei@loongson.cn>
Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn>
---
Documentation/devicetree/bindings/serial/8250.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/serial/8250.yaml b/Documentation/devicetree/bindings/serial/8250.yaml
index 50d5c977afa3..166cb7995b09 100644
--- a/Documentation/devicetree/bindings/serial/8250.yaml
+++ b/Documentation/devicetree/bindings/serial/8250.yaml
@@ -137,6 +137,7 @@ properties:
- ti,da830-uart
- loongson,ls2k0500-uart
- loongson,ls2k1500-uart
+ - loongson,ls2k3000-uart
- const: ns16550a
- items:
- enum:
--
2.52.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH v2 2/2] serial: 8250_loongson: Add Loongson-2K3000 UART support
2026-11-27 6:53 [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 1/2] dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible Binbin Zhou
@ 2026-11-27 6:53 ` Binbin Zhou
2026-11-27 6:57 ` [PATCH v2 0/2] serial: 8250: " sashiko-bot
2 siblings, 0 replies; 4+ messages in thread
From: Binbin Zhou @ 2026-11-27 6:53 UTC (permalink / raw)
To: Binbin Zhou, Huacai Chen, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Greg Kroah-Hartman, Jiri Slaby, Haowei Zheng
Cc: Huacai Chen, Xuerui Wang, loongarch, devicetree, linux-serial,
Binbin Zhou
The Loongson-2K3000 UART differs from earlier Loongson UARTs in that it
does not require MCR/MSR signal inversion. It also supports a fractional
baud rate divisor.
Add the corresponding OF match entry for `loongson,ls2k3000-uart` so the
driver can probe with the new driver data.
Reviewed-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Haowei Zheng <zhenghaowei@loongson.cn>
Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn>
---
drivers/tty/serial/8250/8250_loongson.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/tty/serial/8250/8250_loongson.c b/drivers/tty/serial/8250/8250_loongson.c
index 6d06ed28382d..0458a9f82d86 100644
--- a/drivers/tty/serial/8250/8250_loongson.c
+++ b/drivers/tty/serial/8250/8250_loongson.c
@@ -43,6 +43,12 @@ static const struct loongson_uart_ddata ls2k1500_uart_data = {
.msr_invert = 0,
};
+static const struct loongson_uart_ddata ls2k3000_uart_data = {
+ .has_frac = true,
+ .mcr_invert = 0,
+ .msr_invert = 0,
+};
+
struct loongson_uart_priv {
struct uart_8250_port *uport;
struct clk *clk;
@@ -216,6 +222,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(loongson_uart_pm_ops, loongson_uart_suspend,
static const struct of_device_id loongson_uart_of_ids[] = {
{ .compatible = "loongson,ls2k0500-uart", .data = &ls2k0500_uart_data },
{ .compatible = "loongson,ls2k1500-uart", .data = &ls2k1500_uart_data },
+ { .compatible = "loongson,ls2k3000-uart", .data = &ls2k3000_uart_data },
{ },
};
MODULE_DEVICE_TABLE(of, loongson_uart_of_ids);
--
2.52.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support
2026-11-27 6:53 [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 1/2] dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 2/2] serial: 8250_loongson: Add Loongson-2K3000 UART support Binbin Zhou
@ 2026-11-27 6:57 ` sashiko-bot
2 siblings, 0 replies; 4+ messages in thread
From: sashiko-bot @ 2026-11-27 6:57 UTC (permalink / raw)
To: Binbin Zhou; +Cc: linux-serial
Sashiko has reviewed this 2-patch series and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1795761142.git.zhoubinbin@loongson.cn
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-11-27 6:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-27 6:53 [PATCH v2 0/2] serial: 8250: Add Loongson-2K3000 UART support Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 1/2] dt-bindings: serial: 8250: Document Loongson-2K3000 UART compatible Binbin Zhou
2026-11-27 6:53 ` [PATCH v2 2/2] serial: 8250_loongson: Add Loongson-2K3000 UART support Binbin Zhou
2026-11-27 6:57 ` [PATCH v2 0/2] serial: 8250: " sashiko-bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox