07/12/2013 18:54, Fran?ois-Fr?d?ric Ozog : > > De Thomas Monjalon > > 06/12/2013 14:12, Pashupati Kumar : > > > I am looking for spinlocks that use a single bit (bit 31) of a 32 bit > > > word for locking. The rest of the bits in the word are left > > > undisturbed. This enables more compact data structures as only 1 bit > > > is consumed for the lock. > > > > Oh yes, like test_and_set_bit_lock() in Linux: > > > > http://lxr.free-electrons.com/source/arch/ia64/include/asm/bitops.h?v=3.12#L205 > > > > I think that a patch would be appreciated :) > > I assume you mean the x64 version, not the ia64: > http://lxr.free-electrons.com/source/arch/x86/include/asm/bitops.h.
Yes you're right. > What is the policy to share a sample program: inline in a mail or as a > attachment? Inline should be fine. It allows to comment. > What is the policy to submit a patch? It's now explained here: http://dpdk.org/dev#send -- Thomas