From: Matan Barak Date: Tue, 27 Jan 2015 13:58:07 +0000 (+0200) Subject: net/mlx4: Fix memory corruption in mlx4_MAD_IFC_wrapper X-Git-Tag: fixes-v4.0-rc1~150^2~113^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=19ab574f6271a2f912a449cfdea14a60098fba90;p=pandora-kernel.git net/mlx4: Fix memory corruption in mlx4_MAD_IFC_wrapper Fix a memory corruption at mlx4_MAD_IFC_wrapper. A table of size dev->caps.pkey_table_len[port]*sizeof(*table) was allocated, but get_full_pkey_table() assumes that the number of entries in the table is a multiplication of 32 (which isn't always correct). Fixes: 0a9a018 ('mlx4: MAD_IFC paravirtualization') Signed-off-by: Matan Barak Signed-off-by: Or Gerlitz Signed-off-by: Amir Vadai Signed-off-by: David S. Miller --- Reading git-diff-tree failed