ARM: 7597/1: net: bpf_jit_32: fix kzalloc gfp/size mismatch.
authorSchichan Nicolas <nschichan@freebox.fr>
Mon, 10 Dec 2012 13:49:39 +0000 (14:49 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 11 Dec 2012 00:16:59 +0000 (00:16 +0000)
commit89c2e00978ada02a5b84b361faee954cbc7a0386
treea6232be1fa89adcecf99ca91bcbcde4d06744047
parent026b7c6bf0bf044aa03e2affbda73b6c6a302538
ARM: 7597/1: net: bpf_jit_32: fix kzalloc gfp/size mismatch.

Official prototype for kzalloc is:

void *kzalloc(size_t, gfp_t);

The ARM bpf_jit code was having the assumption that it was:

void *kzalloc(gfp_t, size);

This was resulting the use of some random GFP flags depending on the
size requested and some random overflows once the really needed size
was more than the value of GFP_KERNEL.

This bug was present since the original inclusion of bpf_jit for ARM
(ddecdfce: ARM: 7259/3: net: JIT compiler for packet filters).

Signed-off-by: Nicolas Schichan <nschichan@freebox.fr>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/net/bpf_jit_32.c
This page took 0.04375 seconds and 5 git commands to generate.