<div dir="ltr"><br><br><div class="gmail_quote">On Thu, Dec 10, 2009 at 10:33 AM, Gilboa Davara <span dir="ltr"><<a href="mailto:gilboad@gmail.com">gilboad@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div></div><div class="h5">On Thu, 2009-12-10 at 08:58 +0200, Shachar Shemesh wrote:<br>
> Gilboa Davara wrote:<br>
> > On Wed, 2009-12-09 at 20:04 +0200, Raz wrote:<br>
> ><br>
> > > Do not use inline kernel atomic_t operation, you will violate GPL.<br>
> > > Use gcc builtins. If you want information please refer to:<br>
> > > <a href="http://sos-linux.svn.sourceforge.net/viewvc/sos-linux/offsched/Linux-Debug/" target="_blank">http://sos-linux.svn.sourceforge.net/viewvc/sos-linux/offsched/Linux-Debug/</a><br>
> > > and download linux-debug.pdf . You will few words on atomicity in user<br>
> > > space in linux.<br>
> > > Please execuse for bad editing, the paper is not complete.<br>
> > ><br>
> > > raz<br>
> > ><br>
> ><br>
> > Thanks.<br>
> > While I was aware of the derived problem - I neglected to point it out.<br>
> > Thanks.<br>
> ><br>
> > At least in my case (and partially due to the derived work problem), I<br>
> > simply wrote my own set of assembly functions that worked the same under<br>
> > both Linux/BSD and Windows (under both user mode and kernel mode).<br>
> ><br>
> > - Gilboa<br>
> ><br>
> I might be missing something really basic, but may I ask "why"? What<br>
> would you want to achieve that would require you to use the "get and<br>
> set" (or "test and set", or whatever) in user space?<br>
><br>
> Shachar<br>
<br>
</div></div>Why?<br>
- Write code that can run more-or-less the same as kernel module and as<br>
a user-space library. (And under multiple different OS')<br>
- Implement fast spinlocks and/or RW locks in user mode. (Again, that<br>
behave the same under kernel mode and user mode.)<br></blockquote><div>Giloboa<br>why not take a look at urcu for fast locks.<a href="http://www.lttng.org/?q=node/18">http://www.lttng.org/?q=node/18</a><br>I talked to the guy i saw the presentation at the LPC. <br>
</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
- Atomic counters.<br>
- Anything else that can use the "lock" prefix.<br>
<div><div></div><div class="h5"><br>
- Gilboa<br>
<br>
<br>
<br>
_______________________________________________<br>
Linux-il mailing list<br>
<a href="mailto:Linux-il@cs.huji.ac.il">Linux-il@cs.huji.ac.il</a><br>
<a href="http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il" target="_blank">http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il</a><br>
</div></div></blockquote></div><br></div>