mirror of https://gitee.com/openkylin/linux.git
4a62c5e9e2
This fix is added only to avoid system crash in some a specific scenario. When bnxt_re driver is loaded and if user tries to change interface mac address, delete GID fails because QP1 is still associated with existing MAC (default GID). If the above command fails GID tables are not modified in the h/w or driver, but the GID context memory is freed. Now, if the user changes the mac back to the original value, another add_gid comes to the driver where the driver reports that the GID is already present in its table and tries to access the context which was already freed. So, in this case, in order to avoid NULL pointer de-reference, this patch removes the context memory free if delete_gid fails and the same context memory is re-used in new add_gid. Memory cleanup will be taken care during driver unload, while deleting the GID table. Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com> Signed-off-by: Selvin Xavier <selvin.xavier@broadcom.com> Signed-off-by: Doug Ledford <dledford@redhat.com> |
||
---|---|---|
.. | ||
Kconfig | ||
Makefile | ||
bnxt_re.h | ||
ib_verbs.c | ||
ib_verbs.h | ||
main.c | ||
qplib_fp.c | ||
qplib_fp.h | ||
qplib_rcfw.c | ||
qplib_rcfw.h | ||
qplib_res.c | ||
qplib_res.h | ||
qplib_sp.c | ||
qplib_sp.h | ||
roce_hsi.h |