<?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: Boot Partition Problem to start M4 as a remote proccessor from A35 in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076422#M158020</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi David&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for examples running M4 from A35 one can look at uboot function&lt;/P&gt;&lt;P&gt;arch_auxiliary_core_up()&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://source.codeaurora.org/external/imx/uboot-imx/tree/arch/arm/mach-imx/imx8/cpu.c?h=imx_v2019.04_4.19.35_1.1.0" title="https://source.codeaurora.org/external/imx/uboot-imx/tree/arch/arm/mach-imx/imx8/cpu.c?h=imx_v2019.04_4.19.35_1.1.0"&gt;cpu.c\imx8\mach-imx\arm\arch - uboot-imx - i.MX U-Boot&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;m4ctrl tool&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://source.codeaurora.org/external/imxsupport/m4ctrl/tree/README.md" title="https://source.codeaurora.org/external/imxsupport/m4ctrl/tree/README.md"&gt;README.md - m4ctrl - M4 Control Tool for i.MX platforms&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sect.2.8 Remote Processor Messaging Linux Manual included in&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.nxp.com/webapp/Download?colCode=L5.4.3_1.0.0_LINUX_DOCS" target="_blank"&gt;Linux 5.4.3_1.0.0 Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Apr 2020 23:12:25 GMT</pubDate>
    <dc:creator>igorpadykov</dc:creator>
    <dc:date>2020-04-08T23:12:25Z</dc:date>
    <item>
      <title>Boot Partition Problem to start M4 as a remote proccessor from A35</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076421#M158019</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Hello,&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;we are currently trying to use the M4 on the iMX8QX as coprocessor over the AP (kernel 4.14.98 is used).&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;For this purpose, mk-image is used to create only the A35 partition and no M4 partition. This partition should be created by the kernel.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;(according to &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-343178" rel="nofollow noopener noreferrer" target="_blank"&gt;i.MX8 Boot process and creating a bootable image)&lt;/A&gt;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;The boot flags are set to 0x00000000 so that no further HW partitioning is performed.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;According to the SCFW Porting Guide SCFW it is the same procedure as in chapter 6.9.3 AP Boots M4.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;In the first step the M4 Binary (TCM) is loaded into memory via uboot command line:&lt;/P&gt;&lt;PRE style="margin: 0in; font-size: 11.0pt;"&gt;load mmc 1:1 0x80280000 /boot/m4_0.bin&lt;/PRE&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Afterwards, netboot is used to start Linux over TFTP/NFS.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;But you can also start the M4 (TCM memory is used) directly with&lt;/P&gt;&lt;PRE style="margin: 0in; font-size: 11.0pt;"&gt;load mmc 1:1 0x80280000 /boot/m4_0.bin ; dcach flush ; bootaux 0x80280000 0&lt;/PRE&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&lt;BR /&gt; On the M4 UART the logs can be viewed.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;In the kernel the partition for the M4 issuccessfully created. The necessary M4 resources are assigned to the M4 partition and a shared memory partition is created (TCM memory is used) . &lt;BR /&gt; All this is done by a kernel module. No error messages are thrown here. The following memory areas are created:&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&lt;/P&gt;&lt;PRE style="margin: 0in; font-size: 11.0pt;"&gt;Memreg 2 0x34000000 -- 0x37ffffff /* TCM for M4 */
