lkml.org 
[lkml]   [2002]   [Jul]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] 2.5.27 spinlock
On Mon, 22 Jul 2002 12:50:22 +0200
Marcin Dalecki <dalecki@evision.ag> wrote:

> - Add missing _raw_write_trylock() definitions for the UP preemption case.
>
> - Replace tons of georgeous macros for the UP preemption case with
> static inline functions. Much nicer to look at and more adequate then
> ({ xxxx }) in this case.

Martin, this patch is wrong, obvious from casual reading:

> -#define spin_trylock_bh(lock) ({ int __r; local_bh_disable();\
> +#define spin_trylock_bh(lock) do { int __r; local_bh_disable();\
> __r = spin_trylock(lock); \
> if (!__r) local_bh_enable(); \
> - __r; })
> + __r; } while (0)

I know you're smarter than this Martin 8)

Rusty.
PS. If you want them re-xmitted to Linus, send to trivial@rustcorp.com.au...
--
there are those who do and those who hang on and you don't see too
many doers quoting their contemporaries. -- Larry McVoy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:22    [W:0.390 / U:0.988 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site