Skip to content

Commit 74093e4

Browse files
committed
applications: sdp: mspi: RX no copy
Added no copy functionality to RX. Signed-off-by: Michal Frankiewicz <[email protected]>
1 parent 01f672c commit 74093e4

File tree

1 file changed

+8
-3
lines changed
  • applications/sdp/mspi/src

1 file changed

+8
-3
lines changed

applications/sdp/mspi/src/main.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -453,10 +453,15 @@ static void ep_recv(const void *data, size_t len, void *priv)
453453
break;
454454
case NRFE_MSPI_TXRX: {
455455
nrfe_mspi_xfer_packet_msg_t *packet = (nrfe_mspi_xfer_packet_msg_t *)data;
456-
num_bytes = packet->num_bytes;
457-
458-
if (num_bytes > 0) {
456+
if (packet->num_bytes > 0) {
457+
#ifdef CONFIG_SDP_MSPI_IPC_NO_COPY
458+
xfer_execute(packet, packet->data);
459+
#else
460+
NRFX_ASSERT(packet->num_bytes <=
461+
CONFIG_SDP_MSPI_MAX_RESPONSE_SIZE - sizeof(uint32_t));
462+
num_bytes = packet->num_bytes;
459463
xfer_execute(packet, response_buffer + sizeof(uint32_t));
464+
#endif
460465
}
461466
break;
462467
}

0 commit comments

Comments
 (0)