Memreg 3 0x70000000 -- 0x7fffffff
Memreg 5 0x400000000 -- 0x43fffffff
Memreg 6 0x880000000 -- 0xfffffffff
Memreg 7 0x92000000 -- 0xffffffff
Memreg 8 0x90000000 -- 0x91ffffff /* shared memory for M4/A45 */
Memreg 9 0x80020000 -- 0x87ffffff
Memreg 10 0x88000000 -- 0x8fffffff /* DDR for M4 */&lt;CODE&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;
&lt;/SPAN&gt;&lt;/CODE&gt;
Memreg 11 0x118000 -- 0x1bffffff&lt;/PRE&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Memreg 2,10 are moved to the M4 partition.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Memreg 8 is the shared memory partition for Linux and M4 for RPMsg. Linux/M4 both have access to it.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;The partition creation and resource allocation is taken from the article (&lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-341481" rel="nofollow noopener noreferrer" target="_blank"&gt;System Controller Firmware 101 - Resource management service&lt;/A&gt;).&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;If the M4 partition is booted with the following command, the function returns without errors but a long error message is displayed (see below).&amp;nbsp;However, the M4 core will not boot and no logs will be output on the M4 UART.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&lt;/P&gt;&lt;PRE style="margin: 0in; margin-left: .375in; font-size: 11.0pt;"&gt;boot_err = sc_pm_boot(ipc,pt_m4_0,SC_R_M4_0_PID0,
0x080280000ULL,SC_R_M4_0_MU_1A,SC_R_SDHC_1);
check_error(boot_err, "sc_pm_boot");&lt;/PRE&gt;&lt;P style="margin: 0in; margin-left: .375in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;The Linux will continue to run and you can still access and use the system over SSH.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Does anybody have an idea what could cause it to fail?&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;In the medium term the goal is to load/start/stop the M4 partition from linux with different firmwares over RemoteProc (lifecycle management) and to exchange data via RPMsg.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;The openAMP framework will be used for this purpose.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Thank you for your answer in advance.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Best regards,&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;David&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Error log when M4 Partition is booted from linux:&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;nbsp; *** ] (3 of 5) A start job is running for…e Resolution (3min 48s / 4min 34s)INFO: task kworker/2:0H:25 blocked for more than 120 seconds.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Not tainted 4.14.98-g111dc05-dirty #34&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;"echo 0 &amp;gt; /proc/sys/kernel/hung_task_timeout_secs" disables this message.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;kworker/2:0H&amp;nbsp;&amp;nbsp;&amp;nbsp; D&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp; 25&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2 0x00000000&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Workqueue: kblockd blk_mq_run_work_fn&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Call trace:&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff000008085344&amp;gt;] __switch_to+0x94/0xd8&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000087d01d4&amp;gt;] __schedule+0x18c/0x4e8&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000087d0568&amp;gt;] schedule+0x38/0xa0&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000085b1bd8&amp;gt;] __mmc_claim_host+0x98/0x210&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000085b1d80&amp;gt;] mmc_get_card+0x30/0x40&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000085c6b4c&amp;gt;] mmc_mq_queue_rq+0x1fc/0x258&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff00000834229c&amp;gt;] blk_mq_dispatch_rq_list+0x31c/0x3a0&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000083463c4&amp;gt;] blk_mq_sched_dispatch_requests+0x1ac/0x228&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff000008340684&amp;gt;] __blk_mq_run_hw_queue+0xa4/0x118&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff000008340758&amp;gt;] blk_mq_run_work_fn+0x60/0x70&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000080b93fc&amp;gt;] process_one_work+0x1d4/0x348&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000080b95b8&amp;gt;] worker_thread+0x48/0x470&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000080bf624&amp;gt;] kthread+0x12c/0x130&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;[&amp;lt;ffff0000080846d8&amp;gt;] ret_from_fork+0x10/0x18&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;INFO: task kworker/0:1:34 blocked for more than 120 seconds.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Not tainted 4.14.98-g111dc05-dirty #34&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;"echo 0 &amp;gt; /proc/sys/kernel/hung_task_timeout_secs" disables this message.&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;kworker/0:1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; D&amp;nbsp;&amp;nbsp;&amp;nbsp; 0&amp;nbsp;&amp;nbsp;&amp;nbsp; 34&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2 0x00000000&lt;/P&gt;&lt;P style="margin: 0in; font-size: 11.0pt;"&gt;Workqueue: events_freezable thermal_zone_device_check&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2020 14:31:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076421#M158019</guid>
      <dc:creator>kauschked</dc:creator>
      <dc:date>2020-04-08T14:31:48Z</dc:date>
    </item>
    <item>
      <title>Re: Boot Partition Problem to start M4 as a remote proccessor from A35</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076422#M158020</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi David&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for examples running M4 from A35 one can look at uboot function&lt;/P&gt;&lt;P&gt;arch_auxiliary_core_up()&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://source.codeaurora.org/external/imx/uboot-imx/tree/arch/arm/mach-imx/imx8/cpu.c?h=imx_v2019.04_4.19.35_1.1.0" title="https://source.codeaurora.org/external/imx/uboot-imx/tree/arch/arm/mach-imx/imx8/cpu.c?h=imx_v2019.04_4.19.35_1.1.0"&gt;cpu.c\imx8\mach-imx\arm\arch - uboot-imx - i.MX U-Boot&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;m4ctrl tool&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://source.codeaurora.org/external/imxsupport/m4ctrl/tree/README.md" title="https://source.codeaurora.org/external/imxsupport/m4ctrl/tree/README.md"&gt;README.md - m4ctrl - M4 Control Tool for i.MX platforms&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sect.2.8 Remote Processor Messaging Linux Manual included in&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.nxp.com/webapp/Download?colCode=L5.4.3_1.0.0_LINUX_DOCS" target="_blank"&gt;Linux 5.4.3_1.0.0 Documentation&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2020 23:12:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076422#M158020</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2020-04-08T23:12:25Z</dc:date>
    </item>
    <item>
      <title>Re: Boot Partition Problem to start M4 as a remote proccessor from A35</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076423#M158021</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Thanks for the very helpful links. That's what we have been looking for!&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Best regards,&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;David&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Apr 2020 09:01:08 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Boot-Partition-Problem-to-start-M4-as-a-remote-proccessor-from/m-p/1076423#M158021</guid>
      <dc:creator>kauschked</dc:creator>
      <dc:date>2020-04-09T09:01:08Z</dc:date>
    </item>
  </channel>
</rss>

