staging: netlogic: Return zero pointer after failed kmalloc
commit11b49d9bb63fab2f92223419a2492661e317e2ef
authorLaura Garcia Liebana <nevola@gmail.com>
Thu, 18 Feb 2016 17:38:42 +0000 (18 18:38 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 20 Feb 2016 22:59:37 +0000 (20 14:59 -0800)
tree316c1608f524033173dfb3aa03ef4df5ce4df999
parentbf8b2bb6d84031b7207154046f120052435fb196
staging: netlogic: Return zero pointer after failed kmalloc

Return a ZERO_SIZE_PTR in the xlr_config_spill function if the
kmalloc returns an invalid value. This change prevents a possible
segmentation fault as the invalid pointer is fed into PTR_ALIGN macro.

Signed-off-by: Laura Garcia Liebana <nevola@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/netlogic/xlr_net.c