All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/9] Add SpacemiT K3 FML13V05 EC keyboard support
@ 2026-11-18  8:57 ` Wang Yang
  0 siblings, 0 replies; 25+ messages in thread
From: Wang Yang @ 2026-11-18  8:57 UTC (permalink / raw)
  To: Yixun Lan, Benson Leung
  Cc: Troy Mitchell, Tzung-Bi Shih, Guenter Roeck, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Paul Walmsley, Palmer Dabbelt,
	Albert Ou, Alexandre Ghiti, Sandie Cao, devicetree,
	chrome-platform, linux-riscv, spacemit, linux-kernel

The DeepComputing FML13V05 uses a ChromeOS-compatible embedded controller
connected through the SpacemiT K3 eSPI peripheral channel. Its internal
keyboard is not available on linux-next without the controller and EC
transport support described in this series.

The EC host command registers are exposed through a memory-mapped,
non-linear peripheral window. This interface cannot use the ordinary
cros_ec_spi message transport directly. Add a K3-specific controller and
EC transport, and reuse the existing ChromeOS EC protocol, MFD and
keyboard drivers. Existing EC core, LPC, SPI, protocol and keyboard C
files and the google,cros-ec binding are unchanged.

The series is based on next-20261116. Patches 1-2 document the controller
and EC bindings; patch 3 adds the controller; patches 4-5 enable Chrome
platform support on RISC-V and add the EC transport; patches 6-8 describe
the pins, controller and board keyboard; patch 9 enables the drivers in
riscv defconfig, with the EC transport and keyboard built as modules.

The controller implementation is ported from the SpacemiT vendor BSP
(revision 29b78afb484b, originally authored by goumin
<min.gou@spacemit.com>). Controller programming and recovery remain
separate from the EC client. The EC transport and compatible are scoped
to K3 because the window layout and controller recovery API are specific
to this hardware. Feedback on the transport split and recovery interface
is welcome.

Validation on an FML13V05 with its internal keyboard, 2026-11-18:
- W=1 cross-build of Image, modules and the board DTB completed. No new
  warnings came from the added drivers.
- Both new bindings and their compiled examples passed schema validation;
  the new examples passed strict DT style checks. The new EC, controller
  and keyboard nodes in the board DTB also passed validation.
- Cold boot and module autoload passed all 20 automatic checks.
- 153 read-only EC queries and three EC module unload/reload cycles
  succeeded. EC firmware was FML13V05-V01.06.
- A/B/C/1/2/Enter, all four arrows and Fn+F1/F2/F7/F8 produced the expected
  28 paired press/release events, with no dropped or held keys and no
  new EC/eSPI errors in the kernel log.

The running test kernel was
7.4.0-rc3-next-20261116-fml13v05-k3-espi+.
Booting the test system required a separate K3 PCIe test module and
USB/NVMe DT additions, which are outside this EC series. Suspend/resume,
EC restart fault injection, full-keymap coverage and long-duration
stability were not tested. A previously observed UEFI reset_system()
failure was not addressed or retested by this series.

Checkpatch reports no errors or CHECK findings. Its four new-file
MAINTAINERS reminders were reviewed: the existing SpacemiT N: pattern
and Chrome EC/DT entries already cover the new paths, so no MAINTAINERS
change is included.

OpenAI Codex assisted the port, patch preparation, review analysis and
test tooling. The work was developed through an iterative session to
port the existing DC-linux/BSP support, keep the common EC implementation
unchanged, use K3-specific naming and bindings, and verify the result on
hardware. Human review was completed before submission; the numbered
patches retain the submitter's existing DCO sign-offs.

Wang Yang (9):
  dt-bindings: bus: Add SpacemiT K3 eSPI controller
  dt-bindings: embedded-controller: Add SpacemiT K3 EC window
  bus: Add SpacemiT K3 eSPI controller support
  platform/chrome: Allow ChromeOS platform support on RISC-V
  platform/chrome: Add SpacemiT K3 eSPI EC transport
  riscv: dts: spacemit: Add K3 eSPI pin group
  riscv: dts: spacemit: Describe the K3 eSPI controller
  riscv: dts: spacemit: Enable the FML13V05 EC keyboard
  riscv: defconfig: Enable the FML13V05 EC keyboard modules

 .../bindings/bus/spacemit,k3-espi.yaml        | 146 ++++
 .../spacemit,k3-cros-ec.yaml                  |  58 ++
 .../spacemit/k3-deepcomputing-fml13v05.dts    | 137 +++
 arch/riscv/boot/dts/spacemit/k3-pinctrl.dtsi  |  24 +
 arch/riscv/boot/dts/spacemit/k3.dtsi          |  31 +
 arch/riscv/configs/defconfig                  |   5 +
 drivers/bus/Kconfig                           |  10 +
 drivers/bus/Makefile                          |   1 +
 drivers/bus/spacemit-k3-espi.c                | 804 ++++++++++++++++++
 drivers/platform/chrome/Kconfig               |  13 +-
 drivers/platform/chrome/Makefile              |   1 +
 drivers/platform/chrome/cros_ec_spacemit_k3.c | 739 ++++++++++++++++
 include/linux/spacemit-k3-espi.h              |  20 +
 13 files changed, 1988 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/devicetree/bindings/bus/spacemit,k3-espi.yaml
 create mode 100644 Documentation/devicetree/bindings/embedded-controller/spacemit,k3-cros-ec.yaml
 create mode 100644 drivers/bus/spacemit-k3-espi.c
 create mode 100644 drivers/platform/chrome/cros_ec_spacemit_k3.c
 create mode 100644 include/linux/spacemit-k3-espi.h


base-commit: 749a4de370409464cf8501ec5b2451df45c84eb4
-- 
2.43.0

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

end of thread, other threads:[~2026-11-18  9:25 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-18  8:57 [PATCH 0/9] Add SpacemiT K3 FML13V05 EC keyboard support Wang Yang
2026-11-18  8:57 ` Wang Yang
2026-11-18  8:57 ` [PATCH 1/9] dt-bindings: bus: Add SpacemiT K3 eSPI controller Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  9:18   ` sashiko-bot
2026-11-18  8:57 ` [PATCH 2/9] dt-bindings: embedded-controller: Add SpacemiT K3 EC window Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  8:57 ` [PATCH 3/9] bus: Add SpacemiT K3 eSPI controller support Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  9:23   ` sashiko-bot
2026-11-18  8:57 ` [PATCH 4/9] platform/chrome: Allow ChromeOS platform support on RISC-V Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  8:57 ` [PATCH 5/9] platform/chrome: Add SpacemiT K3 eSPI EC transport Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  8:57 ` [PATCH 6/9] riscv: dts: spacemit: Add K3 eSPI pin group Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  9:08   ` sashiko-bot
2026-11-18  8:57 ` [PATCH 7/9] riscv: dts: spacemit: Describe the K3 eSPI controller Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  9:25   ` sashiko-bot
2026-11-18  8:57 ` [PATCH 8/9] riscv: dts: spacemit: Enable the FML13V05 EC keyboard Wang Yang
2026-11-18  8:57   ` Wang Yang
2026-11-18  9:20   ` sashiko-bot
2026-11-18  8:57 ` [PATCH 9/9] riscv: defconfig: Enable the FML13V05 EC keyboard modules Wang Yang
2026-11-18  8:57   ` Wang Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.