Skip to content

Commit c21b794

Browse files
committed
mbox_ipcc.c: rx_status_t -> mbox_status_t
1 parent bfdc2e4 commit c21b794

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

cores/arduino/stm32/OpenAMP/mbox_ipcc.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,15 @@ virtio_rpmsg_bus.c virtqueue vring rpmsg_virtio
4646
#define IPCC_CPU_M4 REMOTE_CPU_ID
4747

4848
typedef enum {
49-
RX_NO_MSG = 0,
50-
RX_NEW_MSG = 1,
51-
RX_BUF_FREE = 2
52-
} rx_status_t;
49+
MBOX_NO_MSG = 0,
50+
MBOX_NEW_MSG = 1,
51+
MBOX_BUF_FREE = 2
52+
} mbox_status_t;
5353

5454
/* Private variables ---------------------------------------------------------*/
5555
IPCC_HandleTypeDef hipcc;
56-
rx_status_t msg_received_ch1 = RX_NO_MSG;
57-
rx_status_t msg_received_ch2 = RX_NO_MSG;
56+
mbox_status_t msg_received_ch1 = MBOX_NO_MSG;
57+
mbox_status_t msg_received_ch2 = MBOX_NO_MSG;
5858

5959
/* Private function prototypes -----------------------------------------------*/
6060
void IPCC_channel1_callback(IPCC_HandleTypeDef *hipcc, uint32_t ChannelIndex, IPCC_CHANNELDirTypeDef ChannelDir);
@@ -103,16 +103,16 @@ int MAILBOX_Poll(struct virtio_device *vdev, uint32_t vring_id)
103103

104104
switch (vring_id) {
105105
case VRING0_ID:
106-
if (msg_received_ch1 == RX_BUF_FREE) {
106+
if (msg_received_ch1 == MBOX_BUF_FREE) {
107107
core_debug("Running vring0 (ch_1 buf free)\n");
108108
/* This calls rpmsg_virtio_tx_callback(), which actually does nothing. */
109109
rproc_virtio_notified(vdev, VRING0_ID);
110-
msg_received_ch1 = RX_NO_MSG;
110+
msg_received_ch1 = MBOX_NO_MSG;
111111
ret = 0;
112112
}
113113
break;
114114
case VRING1_ID:
115-
if (msg_received_ch2 == RX_NEW_MSG) {
115+
if (msg_received_ch2 == MBOX_NEW_MSG) {
116116
core_debug("Running vring1 (ch_2 new msg)\n");
117117
/**
118118
* This calls rpmsg_virtio_rx_callback(), which calls virt_uart rx callback

0 commit comments

Comments
 (0)