<?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: Why does my i.MX6UL-based Linux system freezes when accessing IO memory?</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901864#M136043</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kévin&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;one can check if epit clocks are enabled in CCM_CCGR1 register and try with&lt;/P&gt;&lt;P&gt;nxp linux from &lt;A class="link-titled" href="https://source.codeaurora.org/external/imx/linux-imx/tree/?h=imx_4.1.15_2.0.0_ga" title="https://source.codeaurora.org/external/imx/linux-imx/tree/?h=imx_4.1.15_2.0.0_ga"&gt;linux-imx - i.MX Linux kernel&lt;/A&gt;&amp;nbsp;&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>Tue, 21 May 2019 23:25:16 GMT</pubDate>
    <dc:creator>igorpadykov</dc:creator>
    <dc:date>2019-05-21T23:25:16Z</dc:date>
    <item>
      <title>Why does my i.MX6UL-based Linux system freezes when accessing IO memory?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901862#M136041</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am currently facing a problem I can't understand.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to develop a Linux kernel module on a i.MX6UL-based embedded system. I would use this module to wake up my system from suspend mode after some delay, using the EPIT to raise an interrupt (which would be the wake-up event).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My system runs Debian Linux 8 ("Jessie"), and thus the version 4.1.15 of the Linux kernel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I began to develop a module to control the i.MX6UL EPIT. Its source code is in the attached file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;modprobe&lt;/SPAN&gt;-ing my module, everything goes okay, until I try to access (read or write) the IO memory reserved and allocated for the EPIT modules: the system then freezes! I have to power off and on my embedded device to be able to reboot Linux!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I comment out the lines in the &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;disable_epit()&lt;/SPAN&gt; function after my comments, the module installs &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;modprobe&lt;/SPAN&gt;s without problem, and I have the following &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;dmesg&lt;/SPAN&gt; output:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;[60641.899705] EPIT1 base address : a0f70000&lt;BR /&gt;[60641.899797] EPIT2 base address : a0f78000&lt;BR /&gt;[60641.899836] CR address = a0f70000&lt;BR /&gt;[60641.899869] EPIT module initialised.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I can only conclude that the problem does not come from the &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;request_mem_region()&lt;/SPAN&gt; or &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;ioremap()&lt;/SPAN&gt; functions, since I check for errors, and I get back valid virtual IO memory addresses...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I absolutely can't understand what's happening. Any help, advice and solution would be greatly appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks, and best regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 May 2019 08:15:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901862#M136041</guid>
      <dc:creator>kevinroussel</dc:creator>
      <dc:date>2019-05-21T08:15:20Z</dc:date>
    </item>
    <item>
      <title>Re: Why does my i.MX6UL-based Linux system freezes when accessing IO memory?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901863#M136042</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Precision: when &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;modprobe&lt;/SPAN&gt;-ing my module without accessing registers, I can also see that the adequate physical memory range has been reserved:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;$ cat /proc/iomem&lt;/P&gt;&lt;P&gt;[...]&lt;/P&gt;&lt;P&gt;020c9000-020c9fff : /soc/aips-bus@02000000/usbphy@020c9000 &lt;BR /&gt;020ca000-020cafff : /soc/aips-bus@02000000/usbphy@020ca000 &lt;BR /&gt;020d0000-020d3fff : i.MX6-UL EPIT1 registers &lt;BR /&gt;020d4000-020d7fff : i.MX6-UL EPIT2 registers &lt;BR /&gt;020e0000-020e3fff : /soc/aips-bus@02000000/iomuxc@020e0000 &lt;BR /&gt;020ec000-020effff : /soc/aips-bus@02000000/sdma@020ec000 &lt;/P&gt;&lt;P&gt;[...]&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;This is another clue that makes me think that I reserved/allocated the IO memory for EPIT registers correctly...&lt;/P&gt;&lt;P&gt;So, I really don't understand why my system freezes when I try to read or write these registers.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 May 2019 08:20:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901863#M136042</guid>
      <dc:creator>kevinroussel</dc:creator>
      <dc:date>2019-05-21T08:20:12Z</dc:date>
    </item>
    <item>
      <title>Re: Why does my i.MX6UL-based Linux system freezes when accessing IO memory?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901864#M136043</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kévin&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;one can check if epit clocks are enabled in CCM_CCGR1 register and try with&lt;/P&gt;&lt;P&gt;nxp linux from &lt;A class="link-titled" href="https://source.codeaurora.org/external/imx/linux-imx/tree/?h=imx_4.1.15_2.0.0_ga" title="https://source.codeaurora.org/external/imx/linux-imx/tree/?h=imx_4.1.15_2.0.0_ga"&gt;linux-imx - i.MX Linux kernel&lt;/A&gt;&amp;nbsp;&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>Tue, 21 May 2019 23:25:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901864#M136043</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2019-05-21T23:25:16Z</dc:date>
    </item>
    <item>
      <title>Re: Why does my i.MX6UL-based Linux system freezes when accessing IO memory?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901865#M136044</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Igor,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Indeed, the EPIT clock was disabled in the CCM. (I would have thought that in such a case an explicit bus error or kernel oops would occur.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you and best regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 May 2019 09:50:30 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Why-does-my-i-MX6UL-based-Linux-system-freezes-when-accessing-IO/m-p/901865#M136044</guid>
      <dc:creator>kevinroussel</dc:creator>
      <dc:date>2019-05-22T09:50:30Z</dc:date>
    </item>
  </channel>
</rss>

