mirror of
https://github.com/ceph/ceph
synced 2025-01-02 09:02:34 +00:00
xio: Enable xio option to call fork init
Ceph fork when running as daemon. This fix call xio option to enforce Accelio to explicitly call ibv_fork_init() to avoid cq overrun issue. Signed-off-by: Vu Pham <vu@mellanox.com>
This commit is contained in:
parent
64a4cb8b1d
commit
c68ecc7431
@ -22,6 +22,7 @@
|
||||
#include "XioMsg.h"
|
||||
#include "XioMessenger.h"
|
||||
#include "common/address_helper.h"
|
||||
#include "common/code_environment.h"
|
||||
#include "messages/MNop.h"
|
||||
|
||||
#define dout_subsys ceph_subsys_xio
|
||||
@ -284,6 +285,12 @@ XioMessenger::XioMessenger(CephContext *cct, entity_name_t name,
|
||||
xio_set_opt(NULL, XIO_OPTLEVEL_ACCELIO, XIO_OPTNAME_DISABLE_HUGETBL,
|
||||
&xopt, sizeof(xopt));
|
||||
|
||||
if (g_code_env == CODE_ENVIRONMENT_DAEMON) {
|
||||
xopt = 1;
|
||||
xio_set_opt(NULL, XIO_OPTLEVEL_RDMA, XIO_OPTNAME_ENABLE_FORK_INIT,
|
||||
&xopt, sizeof(xopt));
|
||||
}
|
||||
|
||||
xopt = XIO_MSGR_IOVLEN;
|
||||
xio_set_opt(NULL, XIO_OPTLEVEL_ACCELIO, XIO_OPTNAME_MAX_IN_IOVLEN,
|
||||
&xopt, sizeof(xopt));
|
||||
|
Loading…
Reference in New Issue
Block a user