On Mon, 30 Jan 2012, Dmitry Antipov wrote:
> Fix pcpu_alloc() to return ZERO_SIZE_PTR if requested size is 0;
> fix free_percpu() to check passed pointer with ZERO_OR_NULL_PTR.
Acked-by: Christoph Lameter
___
linaro-dev mailing list
lina
On Mon, 30 Jan 2012, Tejun Heo wrote:
> I'm pretty sure it never gives out NULL for a dynamic allocation. The
> base might be mapped to zero but we're guaranteed to have some static
> percpu areas there and IIRC the percpu addresses aren't supposed to
> wrap.
True but there is a check for a NULL
On Mon, 30 Jan 2012, Tejun Heo wrote:
> Hello, Christoph.
>
> On Mon, Jan 30, 2012 at 11:52:23AM -0600, Christoph Lameter wrote:
> > We have two possibilities now:
> >
> > 1. We say that the value returned from the per cpu allocator is an opaque
> > value.
>
On Mon, 30 Jan 2012, Tejun Heo wrote:
> Hello,
>
> On Mon, Jan 30, 2012 at 11:58:52AM -0600, Christoph Lameter wrote:
> > > No, NULL is never gonna be a valid return from any allocator including
> > > percpu. Percpu allocator doesn't and will never do so.
>
On Mon, 30 Jan 2012, Tejun Heo wrote:
> On Mon, Jan 30, 2012 at 09:15:58AM -0800, Tejun Heo wrote:
> > Percpu pointers are in a different address space and using
> > ZERO_SIZE_PTR directly will trigger sparse address space warning.
> > Also, I'm not entirely sure whether 16 is guaranteed to be unu
On Mon, 30 Jan 2012, Tejun Heo wrote:
> Percpu pointers are in a different address space and using
> ZERO_SIZE_PTR directly will trigger sparse address space warning.
> Also, I'm not entirely sure whether 16 is guaranteed to be unused in
> percpu address space (maybe it is but I don't think we hav
On Mon, 30 Jan 2012, Tejun Heo wrote:
> Anyways, yeah, it seems we should improve this part too.
I agree.
___
linaro-dev mailing list
linaro-dev@lists.linaro.org
http://lists.linaro.org/mailman/listinfo/linaro-dev
On Mon, 30 Jan 2012, Tejun Heo wrote:
> On Mon, Jan 30, 2012 at 11:22:14AM -0600, Christoph Lameter wrote:
> > On Mon, 30 Jan 2012, Tejun Heo wrote:
> >
> > > Percpu pointers are in a different address space and using
> > > ZERO_SIZE_PTR directly will tri