Re: file locking fix for 3.2

From: Al Viro
Date: Sat Dec 24 2011 - 19:05:59 EST


On Sat, Dec 24, 2011 at 06:50:35PM -0500, J. Bruce Fields wrote:

> Then you're returning -ENOMEM in a case when we really didn't need to do
> an allocation, but is that really a problem? It's a rare case, and
> opens can already fail with -ENOMEM for other reasons, and I'd rather
> not have the extra hair.

I'm certainly OK with that variant; if the folks maintaining fs/locks.c
are happy with it, I'd suggest going for it. Note that you don't need
to touch locks_conflict() call at all if you bail out early on allocation
failure and it's definitely simpler and cleaner that way.
--
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/