<?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のトピックChanging mclk frequency on IMX7D</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Changing-mclk-frequency-on-IMX7D/m-p/2061281#M235055</link>
    <description>&lt;P&gt;Hi,&lt;BR /&gt;I am facing the same issue as already described here&amp;nbsp;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/How-to-obtain-2-different-SAI-MCLKs/m-p/687570?commentID=922214#comment-922214" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/How-to-obtain-2-different-SAI-MCLKs/m-p/687570?commentID=922214#comment-922214&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Explaining it again.&lt;BR /&gt;&lt;BR /&gt;Codec&amp;nbsp; &amp;nbsp;tlv320aic32x4 as slave&lt;BR /&gt;CPU&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; iMX7D as master&lt;BR /&gt;connected on SAI2 interface&lt;BR /&gt;&lt;BR /&gt;I am trying to change the sai2.mck frequency, by default it is getting measured as 24MHz, I want to change it to any other freq (lets say&amp;nbsp;36864000Hz).&lt;BR /&gt;The parent clock selected for SAI2_CLK_ROOT is OSC by default which tells why we are getting 24MHz.&lt;BR /&gt;Here we need to change the parent clk, I was able to do that with the device tree changes and able to see it in clk_summary (cat /sys/kernel/debug/clk/clk_summary | grep sai2)&amp;nbsp;&lt;BR /&gt;But surprisingle it was still coming as 24Mhz on oscilloscope.&lt;BR /&gt;&lt;BR /&gt;Further investigation showd me that if I disable AUDIO_MCLK_CLK_ROOT (0x3038BC80) , the output on sai2.mclk disappers and appreads after I again enable it&lt;BR /&gt;&lt;BR /&gt;devmem2 0x3038BC80 w 0x00000000&amp;nbsp; // clock got disabled&lt;BR /&gt;devmem2 0x3038BC80 w 0x10000000&amp;nbsp; // clock got enabled&lt;BR /&gt;&lt;BR /&gt;So, it seems to be related to AUDIO_MCLK and not SAI2.MCLK. I am not able to find any relavent data in reference manual on how there two are linked.&lt;BR /&gt;&lt;BR /&gt;However, when I tried to change the parent clock of AUDIO_MCLK from device tree, I was able to change it but the clock gating got disabled (IMX7D_AUDIO_MCLK_ROOT_CG)&lt;BR /&gt;&lt;BR /&gt;I am looking for any guide/hints to solve the mclk issue.&lt;BR /&gt;Let me know if any more information is required&lt;/P&gt;</description>
    <pubDate>Thu, 13 Mar 2025 11:54:09 GMT</pubDate>
    <dc:creator>MSahil</dc:creator>
    <dc:date>2025-03-13T11:54:09Z</dc:date>
    <item>
      <title>Changing mclk frequency on IMX7D</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Changing-mclk-frequency-on-IMX7D/m-p/2061281#M235055</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;I am facing the same issue as already described here&amp;nbsp;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/How-to-obtain-2-different-SAI-MCLKs/m-p/687570?commentID=922214#comment-922214" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/How-to-obtain-2-different-SAI-MCLKs/m-p/687570?commentID=922214#comment-922214&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Explaining it again.&lt;BR /&gt;&lt;BR /&gt;Codec&amp;nbsp; &amp;nbsp;tlv320aic32x4 as slave&lt;BR /&gt;CPU&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; iMX7D as master&lt;BR /&gt;connected on SAI2 interface&lt;BR /&gt;&lt;BR /&gt;I am trying to change the sai2.mck frequency, by default it is getting measured as 24MHz, I want to change it to any other freq (lets say&amp;nbsp;36864000Hz).&lt;BR /&gt;The parent clock selected for SAI2_CLK_ROOT is OSC by default which tells why we are getting 24MHz.&lt;BR /&gt;Here we need to change the parent clk, I was able to do that with the device tree changes and able to see it in clk_summary (cat /sys/kernel/debug/clk/clk_summary | grep sai2)&amp;nbsp;&lt;BR /&gt;But surprisingle it was still coming as 24Mhz on oscilloscope.&lt;BR /&gt;&lt;BR /&gt;Further investigation showd me that if I disable AUDIO_MCLK_CLK_ROOT (0x3038BC80) , the output on sai2.mclk disappers and appreads after I again enable it&lt;BR /&gt;&lt;BR /&gt;devmem2 0x3038BC80 w 0x00000000&amp;nbsp; // clock got disabled&lt;BR /&gt;devmem2 0x3038BC80 w 0x10000000&amp;nbsp; // clock got enabled&lt;BR /&gt;&lt;BR /&gt;So, it seems to be related to AUDIO_MCLK and not SAI2.MCLK. I am not able to find any relavent data in reference manual on how there two are linked.&lt;BR /&gt;&lt;BR /&gt;However, when I tried to change the parent clock of AUDIO_MCLK from device tree, I was able to change it but the clock gating got disabled (IMX7D_AUDIO_MCLK_ROOT_CG)&lt;BR /&gt;&lt;BR /&gt;I am looking for any guide/hints to solve the mclk issue.&lt;BR /&gt;Let me know if any more information is required&lt;/P&gt;</description>
      <pubDate>Thu, 13 Mar 2025 11:54:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Changing-mclk-frequency-on-IMX7D/m-p/2061281#M235055</guid>
      <dc:creator>MSahil</dc:creator>
      <dc:date>2025-03-13T11:54:09Z</dc:date>
    </item>
    <item>
      <title>Re: Changing mclk frequency on IMX7D</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Changing-mclk-frequency-on-IMX7D/m-p/2061363#M235061</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;It is IMX7D_AUDIO_MCLK_ROOT_CLK&lt;BR /&gt;clock may be adjusted using common linux framework guidelines&lt;BR /&gt;described in linux documentation something like:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=https%3A%2F%2Fwww.kernel.org%2Fdoc%2FDocumentation%2Fclk.txt" target="_blank" rel="noopener"&gt;https://www.kernel.org/doc/Documentation/clk.txt&lt;/A&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Felinux.org%2Fimages%2Fb%2Fb8%2FElc2013_Clement.pdf" target="_blank" rel="noopener"&gt;http://elinux.org/images/b/b8/Elc2013_Clement.pdf&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://community.nxp.com/thread/455121" target="_blank"&gt;https://community.nxp.com/thread/455121&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Mar 2025 14:07:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Changing-mclk-frequency-on-IMX7D/m-p/2061363#M235061</guid>
      <dc:creator>Bio_TICFSL</dc:creator>
      <dc:date>2025-03-13T14:07:56Z</dc:date>
    </item>
  </channel>
</rss>

