]> www.infradead.org Git - users/dwmw2/linux.git/commit
cxgb4:Fix out-of-bounds MSI-X info array access
authorVishal Kulkarni <vishal@chelsio.com>
Thu, 3 Oct 2019 22:36:15 +0000 (04:06 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 Oct 2019 16:58:16 +0000 (18:58 +0200)
commita203f2d6b4eae63a962bc8e67f67a7e7eb3214a6
tree9801914cb03236c807f03abca4f56a3cf5c01688
parent076d9f965e561de3557c0cf9263b157b1c7380b9
cxgb4:Fix out-of-bounds MSI-X info array access

[ Upstream commit 6b517374f4ea5a3c6e307e1219ec5f35d42e6d00 ]

When fetching free MSI-X vectors for ULDs, check for the error code
before accessing MSI-X info array. Otherwise, an out-of-bounds access is
attempted, which results in kernel panic.

Fixes: 94cdb8bb993a ("cxgb4: Add support for dynamic allocation of resources for ULD")
Signed-off-by: Shahjada Abul Husain <shahjada@chelsio.com>
Signed-off-by: Vishal Kulkarni <vishal@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c