<html><head></head><body>Hi<br>
<br>
Linux already does that for you: (v4.16) arch/x86/kernel/cpu/amd.c line 869.<br>
<br>
<br>
Kind regards<br><br><div class="gmail_quote">On 5 April 2018 00:51:30 GMT+02:00, "Taiidan@gmx.com" <Taiidan@gmx.com> wrote:<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<pre class="k9mail">As I am not a programmer I do not know how to do this (thanks for the<br>heads-up rmarek) nor am I permitted to add to the repos.<br><br>MITIGATION G-2 <br>Description: Set an MSR in the processor so that LFENCE is a dispatch<br>serializing instruction and then<br>use LFENCE in code streams to serialize dispatch (LFENCE is faster than<br>RDTSCP which is also dispatch<br>serializing).<br><br>This mode of LFENCE may be enabled by setting MSR C001_1029[1]=1.<br><br>This is important and covers a variety of boards such as the KGPE-D16,<br>KCMA-D8 and G505s (all the last and best owner controlled x86_64 systems)<br><br></pre></blockquote></div><br>
-- <br>
Arthur Heymans</body></html>