]> git.baikalelectronics.ru Git - kernel.git/commit
cxgb4: fix the error path of cxgb4_uld_register()
authorGanesh Goudar <ganeshgr@chelsio.com>
Thu, 18 Oct 2018 14:04:19 +0000 (19:34 +0530)
committerDavid S. Miller <davem@davemloft.net>
Thu, 18 Oct 2018 23:26:36 +0000 (16:26 -0700)
commita51d6d07baea9f4cb4c466b839d89ec773c5b2d0
treea9acaee91fa26232905f9e857ebd42ac2158e70e
parent46d64f5b7aa58e04b0c515b167ca6e5856bec418
cxgb4: fix the error path of cxgb4_uld_register()

On multi adapter setup if the uld registration fails even on
one adapter, the allocated resources for the uld on all the
adapters are freed, rendering the functioning adapters unusable.

This commit fixes the issue by freeing the allocated resources
only for the failed adapter.

Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/crypto/chelsio/chcr_core.c
drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h