[openib-general] [PATCH/RFC] libibverbs and libmthca fork support

Roland Dreier rdreier at cisco.com
Thu Aug 3 09:40:09 PDT 2006


    Gleb> We can also provide environment variable to control
    Gleb> libibverbs behaviour. This way if programmer made a wrong
    Gleb> assumption user will be able to fix it.

OK, I added this little snippet:

	if (getenv("RDMAV_FORK_SAFE") || getenv("IBV_FORK_SAFE"))
		if (ibv_fork_init())
			fprintf(stderr, PFX "Warning: fork()-safety requested "
				"but init failed\n");

so that setting either RDMAV_FORK_SAFE or IBV_FORK_SAFE environment
variables forces the library to try to be fork()-safe.

 - R.




More information about the general mailing list