2023-12-12 03:53:45 +01:00
|
|
|
############################################################################
|
2024-04-16 10:07:32 +02:00
|
|
|
# drivers/rpmsg/Make.defs
|
2023-12-12 03:53:45 +01:00
|
|
|
#
|
|
|
|
# Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
# contributor license agreements. See the NOTICE file distributed with
|
|
|
|
# this work for additional information regarding copyright ownership. The
|
|
|
|
# ASF licenses this file to you under the Apache License, Version 2.0 (the
|
|
|
|
# "License"); you may not use this file except in compliance with the
|
|
|
|
# License. You may obtain a copy of the License at
|
|
|
|
#
|
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
|
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
|
|
# License for the specific language governing permissions and limitations
|
|
|
|
# under the License.
|
|
|
|
#
|
|
|
|
############################################################################
|
|
|
|
|
|
|
|
# Don't build anything if there is no RPMSG support
|
|
|
|
|
|
|
|
ifeq ($(CONFIG_RPMSG),y)
|
|
|
|
|
|
|
|
CSRCS += rpmsg.c
|
|
|
|
|
2023-12-22 09:09:24 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_PING),y)
|
|
|
|
CSRCS += rpmsg_ping.c
|
|
|
|
endif
|
|
|
|
|
drivers/rpmsg: add rpmsg router support
Rpmsg Router is new rpmsg transport layer, it can router the rpmsg
messages to a cpu that not directly connected with local cpu by Rpmsg,
For the rpmsg services, it is as if there is a real Rpmsg Channel between
the local cpu and the remote cpu.
For examples, there are three cpus: ap, cp and audio.
ap and cp, ap and audio has share memory and be connected by Rpmsg VirtIO,
so ap and cp, ap and audio can communicate with each other by Rpmsg, but
cp can not communicate with audio direclty.
[cp] <-- rpmsg virtio --> [ap] <-- rpmsg virtio --> [audio]
With rpmsg router, the cp can communicate with audip by Rpmsg dereclty because
the router in ap will forward the rpmsg message from cp/audio to audio/cp, like
this:
+<----- rpmsg router --> hub <-- rpmsg router ------>+
| | |
[cp] <-- rpmsg virtio --> [ap] <-- rpmsg virtio --> [audio]
Signed-off-by: yintao <yintao@xiaomi.com>
2024-04-14 07:17:05 +02:00
|
|
|
ifeq ($(CONFIG_RPMSG_ROUTER),y)
|
|
|
|
CSRCS += rpmsg_router_hub.c rpmsg_router_edge.c
|
|
|
|
endif
|
|
|
|
|
2024-01-04 07:10:44 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_PORT),y)
|
|
|
|
CSRCS += rpmsg_port.c
|
|
|
|
CFLAGS += ${INCDIR_PREFIX}$(TOPDIR)$(DELIM)openamp$(DELIM)open-amp$(DELIM)lib
|
|
|
|
endif
|
|
|
|
|
2024-01-23 08:26:37 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_PORT_SPI),y)
|
|
|
|
CSRCS += rpmsg_port_spi.c
|
|
|
|
endif
|
|
|
|
|
2024-06-05 15:50:52 +02:00
|
|
|
ifeq ($(CONFIG_RPMSG_PORT_SPI_SLAVE),y)
|
|
|
|
CSRCS += rpmsg_port_spi_slave.c
|
|
|
|
endif
|
|
|
|
|
2024-01-04 08:05:28 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_PORT_UART),y)
|
|
|
|
CSRCS += rpmsg_port_uart.c
|
|
|
|
endif
|
|
|
|
|
2024-02-06 04:12:15 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_VIRTIO),y)
|
|
|
|
CSRCS += rpmsg_virtio.c
|
|
|
|
CFLAGS += ${INCDIR_PREFIX}$(TOPDIR)$(DELIM)openamp$(DELIM)open-amp$(DELIM)lib
|
|
|
|
endif
|
|
|
|
|
2024-02-23 07:57:40 +01:00
|
|
|
ifeq ($(CONFIG_RPMSG_VIRTIO_IVSHMEM),y)
|
|
|
|
CSRCS += rpmsg_virtio_ivshmem.c
|
|
|
|
endif
|
|
|
|
|
2023-12-12 03:53:45 +01:00
|
|
|
DEPPATH += --dep-path rpmsg
|
|
|
|
VPATH += :rpmsg
|
|
|
|
|
|
|
|
endif
|