<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: RPMSG pingpong sample causes Linux kernel internal error in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1928278#M227135</link>
    <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/237987"&gt;@swf&lt;/a&gt;!&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Unfortunately we don't have the board and we don't have access to the code of that board.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Normally the boards of our partners like avnet take our bsp and they port our software to their boards to provide you new features.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;We only provie software for our evk boards and is the reason that is dificult to provide support is you are not using our boards.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 08 Aug 2024 12:41:56 GMT</pubDate>
    <dc:creator>Chavira</dc:creator>
    <dc:date>2024-08-08T12:41:56Z</dc:date>
    <item>
      <title>RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1921725#M226833</link>
      <description>&lt;P&gt;Hi everyone!&lt;/P&gt;&lt;P&gt;I have a board featuring the i.MX 8M Plus processor and want to use the M7 coprocessor. My board features this SoM: &lt;A href="https://embedded.avnet.com/product/msc-sm2s-imx8plus/" target="_blank"&gt;https://embedded.avnet.com/product/msc-sm2s-imx8plus/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I tried to run the pingpong example , and it seems to work. Here is the dmesg output:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;[  116.002743] remoteproc remoteproc0: powering up imx-rproc
[  116.010377] remoteproc remoteproc0: Booting fw image rpmsg_lite_pingpong_rtos_linux_remote.elf, size 165728
[  116.541483] rproc-virtio rproc-virtio.2.auto: assigned reserved memory node vdevbuffer@55400000
[  116.551365] virtio_rpmsg_bus virtio0: rpmsg host is online
[  116.557457] rproc-virtio rproc-virtio.2.auto: registered virtio0 (type 7)
[  116.564366] remoteproc remoteproc0: remote processor imx-rproc is now up
[  117.552628] virtio_rpmsg_bus virtio0: creating channel rpmsg-openamp-demo-channel addr 0x1e
[  117.561315] imx_rpmsg_pingpong virtio0.rpmsg-openamp-demo-channel.-1.30: new channel: 0x400 -&amp;gt; 0x1e!
[  117.573936] get 1 (src: 0x1e)
[  117.578498] get 3 (src: 0x1e)
.....
[  117.807693] get 101 (src: 0x1e)
[  117.810865] imx_rpmsg_pingpong virtio0.rpmsg-openamp-demo-channel.-1.30: goodbye!
[  117.920808] imx-rproc imx8mp-cm7: imx_rproc_kick: failed (0, err:-62)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, after the pingpong example has run, one I2C bus is kind of broken. No communication is possible until a reboot. E.g. when I try to read the time of a real-time clock on the bus this happens:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;[  128.772966] Internal error: synchronous external abort: 0000000096000210 [#1] PREEMPT SMP
[  128.781179] Modules linked in: imx_rpmsg_pingpong fsl_jr_uio caam_jr caamkeyblob_desc caamhash_desc caamalg_desc crypto_engine authenc libdes crct10dif_ce polyval_ce polyval_generic flexcan rtc_pcf2131 can_dev at24 caam secvio error g_ether fuse
[  128.803011] CPU: 0 PID: 453 Comm: hwclock Not tainted 6.1.36-6.1.36-2.1.0-6.1.36-2.1.0+gd453b3ad570d #1
[  128.812418] Hardware name: MSC SM2S-IMX8MPLUS (DT)
[  128.817216] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[  128.824188] pc : i2c_imx_bus_busy+0x54/0x1a4
[  128.828473] lr : i2c_imx_xfer+0x64/0x350
[  128.832404] sp : ffff80000af83970
[  128.835721] x29: ffff80000af83970 x28: 0000000000000000 x27: 0000000000000037
[  128.842872] x26: 0000000000000001 x25: ffff000005634880 x24: 0000000000068dbc
[  128.850025] x23: 0000000000000000 x22: ffff800009f26000 x21: 0000000000000003
[  128.857177] x20: 00000000ffff5947 x19: 0000000000000000 x18: 0000000000000000
[  128.864331] x17: 0000000000000000 x16: 0000000000000000 x15: 0000000000000000
[  128.871480] x14: 0000000000000000 x13: 0000000000000000 x12: 0000000000000000
[  128.878633] x11: 0000000000000000 x10: 0000000000000000 x9 : 0000000000000000
[  128.885785] x8 : 0000000000000000 x7 : 0000000000000000 x6 : ffff000004097590
[  128.892937] x5 : 0000000000000000 x4 : 0000000000000000 x3 : 000000000000000c
[  128.900086] x2 : ffff80000bbb000c x1 : 0000000000000000 x0 : ffff8000095b8840
[  128.907240] Call trace:
[  128.909691]  i2c_imx_bus_busy+0x54/0x1a4
[  128.913626]  i2c_imx_xfer+0x64/0x350
[  128.917212]  __i2c_transfer+0x15c/0x4c0
[  128.921060]  i2c_transfer+0x60/0x124
[  128.924646]  i2c_transfer_buffer_flags+0x60/0x9c
[  128.929274]  pcf2131_i2c_read+0x34/0xa0 [rtc_pcf2131]
[  128.934350]  _regmap_raw_read+0xdc/0x160
[  128.938283]  regmap_raw_read+0x18c/0x264
[  128.942215]  regmap_bulk_read+0x1b8/0x240
[  128.946235]  pcf2131_rtc_read_time+0x54/0x230 [rtc_pcf2131]
[  128.951825]  __rtc_read_time+0x48/0x12c
[  128.955673]  rtc_read_time+0x3c/0x70
[  128.959258]  rtc_dev_ioctl+0x50c/0x8b0
[  128.963015]  __arm64_sys_ioctl+0xa8/0xf0
[  128.966950]  invoke_syscall+0x48/0x114
[  128.970711]  el0_svc_common.constprop.0+0xd4/0xfc
[  128.975428]  do_el0_svc+0x30/0xd0
[  128.978754]  el0_svc+0x2c/0x84
[  128.981816]  el0t_64_sync_handler+0xbc/0x140
[  128.986094]  el0t_64_sync+0x18c/0x190
[  128.989771] Code: f9421f22 b9400403 1ac322a3 8b030042 (39400042)
[  128.995873] ---[ end trace 0000000000000000 ]---&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When reading the real-time clock or another device on the bus before the pingpong sample has run, everything works normally.&lt;/P&gt;&lt;P&gt;I experience the same behaviour on kernel 5.15 and 6.1, whereas in kernel 5.10 this problem does not occur.&lt;/P&gt;&lt;P&gt;It should be noted that the linux-imx kernel used has a few commits added by AVNET, for the most part adding devicetree files, see &lt;A href="ssh://gitolite@msc-git02.msc-ge.com:9418/thirdparty/linux-imx.git" target="_blank"&gt;ssh://gitolite@msc-git02.msc-ge.com:9418/thirdparty/linux-imx.git&lt;/A&gt; .&lt;/P&gt;&lt;P&gt;I suspect I have set something bad in my devicetree file, but I don't know what. Most of it is copy-pasted from AVNET devicetree files; see the attachment for my dts.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help or input is much appreciated!&lt;/P&gt;&lt;P&gt;Kind regards&lt;/P&gt;</description>
      <pubDate>Wed, 31 Jul 2024 15:23:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1921725#M226833</guid>
      <dc:creator>swf</dc:creator>
      <dc:date>2024-07-31T15:23:46Z</dc:date>
    </item>
    <item>
      <title>Re: RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1921964#M226837</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/237987"&gt;@swf&lt;/a&gt;!&lt;/P&gt;
&lt;P&gt;Thank you for contacting NXP Support!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can´t access to the device trees that you are referring.&lt;/P&gt;
&lt;P&gt;I see you rdevice tree and I noticed some changes compared with our device tree.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can see our device tree in the link below:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/nxp-imx/linux-imx/blob/b586a521770e508d1d440ccb085c7696b9d6d387/arch/arm64/boot/dts/freescale/imx8mp-evk-rpmsg.dts" target="_blank"&gt;https://github.com/nxp-imx/linux-imx/blob/b586a521770e508d1d440ccb085c7696b9d6d387/arch/arm64/boot/dts/freescale/imx8mp-evk-rpmsg.dts&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; For Linux release version L5.15.71-2.2.0 and later, the run prepare_mcore command must&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;run before the bootaux command.&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards!&lt;/P&gt;
&lt;P&gt;Chavira&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Jul 2024 18:33:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1921964#M226837</guid>
      <dc:creator>Chavira</dc:creator>
      <dc:date>2024-07-31T18:33:55Z</dc:date>
    </item>
    <item>
      <title>Re: RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1923245#M226907</link>
      <description>&lt;P&gt;Hi Chavira,&lt;/P&gt;&lt;P&gt;thank you for your answer!&lt;/P&gt;&lt;P&gt;Sorry for the inappropriate devicetree with unknown references. I rewrote it with minimal changes needed for my setup so that its references are easily traceable:&lt;/P&gt;&lt;LI-CODE lang="c"&gt;/dts-v1/;

#include "../../freescale/imx8mp-evk-rpmsg.dts"

// For some reason, imx8mp-evk-rpmsg.dts deletes the i2c3 node, but we need that i2c bus

// redefine i2c3 as done in imx8mp.dtsi
&amp;amp;aips3 {
	i2c3: i2c@30a40000 {
		compatible = "fsl,imx8mp-i2c", "fsl,imx21-i2c";
		#address-cells = &amp;lt;1&amp;gt;;
		#size-cells = &amp;lt;0&amp;gt;;
		reg = &amp;lt;0x30a40000 0x10000&amp;gt;;
		interrupts = &amp;lt;GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH&amp;gt;;
		clocks = &amp;lt;&amp;amp;clk IMX8MP_CLK_I2C3_ROOT&amp;gt;;
		
		// additional properties as added in imx8mp-evk.dts
		clock-frequency = &amp;lt;400000&amp;gt;;
		pinctrl-names = "default";
		pinctrl-0 = &amp;lt;&amp;amp;pinctrl_i2c3&amp;gt;;
		status = "okay";

		// my custom realtime clock on the i2c3 bus
		myrtc: rtc@53 {
		compatible = "nxp,pcf2131";
		reg = &amp;lt;0x53&amp;gt;;
		reset-source;
		};
	};
};&lt;/LI-CODE&gt;&lt;P&gt;As you might have noticed, the i2c3 node is deleted in the devicetree you posted (&lt;A href="https://github.com/nxp-imx/linux-imx/blob/b586a521770e508d1d440ccb085c7696b9d6d387/arch/arm64/boot/dts/freescale/imx8mp-evk-rpmsg.dts#L147" target="_blank"&gt;https://github.com/nxp-imx/linux-imx/blob/b586a521770e508d1d440ccb085c7696b9d6d387/arch/arm64/boot/dts/freescale/imx8mp-evk-rpmsg.dts#L147 &lt;/A&gt;).&lt;/P&gt;&lt;P&gt;I don't know the reason for the deletion, but I need that i2c bus because devices are connected to it, so I simply readded it again.&lt;/P&gt;&lt;P&gt;Unfortunately the behaviour is the same:&lt;/P&gt;&lt;LI-CODE lang="c"&gt;myboard:~$ hwclock -f /dev/rtc1
2024-08-01 19:04:54.563406+02:00
myboard:~$ sudo sh -c "echo imx8mp_m7_TCM_rpmsg_lite_pingpong_rtos_linux_remote.elf &amp;gt; /sys/class/remoteproc/remoteproc0/firmware &amp;amp;&amp;amp; echo start &amp;gt; /sys/class/remoteproc/remoteproc0/state"
myboard:~$ hwclock -f /dev/rtc1&lt;/LI-CODE&gt;&lt;P&gt;and this shell session is unresponsive; in a new shell session the dmesg output gives the i2c error as written in my original post.&lt;/P&gt;&lt;P&gt;Given that it is exactly this i2c3 bus that is causing problems, maybe readding is a bad idea? But how else can I use the devices connected to it?&lt;/P&gt;&lt;P&gt;Thank you for your help!&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 17:12:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1923245#M226907</guid>
      <dc:creator>swf</dc:creator>
      <dc:date>2024-08-01T17:12:18Z</dc:date>
    </item>
    <item>
      <title>Re: RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1923320#M226909</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/237987"&gt;@swf&lt;/a&gt;!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The i2c3 is used by M4 core, we delete the node to change the driver.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The driver used in imx8mp-evk.dts is &lt;STRONG&gt;" "fsl,imx8mp-i2c", "fsl,imx21-i2c"; " &lt;/STRONG&gt; and for imx8mp-evk-rpmsg.dts is &lt;STRONG&gt;" "fsl,i2c-rpbus" ".&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The i2c-rpbus node should define its bus id (which is the node communicating&lt;BR /&gt;with M4) in alias&lt;/P&gt;
&lt;P&gt;"fsl,i2c-rpbus" for I2C bus over RPMSG&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Another thing can I noticed is the driver user for &lt;STRONG&gt;" imx8mp-cm7 "&lt;/STRONG&gt; node in your device tree the driver used is &lt;STRONG&gt;"fsl,imx8mp-cm7" &lt;/STRONG&gt;but should be &lt;STRONG&gt;"fsl,imx8mn-cm7" &lt;/STRONG&gt;like in our device tree.&lt;/P&gt;
&lt;P&gt;In you have the node &lt;STRONG&gt;m4_reserved: &lt;A href="mailto:m4@0x70000000" target="_blank"&gt;m4@0x70000000&lt;/A&gt;&lt;/STRONG&gt;and should be &lt;STRONG&gt;m4_reserved: &lt;A href="mailto:m4@0x80000000" target="_blank"&gt;m4@0x80000000&lt;/A&gt;.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;In general I noticed minimal errors that you need to modify maybe those minimal errors is the root cause.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;if doesn't work please contact to AVNET support, they should have those examples working in their board.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards!&lt;/P&gt;
&lt;P&gt;Chavira&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2024 18:36:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1923320#M226909</guid>
      <dc:creator>Chavira</dc:creator>
      <dc:date>2024-08-01T18:36:09Z</dc:date>
    </item>
    <item>
      <title>Re: RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1927377#M227094</link>
      <description>&lt;P&gt;Hi Chavira,&lt;/P&gt;&lt;P&gt;honestly nothing of the propsed changes helped, but anyway thank you for the help!&lt;/P&gt;&lt;P&gt;I contacted AVNET support now.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kind regards&lt;/P&gt;</description>
      <pubDate>Wed, 07 Aug 2024 12:05:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1927377#M227094</guid>
      <dc:creator>swf</dc:creator>
      <dc:date>2024-08-07T12:05:29Z</dc:date>
    </item>
    <item>
      <title>Re: RPMSG pingpong sample causes Linux kernel internal error</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1928278#M227135</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/237987"&gt;@swf&lt;/a&gt;!&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Unfortunately we don't have the board and we don't have access to the code of that board.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Normally the boards of our partners like avnet take our bsp and they port our software to their boards to provide you new features.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;We only provie software for our evk boards and is the reason that is dificult to provide support is you are not using our boards.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Aug 2024 12:41:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/RPMSG-pingpong-sample-causes-Linux-kernel-internal-error/m-p/1928278#M227135</guid>
      <dc:creator>Chavira</dc:creator>
      <dc:date>2024-08-08T12:41:56Z</dc:date>
    </item>
  </channel>
</rss>

