[RFC PATCH 00/10] Add RPMsg framework
Tanmay Shah
tanmay.shah at amd.com
Tue Jul 25 16:06:40 CEST 2023
Remote Processor Messaging (RPMsg) framework is used to communicate
with remote processor. RPMsg is a virtio-based messaging bus that
allows U-Boot drivers to communicate with remote processors available
on the system. This patch also introduces new virtio transport layer
driver.
To keep things minimal for now hard-coded endpoint is used in U-Boot
to communicate with remote processor using RPMsg protocol. This will
be modified to use multiple endpoints in future.
U-Boot can't receive interrupts from remote processor as per design.
Hence, user has to know when the data will be available from remote
processor and call rpmsg_recv accordingly. Mostly it will be called
to receive response of query done using rpmsg_send.
Some code is already available to allocate memory for RPMsg however,
that framework is mostly TI platform specific and isn't used by any
other platforms. This series makes sure it does not break
previous code for other platforms. If platforms wants to use this new
framework it is expected to set "support_rpmsg_virtio" flag in
relative remoteproc device's platform data.
Also the framework introduced by this series is ported from the Linux
kernel so other platforms which already support RPMsg in the Linux
kernel can easily use this framework in U-Boot as well.
---
Tanmay Shah (10):
remoteproc: move resource table definition
firmware: zynqmp: move zynqmp_pm_request_node API
remoteproc: add remoteproc virtio transport driver
drivers: add RPMsg framework
rpmsg: add sample client driver
cmd: add rpmsg framework commands
remoteproc: add attach/detach commands
remoteproc: add zynqmp driver
configs: zynqmp: enable remoteproc and rpmsg
configs: sandbox: enable rpmsg
MAINTAINERS | 15 +
arch/sandbox/dts/test.dts | 8 +
cmd/Kconfig | 6 +
cmd/Makefile | 1 +
cmd/remoteproc.c | 14 +-
cmd/rpmsg.c | 61 +++
configs/sandbox_defconfig | 4 +
configs/xilinx_zynqmp_virt_defconfig | 6 +
drivers/Kconfig | 2 +
drivers/Makefile | 1 +
drivers/firmware/firmware-zynqmp.c | 27 ++
drivers/power/domain/zynqmp-power-domain.c | 7 -
drivers/remoteproc/Kconfig | 20 +
drivers/remoteproc/Makefile | 2 +
drivers/remoteproc/rproc-elf-loader.c | 33 --
drivers/remoteproc/rproc-uclass.c | 125 +++++-
drivers/remoteproc/rproc_virtio.c | 422 +++++++++++++++++++++
drivers/remoteproc/xlnx_rproc.c | 411 ++++++++++++++++++++
drivers/rpmsg/Kconfig | 39 ++
drivers/rpmsg/Makefile | 13 +
drivers/rpmsg/rpmsg-uclass.c | 156 ++++++++
drivers/rpmsg/rpmsg_internal.h | 52 +++
drivers/rpmsg/rpmsg_sample_client.c | 63 +++
drivers/rpmsg/sandbox_test_rpmsg.c | 88 +++++
drivers/rpmsg/virtio_rpmsg_bus.c | 384 +++++++++++++++++++
drivers/virtio/virtio-uclass.c | 1 +
drivers/virtio/virtio_ring.c | 16 +
include/dm/uclass-id.h | 1 +
include/remoteproc.h | 130 ++++++-
include/rpmsg.h | 145 +++++++
include/rproc_virtio.h | 33 ++
include/virtio.h | 7 +-
include/virtio_ring.h | 32 ++
include/zynqmp_firmware.h | 30 +-
test/dm/Makefile | 1 +
test/dm/rpmsg.c | 41 ++
36 files changed, 2321 insertions(+), 76 deletions(-)
create mode 100644 cmd/rpmsg.c
create mode 100644 drivers/remoteproc/rproc_virtio.c
create mode 100644 drivers/remoteproc/xlnx_rproc.c
create mode 100644 drivers/rpmsg/Kconfig
create mode 100644 drivers/rpmsg/Makefile
create mode 100644 drivers/rpmsg/rpmsg-uclass.c
create mode 100644 drivers/rpmsg/rpmsg_internal.h
create mode 100644 drivers/rpmsg/rpmsg_sample_client.c
create mode 100644 drivers/rpmsg/sandbox_test_rpmsg.c
create mode 100644 drivers/rpmsg/virtio_rpmsg_bus.c
create mode 100644 include/rpmsg.h
create mode 100644 include/rproc_virtio.h
create mode 100644 test/dm/rpmsg.c
base-commit: 94e7cb181ad6bd25d36a11c58e0df64e9f815888
--
2.25.1
More information about the U-Boot
mailing list