Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
prov/efa: replace ibv_fork_init() with aborting at fork()
Currently, we call ibv_fork_init() to turn on rdma-core's support of fork safety by default, which has two issues: 1. it might be to late to call ibv_fork_init(), because application might have already called fork(). 2. it cause unecessary performance degradation for applications that does not use fork(). To address this issue, this patch remove the call to ibv_fork_init() Instead, it register a call back function using pthread_atfork(). The call back function is called when fork() is called, and will warn user about fork safety issue then abort. Signed-off-by: Wei Zhang <wzam@amazon.com>
- Loading branch information
Showing
1 changed file
with
45 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters