public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v6 0/3] uart: Introduce uart driver for the Loongson family
@ 2025-10-11  7:16 Binbin Zhou
  2025-10-11  7:16 ` [PATCH v6 1/3] dt-bindings: serial: 8250: Add Loongson uart compatible Binbin Zhou
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Binbin Zhou @ 2025-10-11  7:16 UTC (permalink / raw)
  To: Binbin Zhou, Huacai Chen, Greg Kroah-Hartman, Jiri Slaby,
	Haowei Zheng
  Cc: Huacai Chen, Xuerui Wang, loongarch, ilpo.jarvinen, linux-serial,
	Binbin Zhou

Hi all:

For various reasons, I will be taking over from Haowei and continuing to
push forward with this patch set. Thanks to Haowei for his efforts so
far.

This patchset introduce a generic UART framework driver for Loongson family.
It can be found on Loongson3 series cpus, Loongson-2K series cpus and Loongson 
LS7A bridge chips.

Thanks.

------
V6:
Patch-1:
 - Add Conor's Acked-by tag, thanks.

Patch-2:
 - Add more missing #include;
 - Convert mcr_invert/msr_invert from int to u8;
 - Split serial_fixup() on a preceding line;
 - Add macro definition to avoid magic numbers, such as
   LOONGSON_QUOT_FRAC_MASK;
 - Rework the relevant data structures, where `loongson_uart_ddata`
   represents the Soc's driver_data;
 - Drop `PORT_LOONGSON` and use PORT_16550A instead.
 - devm_platform_get_and_ioremap_resource() instead of platform_get_resource();
 - Use uart_read_port_properties() and parse the clock attributes;
 - Use switch-case instead of if-else in serial_fixup().

Link to V5:
https://lore.kernel.org/all/cover.1758676290.git.zhoubinbin@loongson.cn/

V5:
Patch-1:
 - Since the Loongson UART is NS8250A-compatible, simply add ls2k* compatible to 8250.yaml.

DTS{i} tested by `make dtbs_check W=1`

Link to V4:
https://lore.kernel.org/all/cover.1757318368.git.zhoubinbin@loongson.cn/

V4:
Patch-1:
  - Rename binding name from loongson,uart.yaml to
    loongson,ls2k0500-uart.yaml;
  - Drop ls7a compatible;
  - According to the manual, ls3a and ls2k uart are the same, so merge their
    compatible.

Patch-2:
  - Format code;
  - Add the LOONGSON_UART_DLF macro definition to avoid magic numbers;
  - Simplify the code, merge flags and quirks, and remove struct
    loongson_uart_config;
  - Use DEFINE_SIMPLE_DEV_PM_OPS;
  - Drop loongson,ls7a-uart compatible.

Patch-3:
  - Add ls2k* compatible string, and ns16550a as the fallback
    compatible.

Link to V3:
https://lore.kernel.org/all/20240826024705.55474-1-zhenghaowei@loongson.cn/

Binbin Zhou (3):
  dt-bindings: serial: 8250: Add Loongson uart compatible
  serial: 8250: Add Loongson uart driver support
  LoongArch: dts: Add uart new compatible string

 .../devicetree/bindings/serial/8250.yaml      |  14 ++
 arch/loongarch/boot/dts/loongson-2k0500.dtsi  |   2 +-
 arch/loongarch/boot/dts/loongson-2k1000.dtsi  |   2 +-
 arch/loongarch/boot/dts/loongson-2k2000.dtsi  |   2 +-
 drivers/tty/serial/8250/8250_loongson.c       | 238 ++++++++++++++++++
 drivers/tty/serial/8250/Kconfig               |  10 +
 drivers/tty/serial/8250/Makefile              |   1 +
 7 files changed, 266 insertions(+), 3 deletions(-)
 create mode 100644 drivers/tty/serial/8250/8250_loongson.c


base-commit: 0d97f2067c166eb495771fede9f7b73999c67f66
-- 
2.47.3


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-10-31 16:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-11  7:16 [PATCH v6 0/3] uart: Introduce uart driver for the Loongson family Binbin Zhou
2025-10-11  7:16 ` [PATCH v6 1/3] dt-bindings: serial: 8250: Add Loongson uart compatible Binbin Zhou
2025-10-11  7:16 ` [PATCH v6 2/3] serial: 8250: Add Loongson uart driver support Binbin Zhou
2025-10-11  7:16 ` [PATCH v6 3/3] LoongArch: dts: Add uart new compatible string Binbin Zhou
2025-10-16 14:37 ` [PATCH v6 0/3] uart: Introduce uart driver for the Loongson family Huacai Chen
2025-10-31  2:36 ` Binbin Zhou
2025-10-31 16:30   ` Greg Kroah-Hartman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox