<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Sep 27, 2015 at 8:52 AM,  <span dir="ltr">&lt;<a href="mailto:Valdis.Kletnieks@vt.edu" target="_blank">Valdis.Kletnieks@vt.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span>On Sun, 27 Sep 2015 15:08:57 +1300, vibnwis said:<br>
<br>
&gt; Xenomai patching succeeded but when running one of is test apps, &quot;latency&quot;<br>
&gt; showing<br>
&gt; &gt; &gt; &gt; &gt; &gt; &gt; &gt;&gt; &gt; 0&quot;000.000| BUG in low_init(): [main] mlockall: Cannot<br>
&gt; allocate<br>
&gt; &gt; &gt; &gt; &gt; memory<br>
&gt; And the mailing list member suggested the following<br>
<br>
</span>Is that in dmesg, or output from the test program?<br>
Is there more output, or is that it?<br>
<br>
Personally, if TRACE_IRQFLAGS is causing an issue with mlock, I&#39;d suspect<br>
a very buggy patch indeed.  If it can&#39;t tolerate a trace function being<br>
turned on, there;s probably some very questionable coding in there.....<br>
<br></blockquote><div><br></div><div><br></div><div>FWIW, I think Xenomai is far better smelling than your quick sniff has told your olfactory sensors</div><div><br></div><div>I first started using it (then called Adeos/ipipe also) shortly after starting to build my own kernels,</div><div>I had it running on 2.4.27, on a i586mmx, before I had any clue how to hack at linux.</div><div>If I could do it then, its not entirely difficult or crazy.  Maybe I got a little lucky,</div><div>maybe Id accumulated more experience by then than the OP.</div><div><br></div><div>main keepers are Phillipe Gerum, Gilles Chanterperdrix, Jan Kiska, they have numerous patches in linux;</div><div>blackfin arch, canbus, arm iirc.  I recognize Valdis&#39; name too, I know my only honest read on your talents is</div><div>`git log --oneline --author $_` for @names,</div><div><br></div><div>To me, youre all heavy hitters, and know WTH youre doing in the kernel.</div><div><br></div><div>Of course my impression is from almost a decade old, and mainline linux has gotten huge RT improvements.</div><div>I know I never came close to proving I needed adeos/xenomai, so when the extra steps got in the way,</div><div>I just stopped using it, and started actually hacking.</div><div><br></div><div>Back then, my notion was to get GPIO pins to emit a jitter free pulse train to an RC servo.</div><div>I did get the GPIO written and accepted, but never got around to putting interrupts into it</div><div>(I thought I might need that to read the pulse train coming from the radio, using interrupts </div><div>to detect rising and falling edges while keep latency down, and polling loops out)</div><div>Or the other things I didnt yet think of.</div><div><br></div><div>I still would like to get around to dragging nsc_gpio and scx200_gpio into the gpiolib era.<br></div><div>I hope Im not forced to protest its removal and promise the upgrades before </div><div>my lazy-hobbyist-quality shipment of round-to-its arrive.</div><div><br></div><div>But I have to get a bootable image onto a CF for my soekris, havent tried in years :-{</div><div>I never did grok what grub docs were telling me.   I&#39;ll have to try lilo next time.</div><div><br></div><div>I still think that reading and writing RC servo pulse trains out of a generic kernel gpio hw/sw combo</div><div>is a reasonable technical goal, even though these days youd probably use a panda/beagle/rpi board</div><div>to do it, iirc the rpi has some slick (arcane but flexible) counters/timers that could modulate</div><div> a 0.5-3.5ms pulse in a 20ms period without much cpu load.</div><div><br></div><div>Anyway, I&#39;ll wrap up with a few connected (to me) points and questions.</div><div><br></div><div>if you, Valdis, take a careful look at xenomai, I think youll find it better than you suggested,</div><div>and if you see anything wrong, I bet youd get a productive discussion.  With that in mind, I cc&#39;d those guys.</div><div>I hope I can follow it, just a bit.  It will be deep water for me.</div><div>(I also hope I didnt just do a gang tackle with all the ccs ;-)</div><div><br></div><div>do you think vanilla kernel and cheap-ass gpio hw can do an adequate job of reading 2 channels of </div><div>cheap-ass RC servo signals from the RC reciever, and transcode them (straight shot at 1st, then with kernel-modulation)</div><div>to 2 gpio outputs ?   Its not the way one would do it, but it could still be a useful model.</div><div><br></div><div>If so, is it a useful stake in the ground, a practical target for a semi-skilled, not-yet-retired hobbyist ?</div><div>Whats the assemblage of modules that makes sense, and needed features of them ?</div><div>If you want to get specific, talk about the scx200_* modules, I have a hope of grokking them ;-)</div><div><br></div><div>at a high level, I thought Adeos was slick-as-snot thing, maybe a micro-hypervisor (if such a notion makes sense)</div><div>only virtualizing the smallest surface for RT.  The massive RT-kernel improvements that have been integrated</div><div>over the last decade are in contrast sprinkled everywhere, by careful and skilled magicians, very much a complementary approach.  Using them together and optimally is a high art (mixology?), and one that surely changes  with each new RT-kernel derived feature to hit mainline, as well as playing poorly with other kernel hypervisors (OP did you do that ?)</div><div><br></div><div>feel free to rebrand this subject as you see fit, Im already WAY OT.</div><div>I hope it will be an illuminating thread, and one that gives me a coherent picture of how to do it.  </div><div>It will make starting easier, even (or especially) if it takes me 6 months to do so.</div><div><br></div><div>jeez, Ive got work to do,</div><div>and reigniting an old hobby isnt it.</div><div>But obviously, the ghost of the itch is still there.</div><div>better get some calamine lotion ;-)</div><div><br></div><div>thanks</div><div>Jim Cromie</div><div><br></div></div></div></div>