linux/drivers/infiniband/hw/mlx4
Dan Carpenter cab66d1273 IB/mlx4: Fix bug unwinding on error in mlx4_ib_init_sriov()
We have to decrement "i" before calling mlx4_ib_free_demux_ctx() or we
free something that wasn't allocated.  That's fine for free_pv_object()
but it would lead to a NULL dereference calling mlx4_ib_free_demux_ctx().
The null dereference is because ->tun is NULL when we check:

	if (!ctx->tun[i])

Also we didn't free ->sriov.demux[0] so it was a small leak.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
2013-02-15 15:22:26 -08:00
..
ah.c
alias_GUID.c IB/mlx4: Fix build error on platforms where UL is not 64 bits 2012-10-18 10:29:01 -07:00
cm.c IB/mlx4: Fix spinlock order to avoid lockdep warnings 2012-11-29 12:14:45 -08:00
cq.c mlx4: 64-byte CQE/EQE support 2012-11-26 10:19:17 -08:00
doorbell.c
Kconfig
mad.c IB/mlx4: Fix bug unwinding on error in mlx4_ib_init_sriov() 2013-02-15 15:22:26 -08:00
main.c mlx4: 64-byte CQE/EQE support 2012-11-26 10:19:17 -08:00
Makefile
mcg.c IB/mlx4: Synchronize cleanup of MCGs in MCG paravirtualization 2012-10-18 10:29:02 -07:00
mlx4_ib.h mlx4: 64-byte CQE/EQE support 2012-11-26 10:19:17 -08:00
mr.c
qp.c
srq.c
sysfs.c
user.h mlx4: 64-byte CQE/EQE support 2012-11-26 10:19:17 -08:00