<?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>i.MX ProcessorsのトピックRe: Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337654#M179833</link>
    <description>&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;Thanks for responding, it was indeed helpful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhargava&lt;/P&gt;</description>
    <pubDate>Thu, 09 Sep 2021 09:51:23 GMT</pubDate>
    <dc:creator>Bhargava</dc:creator>
    <dc:date>2021-09-09T09:51:23Z</dc:date>
    <item>
      <title>Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1336857#M179780</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am running Linux on Cotex-A53 and bare-metal application on Cotex-M4. The communication channel used between is shared memory i.e. OCRAM.&lt;/P&gt;&lt;P&gt;If M4 keeps sending or putting data at the OCRAM location the A53 can read all the data that is put by M4 whereas the other way round is not working as expected i.e., if A53 puts data continuously, from the M4 only first data is received and it is read only once, the subsequent read to that particular location results in the value that is read first, the updated data is not read.&lt;/P&gt;&lt;P&gt;Is this the issue at M4 side or A53 side?&lt;/P&gt;&lt;P&gt;Is A53 blocking access to OCRAM for M4?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From Linux application we are mapping OCRAM memory using &lt;STRONG&gt;mmap()&lt;/STRONG&gt;. If mmap() is the problem then what are the alternatives to mmap?&lt;/P&gt;&lt;P&gt;If this is the Cache Coherence problem then how it can be resolved.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kindly support for this issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Additional details:&lt;/P&gt;&lt;P&gt;SoC : iMX8M Mini&lt;/P&gt;&lt;P&gt;Shared memory: OCRAM (0x00910000)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhargava&lt;/P&gt;</description>
      <pubDate>Wed, 08 Sep 2021 12:29:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1336857#M179780</guid>
      <dc:creator>Bhargava</dc:creator>
      <dc:date>2021-09-08T12:29:26Z</dc:date>
    </item>
    <item>
      <title>Re: Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337227#M179798</link>
      <description>&lt;P&gt;Hi Bhargava&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; In M4 core address map, the OCRAM address 0x00900000 belongs to Processor Code bus ( &lt;SPAN class="fontstyle0"&gt;0x0000_0000 - 0x1FFF_FFFF&lt;/SPAN&gt;) and the cache is enabled in LMEM controller.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; So we need to disable code bus cache and buffer in LMEM controller.&lt;/P&gt;
&lt;P&gt;&amp;nbsp; Please try to modify function&amp;nbsp;SystemInit() in system_MIMX8MM6_cm4.c as below:&lt;/P&gt;
&lt;P&gt;// TY comments to disable code bus cache. {&lt;BR /&gt;//LMEM-&amp;gt;PCCCR |= LMEM_PCCCR_INVW1_MASK | LMEM_PCCCR_INVW0_MASK;&lt;BR /&gt;//LMEM-&amp;gt;PCCCR |= LMEM_PCCCR_GO_MASK;&lt;BR /&gt;/* Wait until the command completes */&lt;BR /&gt;//while (LMEM-&amp;gt;PCCCR &amp;amp; LMEM_PCCCR_GO_MASK) {&lt;BR /&gt;//}&lt;BR /&gt;/* Enable cache, enable write buffer */&lt;BR /&gt;//LMEM-&amp;gt;PCCCR |= (LMEM_PCCCR_ENWRBUF_MASK | LMEM_PCCCR_ENCACHE_MASK);&lt;BR /&gt;// } TY comments to disable code bus cache.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;/P&gt;</description>
      <pubDate>Wed, 08 Sep 2021 23:36:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337227#M179798</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2021-09-08T23:36:46Z</dc:date>
    </item>
    <item>
      <title>Re: Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337510#M179817</link>
      <description>&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;Thank you so much for sharing.&lt;/P&gt;&lt;P&gt;Disabling code bus cache did solve the issue.&lt;/P&gt;&lt;P&gt;Can I please know if disabling Processor Code bus cache affects the normal execution of the application?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhargava&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 07:36:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337510#M179817</guid>
      <dc:creator>Bhargava</dc:creator>
      <dc:date>2021-09-09T07:36:37Z</dc:date>
    </item>
    <item>
      <title>Re: Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337581#M179823</link>
      <description>&lt;P&gt;Hi Bhargava&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;no, it does not affect the normal execution of the application.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 08:28:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337581#M179823</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2021-09-09T08:28:12Z</dc:date>
    </item>
    <item>
      <title>Re: Cortex-M4 bare-metal application cannot read data from the shared memory(OCRAM)</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337654#M179833</link>
      <description>&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;Thanks for responding, it was indeed helpful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bhargava&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 09:51:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Cortex-M4-bare-metal-application-cannot-read-data-from-the/m-p/1337654#M179833</guid>
      <dc:creator>Bhargava</dc:creator>
      <dc:date>2021-09-09T09:51:23Z</dc:date>
    </item>
  </channel>
</rss>

