public inbox for linux-mediatek@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH 0/7] Add MediaTek VCP remoteproc driver support
@ 2026-04-27 11:04 Xiangzhi Tang
  2026-04-27 11:04 ` [PATCH v4 1/7] dt-bindings: remoteproc: Add MediaTek mt8196 VCP binding Xiangzhi Tang
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Xiangzhi Tang @ 2026-04-27 11:04 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Matthias Brugger,
	AngeloGioacchino Del Regno, Xiangzhi Tang
  Cc: linux-remoteproc, devicetree, linux-kernel, linux-arm-kernel,
	linux-mediatek, Project_Global_Chrome_Upstream_Group, Hailong Fan,
	Huayu Zong, Jarried Lin, Justin Yeh, Vince-WL Liu, Xiangzhi Tang

This patch series adds support for the MediaTek Video Companion
Processor (VCP), a RISC-V based coprocessor found on MediaTek SoCs
starting from mt8196. The VCP handles video processing and multimedia
tasks, offloading work from the main CPU cores.

Architecture Overview
=====================

The VCP subsystem consists of several components:

1. Hardware Architecture
   - RISC-V coprocessor with 1-2 harts per core
   - Multi-core capable (mt8196 has 2 VCP cores)
   - Shared SRAM (up to 384KB) partitioned among cores
   - Dedicated power domain for power management
   - Integrated with SoC IOMMU for memory protection

2. Communication Infrastructure
   - 5 hardware mailbox channels for IPI (Inter-Processor Interrupt)
   - Shared memory regions for bulk data transfer
   - IPI routing tables mapping message types to mailboxes
   - Support for both blocking and non-blocking IPI operations

3. Boot and Runtime Management
   - Firmware loaded via remoteproc framework from filesystem
   - Boot sequence coordinated with ARM Trusted Firmware (ATF) via SMC
   - Runtime power management with suspend/resume support
   - Feature registration mechanism for cross-subsystem coordination

Patch Series Structure
======================

[PATCH 1/7] dt-bindings: Device tree binding for mt8196 VCP
[PATCH 2/7] remoteproc: Core VCP remoteproc driver with ATF integration
[PATCH 3/7] firmware: IPC protocol layer for VCP communication
[PATCH 4/7] remoteproc: IPI mailbox initialization and routing
[PATCH 5/7] remoteproc: IPI synchronization mechanism
[PATCH 6/7] remoteproc: Suspend/resume power management
[PATCH 7/7] MAINTAINERS: Add maintainer entry

Differences from MediaTek SCP
==============================

MediaTek SoCs have two types of companion processors:
- SCP (System Companion Processor): Cortex-M based, for system tasks
- VCP (Video Companion Processor): RISC-V based, for multimedia

While both use the remoteproc framework, VCP has distinct characteristics:
- Different ISA (RISC-V vs ARM Cortex-M)
- Different firmware and memory layout
- Different IPC protocol (5 mailboxes vs 1)
- ATF-coordinated boot sequence
- Multi-core capable architecture

Testing
=======

This patch series has been tested on mt8196 development boards with:
- Firmware loading and boot sequence verification
- IPI communication with video encoder/decoder subsystems
- Suspend/resume cycles with multimedia workloads active
- Multi-core VCP configuration
- IOMMU integration with multimedia memory management

Dependencies
============

- Mediatek Power management driver
- MediaTek VCP mailbox driver (MTK_VCP_MBOX)
- ARM SMCCC support for ATF communication
- IOMMU support for memory protection

Checkpatch Status
=================

All patches pass checkpatch.pl with no errors. Warnings about MAINTAINERS
are addressed in the final patch of the series.

Future Work
===========

- Support for additional SoC variants (mt8197, mt8198)
- Enhanced debugging infrastructure (trace, core dump)
- Performance optimizations for IPI latency
- Documentation under Documentation/remoteproc/

Xiangzhi Tang (7):
  dt-bindings: remoteproc: Add MediaTek mt8196 VCP binding
  remoteproc: mediatek: Add VCP remoteproc driver
  firmware: mediatek: Add VCP IPC protocol driver
  remoteproc: mediatek: Add VCP IPI mailbox initialization
  remoteproc: mediatek: Add VCP ipi communication sync mechanism
  remoteproc: mediatek: vcp: Add vcp suspend and resume feature
  MAINTAINERS: Add entry for MediaTek VCP remoteproc driver

 .../bindings/remoteproc/mediatek,mt8196-vcp.yaml   | 166 ++++
 MAINTAINERS                                        |  14 +
 drivers/firmware/Kconfig                           |   9 +
 drivers/firmware/Makefile                          |   1 +
 drivers/firmware/mtk-vcp-ipc.c                     | 481 +++++++++++
 drivers/remoteproc/Kconfig                         |  12 +
 drivers/remoteproc/Makefile                        |   3 +
 drivers/remoteproc/mtk_vcp_common.c                | 881 +++++++++++++++++++++
 drivers/remoteproc/mtk_vcp_common.h                | 281 +++++++
 drivers/remoteproc/mtk_vcp_rproc.c                 | 581 ++++++++++++++
 drivers/remoteproc/mtk_vcp_rproc.h                 |  95 +++
 include/linux/firmware/mediatek/mtk-vcp-ipc.h      | 151 ++++
 include/linux/remoteproc/mtk_vcp_public.h          | 146 ++++
 include/linux/soc/mediatek/mtk_sip_svc.h           |   2 +
 14 files changed, 2823 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/remoteproc/mediatek,mt8196-vcp.yaml
 create mode 100644 drivers/firmware/mtk-vcp-ipc.c
 create mode 100644 drivers/remoteproc/mtk_vcp_common.c
 create mode 100644 drivers/remoteproc/mtk_vcp_common.h
 create mode 100644 drivers/remoteproc/mtk_vcp_rproc.c
 create mode 100644 drivers/remoteproc/mtk_vcp_rproc.h
 create mode 100644 include/linux/firmware/mediatek/mtk-vcp-ipc.h
 create mode 100644 include/linux/remoteproc/mtk_vcp_public.h

-- 
2.46.0



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

end of thread, other threads:[~2026-04-27 13:51 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-27 11:04 [PATCH 0/7] Add MediaTek VCP remoteproc driver support Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 1/7] dt-bindings: remoteproc: Add MediaTek mt8196 VCP binding Xiangzhi Tang
2026-04-27 12:39   ` Rob Herring (Arm)
2026-04-27 13:51   ` Rob Herring
2026-04-27 11:04 ` [PATCH v4 2/7] remoteproc: mediatek: Add VCP remoteproc driver Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 3/7] firmware: mediatek: Add VCP IPC protocol driver Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 4/7] remoteproc: mediatek: Add VCP IPI mailbox initialization Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 5/7] remoteproc: mediatek: Add VCP ipi communication sync mechanism Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 6/7] remoteproc: mediatek: vcp: Add vcp suspend and resume feature Xiangzhi Tang
2026-04-27 11:04 ` [PATCH v4 7/7] MAINTAINERS: Add entry for MediaTek VCP remoteproc driver Xiangzhi Tang

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