初级会员

- 积分
- 73
- 金钱
- 73
- 注册时间
- 2020-5-22
- 在线时间
- 22 小时
|
发表于 2022-7-21 15:59:29
|
显示全部楼层
最大一次是32768个字节
vdev0vring0长度最少为4*MAX_RPMSG_BUF_SIZE
vdev0vring0: vdev0vring0@10040000 {
compatible = "shared-dma-pool";
reg = <0x10040000 0x08000>;
no-map;
};
vdev0vring1: vdev0vring1@10048000 {
compatible = "shared-dma-pool";
reg = <0x10048000 0x08000>;
no-map;
};
vdev0buffer: vdev0buffer@10050000 {
compatible = "shared-dma-pool";
reg = <0x10050000 0x10000>;
no-map;
};
/drives/rpmsg/virtio_rpmsg_bus.c
#define MAX_RPMSG_NUM_BUFS (2)
#define MAX_RPMSG_BUF_SIZE (32768)
#define RPMSG_RESERVED_ADDRESSES (1024)
#define RPMSG_NS_ADDR (53)
M4
Middlewares/Third_Party/OpenAMP/open-amp/lib/include/openamp/rpmsg_virtio.h
#ifndef RPMSG_BUFFER_SIZE
#define RPMSG_BUFFER_SIZE (32768)
#endif
修改STM32MP157AACX_RAM.ld
MEMORY
{
RETRAM_interrupts (xrw) : ORIGIN = 0x00000000, LENGTH = 0x00000600
SRAM1_text (xrw) : ORIGIN = 0x10000000, LENGTH = 128K
SRAM2_data (xrw) : ORIGIN = 0x10020000, LENGTH = 128K
SRAM3_ipc_shm (xrw) : ORIGIN = 0x10040000, LENGTH = 128K
SRAM4 (xrw) : ORIGIN = 0x10060000, LENGTH = 64k
} |
|