Re: [PATCH 1/3] flex_array: flex_array_prealloc takes a number ofelements, not an end
From: Eric Paris
Date: Tue Apr 26 2011 - 15:06:49 EST
On Tue, 2011-04-26 at 11:56 -0700, Andrew Morton wrote:
> On Mon, 25 Apr 2011 21:45:31 -0400
> Eric Paris <eparis@xxxxxxxxxx> wrote:
>
> > Change flex_array_prealloc to take the number of elements for which space
> > should be allocated instead of the last (inclusive) element. Users
> > and documentation are updated accordingly.
>
> Why?
All three of these patches came from these discussions:
http://marc.info/?t=129552800100005&r=1&w=2
http://marc.info/?t=129646395700004&r=1&w=2
http://marc.info/?t=129708178200007&r=1&w=2
1/3 was changed just because it seemed to be the way the interface was
used
2/3 was changed because the 2.6.38 kernel fails to load certain selinux
policies which worked under 2.6.37 because of this lack of functionality
3/3 was changed just because that's how maybe it should work, although
there are no known users.
I can certainly update 2/3 to better explain the rational but I can't
really do any better on 1/3 and 3/3 other than to just say what the
change is......
-Eric
--
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/