<?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: imx8mm - GPT clock source in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1241326#M170456</link>
    <description>&lt;P&gt;Hi Nir&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;one can try to debug it using AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors&lt;BR /&gt;&lt;A href="https://www.nxp.com/docs/en/application-note/AN4553.pdf" target="_blank" rel="noopener"&gt;https://www.nxp.com/docs/en/application-note/AN4553.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Also I sent additional patch by mail, however for complete solution suggest to proceed with help of&lt;/P&gt;
&lt;P&gt;&lt;A href="https://contact.nxp.com/new-prof-svcs-sw-tech" target="_blank" rel="noopener"&gt;https://contact.nxp.com/new-prof-svcs-sw-tech&lt;/A&gt;&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>Sat, 06 Mar 2021 12:05:32 GMT</pubDate>
    <dc:creator>igorpadykov</dc:creator>
    <dc:date>2021-03-06T12:05:32Z</dc:date>
    <item>
      <title>imx8mm - GPT clock source</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235156#M169889</link>
      <description>&lt;P&gt;Hi There,&lt;/P&gt;&lt;P&gt;I'm working on a imx8mm evaluation board, running BSP 5.4-zeus, BB_VERSION = "1.44.0", linux kernel 5.4.47.&lt;/P&gt;&lt;P&gt;I'm trying to set clock source to the GPT.&lt;/P&gt;&lt;P&gt;According to "i.MX 8M Mini Applications Processor Reference Manual", page 280, Table 5-1, the maximum clock frequency that can be used is 100MHz.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="nirgeller_0-1614105283868.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/137840iF8F88FB6277B9D1B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="nirgeller_0-1614105283868.png" alt="nirgeller_0-1614105283868.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;According to page 3855, 12.1.5.1, GPT Control Register, the clock source can be determined by setting bits 8-6 during the setup procedure of the GPT.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="nirgeller_1-1614105412796.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/137842iBDBC40AE3746B9BE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="nirgeller_1-1614105412796.png" alt="nirgeller_1-1614105412796.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;By editing the GPT driver, drivers/clocksource/timer-imx-gpt.c I tried all the variants, but the maximum clock frequency I got is 24MHz.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please help me to configure that clock source to get at least 66MHz.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Nir.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Feb 2021 18:42:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235156#M169889</guid>
      <dc:creator>nirgeller</dc:creator>
      <dc:date>2021-02-23T18:42:44Z</dc:date>
    </item>
    <item>
      <title>Re: imx8mm - GPT clock source</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235245#M169896</link>
      <description>&lt;P&gt;Hi Nir&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;one can check clock driver&lt;/P&gt;
