1
0
Fork 0

i40iw: Fix double free of allocated_buffer

Memory allocated for iwqp; iwqp->allocated_buffer is freed twice in
the create_qp error path. Correct this by having it freed only once in
i40iw_free_qp_resources().

Fixes: d374984179 ("i40iw: add files for iwarp interface")

Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com>
Signed-off-by: Shiraz Saleem <shiraz.saleem@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
steinar/wifi_calib_4_9_kernel
Mustafa Ismail 2016-08-23 16:50:13 -05:00 committed by Doug Ledford
parent 82d200cc6f
commit d41d0910d9
1 changed files with 0 additions and 1 deletions

View File

@ -794,7 +794,6 @@ static struct ib_qp *i40iw_create_qp(struct ib_pd *ibpd,
return &iwqp->ibqp;
error:
i40iw_free_qp_resources(iwdev, iwqp, qp_num);
kfree(mem);
return ERR_PTR(err_code);
}