Re: [TIP][RFC 3/7] futex: futex_lock_pi_atomic()

From: Darren Hart
Date: Tue Mar 03 2009 - 12:29:55 EST


Peter Zijlstra wrote:

Hi Peter,

Thanks for taking a look.

On Mon, 2009-03-02 at 16:13 -0800, Darren Hart wrote:
+ * Returns:
+ * - 0 on success (futex_q is setup and FUTEX_WAITERS bit is set on the futex)
+ * - 1 on a successful atomic acquisition of the lock
+ * - A negative error code on failure

That utterly confused me for a while.

Sorry about that, guess my doc-fu needs some work.


Maybe something like:

0 - ready to wait
1 - acquired the lock

<0 - error

Sure thing, I've updated the patch and my git tree:

http://git.kernel.org/?p=linux/kernel/git/dvhart/linux-2.6-tip-hacks.git;a=shortlog;h=requeue-pi-dev

Note, this is a development branch and I continuously update it, replacing patches, etc.


--
Darren Hart
IBM Linux Technology Center
Real-Time Linux Team
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/