Need help to set up rpmsg on dalhia board with imx8m-plus

I’m trying to get rpmsg working on a dalhia board with imx8m-plus.
Using the toradex kernel and the provided device tree.
Read all the relevant questions on the forum yet i can’t find a way to get it working.
On the M core side,the example rpmsg string echo program is launched.
When i add the rpmsg_tty module on the linux side, /dev/ttyRPMSG30 is successfully created but the M core still hangs on the call to rpmsg_lite_wait_for_link_up.
I’ll gladly provide missing information if any, hoping we can find a solution to this issue.

Hi @fennecdjay !

Thanks for reaching out to Toradex Community!

Could you please share the output of tdx-info? (reference: Getting Device Information with Tdx-Info | Toradex Developer Center)

Also, please share with more details the steps you took to enable RPMsg.

Did you follow the article Cortex-M RPMsg Guide | Toradex Developer Center?

Best regards,

@henrique.tx sorry for the delay and thanks for the reply.
i did follow the article then proceeded to search in the forums.
here is the output of tdx-info:

Software summary
Bootloader:               U-Boot
Kernel version:           5.15.129-rt67-6.5.0-devel+git.6f32493eb88e #1-TorizonCore SMP PREEMPT_RT Tue Aug 9 12:56:10 UTC 2022
Kernel command line:      root=LABEL=otaroot rootfstype=ext4 quiet logo.nologo vt.global_cursor_default=0 plymouth.ignore-serial-consoles splash fbcon=map:3 ostree=/ostree/boot.1/torizon/a3b4098110644f25cd420e4b2928c25ae1bbe1aafb81c8c702cb326aefcc5d0e/0
Distro name:              NAME="TorizonCore with PREEMPT_RT"
Distro version:           VERSION_ID=6.5.0-devel-20231118150913-build.0
Hostname:                 verdin-imx8mp-07154522

Hardware info
HW model:                 Toradex Verdin iMX8M Plus WB on Verdin Development Board
Toradex version:          0058 V1.0D
Serial number:            07154522
Processor arch:           aarch64

after loading the example string echo program in the m core and booting linux:

root@verdin-imx8mp-07154522:~# modprobe imx-rpmsg-tty
root@verdin-imx8mp-07154522:~# dmesg | grep rpmsg
[    0.056981] imx rpmsg driver is registered.
[    0.515413] virtio_rpmsg_bus virtio0: rpmsg host is online
[    0.516404] virtio_rpmsg_bus virtio0: creating channel rpmsg-virtual-tty-channel-1 addr 0x1e
[   41.501397] imx_rpmsg_tty virtio0.rpmsg-virtual-tty-channel-1.-1.30: new channel: 0x400 -> 0x1e!
[   41.501899] Install rpmsg tty driver!
[   41.507037] rpmsg_tty_cb68 65 6c 6c 6f 20 77 6f 72 6c 64 21              hello world!

this does look ok, yet the m core console is still hanging;
hope these elements shine some light on the problem.

@henrique.tx could you provide any suggestions? I’m also eagerly watching this topic :slight_smile: Thank you

Hi @fennecdjay and @ben!

Sorry for the delay here.

I just followed step-by-step the related articles in the order that we have them on Heterogeneous Multi-core Processing (HMP) Documentation Overview | Toradex Developer Center, which means:

  1. Setting Up MCUXpresso SDK and Toolchain for Cortex-M development | Toradex Developer Center
  2. How to Load Compiled Binaries into Cortex-M | Toradex Developer Center
  3. How to Run a Hello World on the Cortex-M | Toradex Developer Center
  4. Cortex-M RPMsg Guide | Toradex Developer Center
  5. How to Use RemoteProc | Toradex Developer Center

And I have Remoteproc and RPMsg working on my side.
Here is what I am using:

  • Verdin iMX8M Plus Q 4GB WB IT V1.0B
  • Dahlia V1.1C
  • Toradex Reference Minimal Image from BSP 6.4.0 (which is the latest quarterly currently)
    • Instead of Torizon OS
    • Without PREEMPT_RT

Could you, @fennecdjay, to also try on the 6.4.0 instead of 6.5.0?
(@ben , if you are facing the exact same issue, with same software versions and module please try on your side as well)

In the meantime, I will try to reproduce on Torizon OS 6.5.0 (non PREEMPT RT) as well :slight_smile:

Best regards,

1 Like

thanks a lot!!!
will give it a chance tomorrow.
there is one thing i do have a doubt on, concerning the mcore side of things.
are you using the stock example or did you change the uart? (iirc that was one of the concerns in at least one forum post).

Hi @fennecdjay !

As said above, I just followed the articles.

Which currently means: I did not perform a single change to the RPMsg String Echo example from the MCUXpresso. The change was done on the Linux side, to make sure that it won’t take ownership of something used by the Cortex-M. What needs to be done is also explained there :slight_smile:

Best regards,

Hi @fennecdjay !

Now I just tested the same setup, but running Torizon OS 6.5.0 (monthly, non PREEMPT RT) and I also was able to use Remoteproc and execute the RPMsg String Echo demo simply following the related articles (listed above).

Please let us know how it goes for you.

Best regards,

Thanks again for all the infos.
Turns out i couldn’t try it today as there was issue in the docker/google-repo workflow i use.
Will report as soon as i can for sure, hoping it can be tomorrow.

Best regards

i had more some more non related issues yesterday, but finally it got it to work.
Thanks a lot for the assist!

Best regards.

Hi @fennecdjay !

That’s great!

Thanks for the feedback :slight_smile:

Have a nice day!