Skip to content

Commit

Permalink
Merge pull request #42 from intel/May5Update
Browse files Browse the repository at this point in the history
QAT update #133, 134, 135, 136 and 139
  • Loading branch information
jdschuet authored May 6, 2024
2 parents 7a6241e + b3e7e3f commit ef27b52
Show file tree
Hide file tree
Showing 31 changed files with 130 additions and 323 deletions.
66 changes: 63 additions & 3 deletions docs/API_PG/baseAPI.html
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
</li>
<li class="toctree-l3"><a class="reference internal" href="#intel-qat-api-conventions">Intel® QAT API Conventions</a><ul>
<li class="toctree-l4"><a class="reference internal" href="#instance-discovery">Instance Discovery</a></li>
<li class="toctree-l4"><a class="reference internal" href="#querying-capabilities">Querying Capabilities</a></li>
<li class="toctree-l4"><a class="reference internal" href="#modes-of-operation">Modes of Operation</a></li>
<li class="toctree-l4"><a class="reference internal" href="#memory-allocation-and-ownership">Memory Allocation and Ownership</a></li>
<li class="toctree-l4"><a class="reference internal" href="#data-plane-apis">Data Plane APIs</a></li>
Expand Down Expand Up @@ -210,8 +211,10 @@ <h2>Intel® QAT API Conventions<a class="headerlink" href="#intel-qat-api-conven
a specific instance within the system and is passed as a parameter to all
API functions that operate on instances.</p>
<p>Instance discovery is achieved through service-specific API invocations.
This section describes the instance discovery for data compression (<code class="docutils literal notranslate"><span class="pre">dc</span></code>);
however, the flow of the calls is similar for the cryptographic service.</p>
Subsections here provide details on the instance discovery for data compression (<code class="docutils literal notranslate"><span class="pre">dc</span></code>)
as well as the cryptographic service.</p>
<section id="data-compression">
<h4>Data Compression<a class="headerlink" href="#data-compression" title="Permalink to this heading"></a></h4>
<p>In the below example, the number of <code class="docutils literal notranslate"><span class="pre">dc</span></code> instances available to the application is
queried via the <code class="docutils literal notranslate"><span class="pre">cpaDcGetNumInstances</span></code> call. The application obtains the
instance handle of the first instance.</p>
Expand Down Expand Up @@ -240,8 +243,65 @@ <h2>Intel® QAT API Conventions<a class="headerlink" href="#intel-qat-api-conven
<span class="p">}</span>
</pre></div>
</div>
</section>
<section id="cryptography">
<h4>Cryptography<a class="headerlink" href="#cryptography" title="Permalink to this heading"></a></h4>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>This note is pertinent to customers utilizing legacy QuickAssist Technology (QAT) generations, such as QAT1.7. It is <strong>not applicable</strong> to customers operating on QAT2.0 or newer generations.</p>
<p>For cryptographic operations on legacy QAT generations, it is imperative to use the APIs <code class="docutils literal notranslate"><span class="pre">cpaCyGetNumInstances</span></code> and <code class="docutils literal notranslate"><span class="pre">cpaCyGetInstances</span></code>.</p>
<p>A notable distinction is that legacy QAT generations support both symmetric (<code class="docutils literal notranslate"><span class="pre">sym</span></code>) and asymmetric (<code class="docutils literal notranslate"><span class="pre">asym</span></code>) cryptographic instances within a single instance.
In contrast, starting with QAT2.0, each instance is dedicated to either symmetric or asymmetric operations exclusively.</p>
</div>
<p>Cryptography instance types are delineated by the enumeration <code class="docutils literal notranslate"><span class="pre">CpaAccelerationServiceType</span></code>, which can be found in the <code class="docutils literal notranslate"><span class="pre">cpa.h</span></code> header file.</p>
<p>The currently supported instance types are:</p>
<ul class="simple">
<li><p><code class="docutils literal notranslate"><span class="pre">CPA_ACC_SVC_TYPE_CRYPTO_ASYM</span></code> for asymmetric cryptographic services</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">CPA_ACC_SVC_TYPE_CRYPTO_SYM</span></code> for symmetric cryptographic services</p></li>
</ul>
<p>Consider the following example, where an additional parameter is provided to specify the desired service type. The application first queries the number of available instances for the requested service type using the <code class="docutils literal notranslate"><span class="pre">cpaGetNumInstances</span></code> API.</p>
<p>Subsequently, the application acquires the handle for the first instance returned by the <code class="docutils literal notranslate"><span class="pre">cpaGetInstances</span></code> API call.</p>
<div class="highlight-c notranslate"><div class="highlight"><pre><span></span><span class="kt">void</span><span class="w"> </span><span class="nf">sampleCyGetInstance</span><span class="p">(</span><span class="n">CpaInstanceHandle</span><span class="w"> </span><span class="o">*</span><span class="n">pCyInstHandle</span><span class="p">,</span><span class="w"> </span><span class="n">CpaAccelerationServiceType</span><span class="w"> </span><span class="n">service_type</span><span class="p">)</span>
<span class="p">{</span>
<span class="w"> </span><span class="n">CpaInstanceHandle</span><span class="w"> </span><span class="n">cyInstHandles</span><span class="p">[</span><span class="n">MAX_INSTANCES</span><span class="p">];</span>
<span class="w"> </span><span class="n">Cpa16U</span><span class="w"> </span><span class="n">numInstances</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="mi">0</span><span class="p">;</span>
<span class="w"> </span><span class="n">CpaStatus</span><span class="w"> </span><span class="n">status</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">CPA_STATUS_SUCCESS</span><span class="p">;</span>

<span class="w"> </span><span class="o">*</span><span class="n">pCyInstHandle</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="nb">NULL</span><span class="p">;</span>
<span class="w"> </span><span class="n">status</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">cpaGetNumInstances</span><span class="p">(</span><span class="n">service_type</span><span class="p">,</span><span class="w"> </span><span class="o">&amp;</span><span class="n">numInstances</span><span class="p">);</span>
<span class="w"> </span><span class="k">if</span><span class="w"> </span><span class="p">(</span><span class="n">numInstances</span><span class="w"> </span><span class="o">&gt;=</span><span class="w"> </span><span class="n">MAX_INSTANCES</span><span class="p">)</span>
<span class="w"> </span><span class="p">{</span>
<span class="w"> </span><span class="n">numInstances</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">MAX_INSTANCES</span><span class="p">;</span>
<span class="w"> </span><span class="p">}</span>
<span class="w"> </span><span class="k">if</span><span class="w"> </span><span class="p">((</span><span class="n">status</span><span class="w"> </span><span class="o">==</span><span class="w"> </span><span class="n">CPA_STATUS_SUCCESS</span><span class="p">)</span><span class="w"> </span><span class="o">&amp;&amp;</span><span class="w"> </span><span class="p">(</span><span class="n">numInstances</span><span class="w"> </span><span class="o">&gt;</span><span class="w"> </span><span class="mi">0</span><span class="p">))</span>
<span class="w"> </span><span class="p">{</span>
<span class="w"> </span><span class="n">status</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">cpaGetInstances</span><span class="p">(</span><span class="n">service_type</span><span class="p">,</span><span class="w"> </span><span class="n">numInstances</span><span class="p">,</span><span class="w"> </span><span class="n">cyInstHandles</span><span class="p">);</span>
<span class="w"> </span><span class="k">if</span><span class="w"> </span><span class="p">(</span><span class="n">status</span><span class="w"> </span><span class="o">==</span><span class="w"> </span><span class="n">CPA_STATUS_SUCCESS</span><span class="p">)</span>
<span class="w"> </span><span class="p">{</span>
<span class="w"> </span><span class="o">*</span><span class="n">pCyInstHandle</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="n">cyInstHandles</span><span class="p">[</span><span class="mi">0</span><span class="p">];</span>
<span class="w"> </span><span class="p">}</span>
<span class="w"> </span><span class="p">}</span>

<span class="w"> </span><span class="k">if</span><span class="w"> </span><span class="p">(</span><span class="mi">0</span><span class="w"> </span><span class="o">==</span><span class="w"> </span><span class="n">numInstances</span><span class="p">)</span>
<span class="w"> </span><span class="p">{</span>
<span class="w"> </span><span class="n">PRINT_ERR</span><span class="p">(</span><span class="s">&quot;No instances found for &#39;SSL&#39;</span><span class="se">\n</span><span class="s">&quot;</span><span class="p">);</span>
<span class="w"> </span><span class="n">PRINT_ERR</span><span class="p">(</span><span class="s">&quot;Please check your section names&quot;</span><span class="p">);</span>
<span class="w"> </span><span class="n">PRINT_ERR</span><span class="p">(</span><span class="s">&quot; in the config file.</span><span class="se">\n</span><span class="s">&quot;</span><span class="p">);</span>
<span class="w"> </span><span class="n">PRINT_ERR</span><span class="p">(</span><span class="s">&quot;Also make sure to use config file version 2.</span><span class="se">\n</span><span class="s">&quot;</span><span class="p">);</span>
<span class="w"> </span><span class="p">}</span>
<span class="p">}</span>
</pre></div>
</div>
</section>
</section>
<section id="querying-capabilities">
<h3>Querying Capabilities<a class="headerlink" href="#querying-capabilities" title="Permalink to this heading"></a></h3>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>This section describes the querying capabilities for data compression (dc); however, the flow of the calls is similar for the cryptographic service.</p>
</div>
<p>The next example shows the application querying the capabilities of the data
compression implementation, and veryfing the required functionality is present.
compression implementation, and verifying the required functionality is present.
Each service implementation exposes the capabilities that have been implemented
and are available. Capabilities include algorithms, common features, and limits
to variables. Each service has a unique capability matrix, and each implementation
Expand Down
11 changes: 4 additions & 7 deletions docs/API_PG/introduction.html
Original file line number Diff line number Diff line change
Expand Up @@ -300,19 +300,16 @@ <h2>Terminology<a class="headerlink" href="#terminology" title="Permalink to thi
<tr class="row-odd"><td><p>SKU</p></td>
<td><p>Stock Keeping Unit</p></td>
</tr>
<tr class="row-even"><td><p>sIOV</p></td>
<td><p>Scalable IOV</p></td>
</tr>
<tr class="row-odd"><td><p>SR-IOV</p></td>
<tr class="row-even"><td><p>SR-IOV</p></td>
<td><p>Single Root-I/O Virtualization</p></td>
</tr>
<tr class="row-even"><td><p>SSL</p></td>
<tr class="row-odd"><td><p>SSL</p></td>
<td><p>Secure Sockets Layer</p></td>
</tr>
<tr class="row-odd"><td><p>TLS</p></td>
<tr class="row-even"><td><p>TLS</p></td>
<td><p>Transport Layer Security (SSL successor)</p></td>
</tr>
<tr class="row-even"><td><p>VF</p></td>
<tr class="row-odd"><td><p>VF</p></td>
<td><p>Virtual Function</p></td>
</tr>
</tbody>
Expand Down
7 changes: 2 additions & 5 deletions docs/GSG/2.X/introduction.html
Original file line number Diff line number Diff line change
Expand Up @@ -181,13 +181,10 @@ <h2>Conventions and Terminology<a class="headerlink" href="#conventions-and-term
<tr class="row-even"><td><p>SKU</p></td>
<td><p>Stock Keeping Unit</p></td>
</tr>
<tr class="row-odd"><td><p>sIOV</p></td>
<td><p>Scalable IOV</p></td>
</tr>
<tr class="row-even"><td><p>SR-IOV</p></td>
<tr class="row-odd"><td><p>SR-IOV</p></td>
<td><p>Single Root-I/O Virtualization</p></td>
</tr>
<tr class="row-odd"><td><p>VF</p></td>
<tr class="row-even"><td><p>VF</p></td>
<td><p>Virtual Function</p></td>
</tr>
</tbody>
Expand Down
8 changes: 6 additions & 2 deletions docs/GSG/2.X/revision_history.html
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,15 @@
</tr>
</thead>
<tbody>
<tr class="row-even"><td><p>002</p></td>
<tr class="row-even"><td><p>003</p></td>
<td><p>Removed S-IOV References</p></td>
<td><p>April 2024</p></td>
</tr>
<tr class="row-odd"><td><p>002</p></td>
<td><p>Updates for 1.1.40 Release</p></td>
<td><p>March 2024</p></td>
</tr>
<tr class="row-odd"><td><p>001</p></td>
<tr class="row-even"><td><p>001</p></td>
<td><p>Initial Release</p></td>
<td><p>February 2023</p></td>
</tr>
Expand Down
2 changes: 2 additions & 0 deletions docs/GSG/2.X/systemconfiguration.html
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@ <h4>RPM-based package dependencies<a class="headerlink" href="#rpm-based-package
<span class="go">sudo dnf install -y openssl-devel</span>
<span class="go">sudo dnf install -y zlib-devel</span>
<span class="go">sudo dnf install -y make</span>
<span class="go">sudo dnf install -y libnl3-devel libnl-genl3-devel2</span>
</pre></div>
</div>
</div></blockquote>
Expand Down Expand Up @@ -287,6 +288,7 @@ <h4>DEB-based package dependencies<a class="headerlink" href="#deb-based-package
<span class="go">sudo apt-get install -y yasm</span>
<span class="go">sudo apt-get install -y zlib1g-dev</span>
<span class="go">sudo apt-get install -y libssl-dev</span>
<span class="go">sudo apt-get install -y libnl-3-dev libnl-genl-3-dev3</span>
</pre></div>
</div>
</div></blockquote>
Expand Down
2 changes: 0 additions & 2 deletions docs/Intro/terminology.html
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,6 @@
</dd>
<dt id="term-SHA">SHA<a class="headerlink" href="#term-SHA" title="Permalink to this term"></a></dt><dd><p>Secure Hash Algorithm.</p>
</dd>
<dt id="term-sIOV">sIOV<a class="headerlink" href="#term-sIOV" title="Permalink to this term"></a></dt><dd><p>Intel® Scalable I/O Virtualization</p>
</dd>
<dt id="term-SoC">SoC<a class="headerlink" href="#term-SoC" title="Permalink to this term"></a></dt><dd><p>System-on-a-Chip.</p>
</dd>
<dt id="term-SOL">SOL<a class="headerlink" href="#term-SOL" title="Permalink to this term"></a></dt><dd><p>Sign-Of-Life.</p>
Expand Down
1 change: 0 additions & 1 deletion docs/PG/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@
<li class="toctree-l2"><a class="reference internal" href="virtualization.html#virtualization-deployment-model-for-intel-qat-2-0">Virtualization Deployment Model for Intel<sup>®</sup> QAT 2.0</a></li>
<li class="toctree-l2"><a class="reference internal" href="virtualization.html#physical-device-direct-assignment">Physical Device Direct Assignment</a></li>
<li class="toctree-l2"><a class="reference internal" href="virtualization.html#single-root-iov-sr-iov">Single Root IOV (SR-IOV)</a></li>
<li class="toctree-l2"><a class="reference internal" href="virtualization.html#scalable-iov-s-iov">Scalable IOV (S-IOV)</a></li>
<li class="toctree-l2"><a class="reference internal" href="virtualization.html#reducing-number-of-vfs-per-endpoint">Reducing Number of VFs per Endpoint</a></li>
</ul>
</li>
Expand Down
4 changes: 0 additions & 4 deletions docs/PG/infrastructure_debugability.html
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,6 @@ <h3>Entries in /sys/kernel/debug/qat_*<a class="headerlink" href="#entries-in-sy
<td><p>Includes package version information.</p></td>
<td><p>All</p></td>
</tr>
<tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">vqat</span></code></p></td>
<td><p>Contains sIOV Virtual QAT device details. Refer to <a class="reference internal" href="virtualization.html#scalable-iov"><span class="std std-ref">Scalable IOV</span></a> for additional information.</p></td>
<td><p>QAT 2.0</p></td>
</tr>
</tbody>
</table>
</section>
Expand Down
5 changes: 0 additions & 5 deletions docs/PG/infrastructure_load_balancing.html
Original file line number Diff line number Diff line change
Expand Up @@ -238,11 +238,6 @@ <h3>Load Sharing Criteria<a class="headerlink" href="#load-sharing-criteria" tit
<td><p>8</p></td>
<td><p>4</p></td>
</tr>
<tr class="row-even"><td><p>Number of s-IOV
ADIs per Endpoint</p></td>
<td><p>N/A</p></td>
<td><p>64</p></td>
</tr>
</tbody>
</table>
</section>
Expand Down
1 change: 0 additions & 1 deletion docs/PG/infrastructure_queue_pairs.html
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,6 @@ <h2>Queue Bundles<a class="headerlink" href="#queue-bundles" title="Permalink to
<p>Queues are grouped into bundles of 8 queues (4 Queue Pairs (QPs)).</p>
<ul class="simple">
<li><p>When SR-IOV is enabled, each bundle shows up as a separate Virtual Function.</p></li>
<li><p>When s-IOV is enabled each QP is exposed as a separate Assignable Device Interface (ADI).</p></li>
</ul>
<p>Within each bundle, by default, a separate QP is used for each of the three possible services:</p>
<ol class="arabic simple">
Expand Down
7 changes: 2 additions & 5 deletions docs/PG/introduction.html
Original file line number Diff line number Diff line change
Expand Up @@ -186,13 +186,10 @@ <h2>Conventions and Terminology<a class="headerlink" href="#conventions-and-term
<tr class="row-even"><td><p>SKU</p></td>
<td><p>Stock Keeping Unit</p></td>
</tr>
<tr class="row-odd"><td><p>sIOV</p></td>
<td><p>Scalable IOV</p></td>
</tr>
<tr class="row-even"><td><p>SR-IOV</p></td>
<tr class="row-odd"><td><p>SR-IOV</p></td>
<td><p>Single Root-I/O Virtualization</p></td>
</tr>
<tr class="row-odd"><td><p>VF</p></td>
<tr class="row-even"><td><p>VF</p></td>
<td><p>Virtual Function</p></td>
</tr>
</tbody>
Expand Down
12 changes: 8 additions & 4 deletions docs/PG/revision_history.html
Original file line number Diff line number Diff line change
Expand Up @@ -120,21 +120,25 @@
</tr>
</thead>
<tbody>
<tr class="row-even"><td><p>004</p></td>
<tr class="row-even"><td><p>005</p></td>
<td><p>Removed S-IOV References</p></td>
<td><p>April 2024</p></td>
</tr>
<tr class="row-odd"><td><p>004</p></td>
<td><p>Updates for 1.1.40 Release</p></td>
<td><p>March 2024</p></td>
</tr>
<tr class="row-odd"><td><p>003</p></td>
<tr class="row-even"><td><p>003</p></td>
<td><p>RSA-1024 added as Opt-in.</p></td>
<td><p>June 2023</p></td>
</tr>
<tr class="row-even"><td><p>002</p></td>
<tr class="row-odd"><td><p>002</p></td>
<td><p>Note added about using SR-IOV and
S-IOV simultaneously on same PF
(not supported).</p></td>
<td><p>May 2023</p></td>
</tr>
<tr class="row-odd"><td><p>001</p></td>
<tr class="row-even"><td><p>001</p></td>
<td><p>Initial Release</p></td>
<td><p>February 2023</p></td>
</tr>
Expand Down
Loading

0 comments on commit ef27b52

Please sign in to comment.