<div dir="ltr">Maybe that is <a href="https://reviews.llvm.org/D30171">https://reviews.llvm.org/D30171</a>.</div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 20, 2017 at 11:16 PM, Dmitry Golovin <span dir="ltr"><<a href="mailto:dima@golovin.in" target="_blank">dima@golovin.in</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>Hi,</div><div> </div><div>I can't build the Linux kernel anymore. With the latest kernel source and latest LLVM and LLD (with D30163) I can only get this error message when linking vmlinux:</div><div> </div><div>ld.lld: error: unable to move location counter backward<div> </div><div>Did you have similar errors? How do I get rid of it?</div></div><div> </div><div>Regards,</div><div>Dmitry</div></div><div><br></div><div><br></div><div>20.02.2017, 17:51, "George Rimar" <<a href="mailto:grimar@accesssoftek.com" target="_blank">grimar@accesssoftek.com</a>>:</div><div class="HOEnZb"><div class="h5"><blockquote type="cite">




<div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<p></p>
<div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<div>
<div>
<div>And I think current issue with "Kernel panic - not syncing: IO-APIC + timer doesn't work!" is also clear.</div>
<div><br>
</div>
<div>timer_irq_works(void) never returns 1:</div>
<div><a href="https://github.com/torvalds/linux/blob/d966564fcdc19e13eb6ba1fbe6b8101070339c3d/arch/x86/kernel/apic/io_apic.c#L1641" target="_blank">https://github.com/torvalds/<wbr>linux/blob/<wbr>d966564fcdc19e13eb6ba1fbe6b810<wbr>1070339c3d/arch/x86/kernel/<wbr>apic/io_apic.c#L1641</a></div>
<div><br>
</div>
<div>I think it happens because of jiffies (<a href="http://www.makelinux.net/books/lkd2/ch10lev1sec3#ch10fig01" target="_blank">http://www.makelinux.net/<wbr>books/lkd2/ch10lev1sec3#<wbr>ch10fig01</a>)</div>
<div><br>
</div>
<div>It should have the same address as jiffies_64:</div>
<div><a href="https://github.com/torvalds/linux/blob/b66484cd74706fa8681d051840fe4b18a3da40ff/arch/x86/kernel/vmlinux.lds.S#L41" target="_blank">https://github.com/torvalds/<wbr>linux/blob/<wbr>b66484cd74706fa8681d051840fe4b<wbr>18a3da40ff/arch/x86/kernel/<wbr>vmlinux.lds.S#L41</a></div>
<div><br>
</div>
<div>And that is true for BFD linked binary:</div>
<div> 10595: ffffffff8140b000     8 OBJECT  GLOBAL DEFAULT    8 jiffies</div>
<div> 11730: ffffffff8140b000     8 OBJECT  GLOBAL DEFAULT    8 jiffies_64</div>
<div> </div>
<div>But something is wrong with them for LLD case:</div>
<div> 6422: ffffffff8140b000     8 OBJECT  GLOBAL DEFAULT   19 jiffies</div>
<div> 7416: ffffffff<span>81400000</span>     0 NOTYPE  GLOBAL DEFAULT   19 jiffies_64</div>
<div>  </div>
<div>I think we probably incorrectly assign symbols outside SECTIONS declarations in scripts. Looking at it.<br>
</div>
<br>
</div>
<p>George.<br>
</p>
</div>
</div>
</div>

</blockquote>
</div></div></blockquote></div><br></div>