2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5 <html xmlns="http://www.w3.org/1999/xhtml">
7 <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
8 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
9 <title>FE310-G00 PLL — Freedom Metal v201905 documentation</title>
10 <link rel="stylesheet" href="../_static/alabaster.css" type="text/css" />
11 <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
12 <script type="text/javascript" id="documentation_options" data-url_root="../" src="../_static/documentation_options.js"></script>
13 <script type="text/javascript" src="../_static/jquery.js"></script>
14 <script type="text/javascript" src="../_static/underscore.js"></script>
15 <script type="text/javascript" src="../_static/doctools.js"></script>
16 <link rel="index" title="Index" href="../genindex.html" />
17 <link rel="search" title="Search" href="../search.html" />
18 <link rel="next" title="Interrupt Handlers" href="interrupts.html" />
19 <link rel="prev" title="Exception Handlers" href="exceptions.html" />
21 <link rel="stylesheet" href="../_static/custom.css" type="text/css" />
24 <meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />
29 <div class="document">
30 <div class="documentwrapper">
31 <div class="bodywrapper">
34 <div class="body" role="main">
36 <div class="section" id="fe310-g00-pll">
37 <h1>FE310-G00 PLL<a class="headerlink" href="#fe310-g00-pll" title="Permalink to this headline">ΒΆ</a></h1>
38 <p>On targets with a PLL compatible with the FE310-G000 SoC, the PLL is configured
39 at program initialization with a constructor. This PLL sets the clock frequency
40 of the RISC-V CPU, and users of Freedom Metal who wish to set a specific clock
41 rate can use Freedom Metal to request that the PLL take on a certain output rate.</p>
42 <p>In the DeviceTree for your target, there should be a node like the following
43 (example taken from the SiFive HiFive1):</p>
44 <div class="highlight-DeviceTree notranslate"><div class="highlight"><pre><span></span>hfclk: clock@4 {
45 compatible = "sifive,fe310-g000,pll";
46 clocks = <&hfxoscout &hfroscout>;
47 clock-names = "pllref", "pllsel0";
48 reg = <&prci 0x8 &prci 0xc>;
49 reg-names = "config", "divider";
50 clock-frequency = <16000000>;
54 <p>The <code class="docutils literal notranslate"><span class="pre">clock-frequency</span></code> property of the node sets the requested clock rate of
55 the FE310-G000 PLL. The PLL driver will attempt to configure the PLL to achieve
57 <p>Users should note that the FE310-G000 PLL only supports certain input/output
58 clock rate ratios, and so the effective output rate of the PLL may differ from
59 the requested rate.</p>
67 <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
68 <div class="sphinxsidebarwrapper">
69 <h1 class="logo"><a href="../index.html">Freedom Metal</a></h1>
80 <li class="toctree-l1"><a class="reference internal" href="../introduction.html">Introduction to Freedom Metal</a></li>
81 <li class="toctree-l1 current"><a class="reference internal" href="../devguide.html">Developer Guide</a><ul class="current">
82 <li class="toctree-l2"><a class="reference internal" href="exceptions.html">Exception Handlers</a></li>
83 <li class="toctree-l2 current"><a class="current reference internal" href="#">FE310-G00 PLL</a></li>
84 <li class="toctree-l2"><a class="reference internal" href="interrupts.html">Interrupt Handlers</a></li>
85 <li class="toctree-l2"><a class="reference internal" href="itim.html">Instruction Tightly Integrated Memory</a></li>
86 <li class="toctree-l2"><a class="reference internal" href="pmps.html">Physical Memory Protection</a></li>
87 <li class="toctree-l2"><a class="reference internal" href="tty.html">Standard I/O</a></li>
90 <li class="toctree-l1"><a class="reference internal" href="../api.html">API Reference</a></li>
93 <div class="relations">
94 <h3>Related Topics</h3>
96 <li><a href="../index.html">Documentation overview</a><ul>
97 <li><a href="../devguide.html">Developer Guide</a><ul>
98 <li>Previous: <a href="exceptions.html" title="previous chapter">Exception Handlers</a></li>
99 <li>Next: <a href="interrupts.html" title="next chapter">Interrupt Handlers</a></li>
104 <div id="searchbox" style="display: none" role="search">
105 <h3>Quick search</h3>
106 <div class="searchformwrapper">
107 <form class="search" action="../search.html" method="get">
108 <input type="text" name="q" />
109 <input type="submit" value="Go" />
110 <input type="hidden" name="check_keywords" value="yes" />
111 <input type="hidden" name="area" value="default" />
115 <script type="text/javascript">$('#searchbox').show(0);</script>
118 <div class="clearer"></div>
121 ©2019, SiFive Inc..
124 Powered by <a href="http://sphinx-doc.org/">Sphinx 1.7.5</a>
125 & <a href="https://github.com/bitprophet/alabaster">Alabaster 0.7.11</a>
128 <a href="../_sources/devguide/fe310-g000-pll.rst.txt"
129 rel="nofollow">Page source</a>