> > > > There's still the problem of cmpxchg meddling in the internals of an > > atomic_t. Is that OK? Will that work on all archs? > > Probably. It might be worth defining an atomic_cmpxchg() op to formalise it > though: > > int atomic_cmpxchg(atomic_t *p, int old, int new); > > The main reason for this is that atomic_t is mostly a 32-bit value, I think, > and cmpxchg() may sometimes enforce a 64-bit value. > > It can be made to work on PPC, PPC64, x86, x86_64, frv. I imagine it'll work > on MIPS, sparc and alpha too without too much trouble. Dunno about the rest. Any takers? I'd rather not do this, if I don't have to :) Do you think my original fix is wrong, or is this just cosmetics? Thanks, Miklos - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- References:
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- From: Miklos Szeredi <[email protected]>
- [PATCH] fix race in mark_mounts_for_expiry()
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Ram <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Ram <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Jamie Lokier <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Ram <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Jamie Lokier <[email protected]>
- Re: [PATCH] namespace.c: fix bind mount from foreign namespace
- From: Miklos Szeredi <[email protected]>
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- From: David Howells <[email protected]>
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- From: David Howells <[email protected]>
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- From: David Howells <[email protected]>
- Re: [PATCH] fix race in mark_mounts_for_expiry()
- Prev by Date: Re: Problem report: 2.6.12-rc4 ps2 keyboard being misdetected as /dev/input/mouse0
- Next by Date: Re: [SMP NICE] [PATCH] SCHED: Implement nice support across physical cpus on SMP
- Previous by thread: Re: [PATCH] fix race in mark_mounts_for_expiry()
- Next by thread: Re: [PATCH] fix race in mark_mounts_for_expiry()
- Index(es):