NRF5340 rpmsg_service RX callback in master (app core) seemingly not triggered via interrupt

Hi,

Using NRF Connect  1.6.1 on NRF5340 I have modified hci_rpmsg project to add another endpoint for bidirectional calling between app core and net core. 
I have used the rpgmsg_service sample as a guide.

I can send messages from the app core (master) to the net core and all works as expected. 

However, when sending a message from the net core to the app core, the message is not delivered until the app core next sends a message to the net core.
Once app core sends another message all awaiting messages are delivered. This is a problem because I am send the message from net core based on radio notification and latency is important.

It is as if there is no RX interrupt for the app core. I noticed the following relevant commit in Zephyr from August "

"The IPC drivers rpmsg_service and rpmsg_multi_instance are not
explicitly enabling the RX IPM channel when two different devices are
used for TX and RX. While this could be redundant for some IPM drivers,
in some cases the hardware needs to be enabled before using it.

Add the missing calls to ipm_set_enabled() for both the devices."

So I tried patching the rpmsg_backend.c with the change in that commit

err = ipm_set_enabled(ipm_rx_handle, 1);
	if (err != 0) {
		LOG_ERR("Could not enable IPM interrupts and callbacks for RX");
		return err;
	}

But this made no difference. Maybe there is some other interrupt conflict or configuration that I am missing. The prj.conf entries for master and remote are as in the rpmsg_service sample.

Any help in getting messages from the net core to the app core would be great.

Thanks

Related