&lt;P&gt;&lt;A href="https://source.codeaurora.org/external/imx/linux-imx/tree/drivers/clk/imx/clk-imx8mm.c?h=imx_5.4.47_2.2.0" target="_blank"&gt;https://source.codeaurora.org/external/imx/linux-imx/tree/drivers/clk/imx/clk-imx8mm.c?h=imx_5.4.47_2.2.0&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Linux common clock framework documentation&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.kernel.org/doc/Documentation/clk.txt" target="_blank"&gt;https://www.kernel.org/doc/Documentation/clk.txt&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.linuxsecrets.com/elinux-wiki/images/b/b8/Elc2013_Clement.pdf" target="_blank"&gt;www.linuxsecrets.com/elinux-wiki/images/b/b8/Elc2013_Clement.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;example:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/Where-pll4-bypass-src-is-set-to-choose-osc-24MHz-or-CLK2-N-P-as/m-p/671354" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/Where-pll4-bypass-src-is-set-to-choose-osc-24MHz-or-CLK2-N-P-as/m-p/671354&lt;/A&gt;&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>Tue, 23 Feb 2021 23:11:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235245#M169896</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2021-02-23T23:11:10Z</dc:date>
    </item>
    <item>
      <title>Re: imx8mm - GPT clock source</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235889#M169972</link>
      <description>&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;Thanks for your reply.&lt;/P&gt;&lt;P&gt;It looks like the clock driver, drivers/clk/imx/clk-imx8mm.c, defines the available clock sources for the GPT module in line 301:&lt;/P&gt;&lt;P&gt;301 static const char *imx8mm_gpt1_sels[] = {"osc_24m", "sys_pll2_100m", "sys_pll1_400m", "sys_pll1_40m",&lt;BR /&gt;302 "video_pll1_out", "sys_pll1_80m", "audio_pll1_out", "clk_ext1" };&lt;/P&gt;&lt;P&gt;This definition complies perfectly with Table 5-1.&lt;/P&gt;&lt;P&gt;However, the clock source is determined by bits 6-8 in the GPT control register, 12.1.5.1&lt;/P&gt;&lt;P&gt;How exactly are these 3 bits mapped to the structure imx8mm_gpt1_sels[]?&lt;/P&gt;&lt;P&gt;How can I figure out what is the frequency of "High Frequency Reference Clock (ipg_clk_highfreq)", or "Peripheral Clock (ipg_clk)"?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;As I stated, any combination of bits I'm trying yields a maximum frequency of 24MHz. (I'm setting the prescaler to 1).&lt;/P&gt;&lt;P&gt;Can you please direct me how to set sys_pll2_100m as the clock source instead of osc_24m?&lt;/P&gt;&lt;P&gt;Thanks a lot,&lt;/P&gt;&lt;P&gt;Nir.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Feb 2021 19:01:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1235889#M169972</guid>
      <dc:creator>nirgeller</dc:creator>
      <dc:date>2021-02-24T19:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: imx8mm - GPT clock source</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1239186#M170274</link>
      <description>&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;Thanks for your reply.&lt;/P&gt;&lt;P&gt;It looks like the clock driver, drivers/clk/imx/clk-imx8mm.c, defines the available clock sources for the GPT module in line 301:&lt;/P&gt;&lt;P&gt;301 static const char *imx8mm_gpt1_sels[] = {"osc_24m", "sys_pll2_100m", "sys_pll1_400m", "sys_pll1_40m",&lt;BR /&gt;302 "video_pll1_out", "sys_pll1_80m", "audio_pll1_out", "clk_ext1" };&lt;/P&gt;&lt;P&gt;This definition complies perfectly with Table 5-1.&lt;/P&gt;&lt;P&gt;However, the clock source is determined by bits 6-8 in the GPT control register, 12.1.5.1&lt;/P&gt;&lt;P&gt;How exactly are these 3 bits mapped to the structure imx8mm_gpt1_sels[]?&lt;/P&gt;&lt;P&gt;How can I figure out what is the frequency of "High Frequency Reference Clock (ipg_clk_highfreq)", or "Peripheral Clock (ipg_clk)"?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;As I stated, any combination of bits I'm trying yields a maximum frequency of 24MHz. (I'm setting the prescaler to 1).&lt;/P&gt;&lt;P&gt;Can you please direct me how to &lt;STRONG&gt;set sys_pll2_100m&lt;/STRONG&gt; as the clock source &lt;STRONG&gt;instead of osc_24m&lt;/STRONG&gt;?&lt;/P&gt;&lt;P&gt;Thanks a lot,&lt;/P&gt;&lt;P&gt;Nir.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 08:16:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1239186#M170274</guid>
      <dc:creator>nirgeller</dc:creator>
      <dc:date>2021-03-03T08:16:18Z</dc:date>
    </item>
    <item>
      <title>Re: imx8mm - GPT clock source</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1241326#M170456</link>
      <description>&lt;P&gt;Hi Nir&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;one can try to debug it using AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors&lt;BR /&gt;&lt;A href="https://www.nxp.com/docs/en/application-note/AN4553.pdf" target="_blank" rel="noopener"&gt;https://www.nxp.com/docs/en/application-note/AN4553.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Also I sent additional patch by mail, however for complete solution suggest to proceed with help of&lt;/P&gt;
&lt;P&gt;&lt;A href="https://contact.nxp.com/new-prof-svcs-sw-tech" target="_blank" rel="noopener"&gt;https://contact.nxp.com/new-prof-svcs-sw-tech&lt;/A&gt;&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>Sat, 06 Mar 2021 12:05:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-GPT-clock-source/m-p/1241326#M170456</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2021-03-06T12:05:32Z</dc:date>
    </item>
  </channel>
</rss>

