<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div><blockquote type="cite" class=""><div class=""><br class="">On Jan 26, 2015, at 2:57 PM, Aaron Block <<a href="mailto:ablock@austincollege.edu" class="">ablock@austincollege.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=us-ascii" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">A plugin I am writing right now has a lot of logic in it for what do when a<br class="">job completes. The plugin works correctly, except that it crashes when the<br class="">system load is high. I might be barking up the wrong tree but I suspect<br class="">that my scheduling logic is "taking too long" and this is causing the<br class="">kernel to crash. I was wondering if anybody has an idea of how I could<br class="">increase the amount of time allocated to the scheduler (if there is even<br class="">such a value)<br class=""><br class="">Thanks,<br class=""><br class="">--Aaron<br class=""><div apple-content-edited="true" class="">
<span class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px;"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; border-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-stroke-width: 0px;"><div apple-content-edited="true" class=""><span class="Apple-style-span" style="font-size: 12px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; " class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; " class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; " class=""><span class="Apple-style-span" style="font-size: 18px; "><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><b class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; font-weight: bold; " class="">Aaron Block</span></font></b></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><span class="Apple-style-span" style="line-height: 15px; font-size: 13px; ">Assistant Professor of Computer Science</span></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class=""><o:p class=""> </o:p></span></font></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><st1:place w:st="on" class=""><st1:placename w:st="on" class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class="">Austin</span></font></st1:placename><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class=""> <st1:placename w:st="on" class="">College</st1:placename></span></font></st1:place><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class=""> | Math and Computer Science<o:p class=""></o:p></span></font></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><st1:street w:st="on" class=""><st1:address w:st="on" class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class="">900 North Grand Avenue, Suite 61592</span></font></st1:address></st1:street><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class=""> | <st1:place w:st="on" class=""><st1:city w:st="on" class="">Sherman</st1:city>, <st1:state w:st="on" class="">Texas</st1:state> <st1:postalcode w:st="on" class="">75090</st1:postalcode></st1:place><o:p class=""></o:p></span></font></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class="">Phone 903.813.2563 <o:p class=""></o:p></span></font></div><div style="margin-top: 0in; margin-bottom: 0.0001pt; line-height: 19px; margin-right: 0in; margin-left: 0in; font-size: 12pt; " class=""><font size="2" class=""><span style="font-size: 10pt; line-height: 15px; " class=""><a href="http://austincollege.edu" class="">austincollege.edu</a><o:p class=""></o:p></span></font></div></span></div></div></div></span></div></span></span></div></div></div></blockquote><br class=""></div><div><br class=""></div><div>Hi Aaron,</div><div><br class=""></div><div>Do you have “CONFIG_LOCKUP_DETECTOR” set?  (It’s under the Kernel Hacking > Kernel debugging submenu).  Linux’s soft lockup detector works by running a background high-priority SCHED_FIFO task that runs every few seconds.  Every time it executes, the task resets a counter.  In parallel, using NMIs, an interrupt handler increments this counter.  If this counter reaches a great enough value (~20 seconds by default, I think), the NMI interrupt handler will crash the system.  In systems heavily loaded with Litmus tasks, the SCHED_LITMUS tasks starve the soft lockup detector for CPU time.  The NMI interrupt handler inevitably crashes the system.  I’ve wasted days figuring this one out.</div><div><br class=""></div><div>Workaround: Don’t set CONFIG_LOCKUP_DETECTOR.</div><div><br class=""></div><div>I’ve thought about submitting a patch to Litmus where the on_tick API causes the lockup detector counter to be reset.  I haven’t gotten around to it yet though.</div><div><br class=""></div><div>Of course, maybe CONFIG_LOCKUP_DETECTOR isn’t the source of the problem you are seeing.</div><div><br class=""></div><div>-Glenn</div></body></html>