]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
bnxt_en: Add a mutex to synchronize ULP operations
authorKalesh AP <kalesh-anakkur.purayil@broadcom.com>
Wed, 1 May 2024 00:30:54 +0000 (17:30 -0700)
committerJakub Kicinski <kuba@kernel.org>
Thu, 2 May 2024 14:27:20 +0000 (07:27 -0700)
commitde21ec442d411b17a2386cb6683acd18b047506d
tree39bc1b1ac845a8736970a7f919b8ddeef000e58d
parentf79d7a9f1c9d0cba9ae3d0cfd743c277d78dcf45
bnxt_en: Add a mutex to synchronize ULP operations

The current scheme relies heavily on the RTNL lock for all ULP
operations between the L2 and the RoCE driver.  Add a new en_dev_lock
mutex so that the asynchronous ULP_STOP and ULP_START operations
can be serialized with bnxt_register_dev() and bnxt_unregister_dev()
calls without relying on the RTNL lock.  The next patch will remove
the RTNL lock from the ULP_STOP and ULP_START calls.

Reviewed-by: Selvin Thyparampil Xavier <selvin.xavier@broadcom.com>
Reviewed-by: Vikas Gupta <vikas.gupta@broadcom.com>
Reviewed-by: Pavan Chebbi <pavan.chebbi@broadcom.com>
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://lore.kernel.org/r/20240501003056.100607-5-michael.chan@broadcom.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.h