summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/vio.c
diff options
context:
space:
mode:
authorJulia Lawall <julia@diku.dk>2010-03-10 12:15:01 +0100
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2010-04-07 10:00:42 +0200
commit43caa61f154da85a620965f3f61c2f45366d8dc7 (patch)
treeea487c9de02013c1b5d4fad8d1fde7517244bf17 /arch/powerpc/kernel/vio.c
parentpowerpc/pseries/dlpar: Eliminate use after free (diff)
downloadlinux-43caa61f154da85a620965f3f61c2f45366d8dc7.tar.xz
linux-43caa61f154da85a620965f3f61c2f45366d8dc7.zip
powerpc/pseries/dlpar: Use kasprintf
kasprintf combines kmalloc and sprintf, and takes care of the size calculation itself. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression a,flag; expression list args; statement S; @@ a = - \(kmalloc\|kzalloc\)(...,flag) + kasprintf(flag,args) <... when != a if (a == NULL || ...) S ...> - sprintf(a,args); // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Acked-by: Nathan Fontenot <nfont@austin.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/vio.c')
0 files changed, 0 insertions, 0 deletions