In order to prevent name conflicts in XRC (MOFED) enabled mode
OFACM's ib_address_t was renamed to ofacm_ib_address_t This commit was SVN r28289.
Этот коммит содержится в:
родитель
1f011bef99
Коммит
aa1f5697b4
@ -38,10 +38,10 @@ static int xoob_component_finalize(void);
|
|||||||
static int xoob_module_start_connect
|
static int xoob_module_start_connect
|
||||||
(ompi_common_ofacm_base_local_connection_context_t *context);
|
(ompi_common_ofacm_base_local_connection_context_t *context);
|
||||||
|
|
||||||
static void xoob_ib_address_constructor(ib_address_t *ib_addr);
|
static void xoob_ib_address_constructor(ofacm_ib_address_t *ib_addr);
|
||||||
static void xoob_ib_address_destructor(ib_address_t *ib_addr);
|
static void xoob_ib_address_destructor(ofacm_ib_address_t *ib_addr);
|
||||||
|
|
||||||
OBJ_CLASS_INSTANCE(ib_address_t,
|
OBJ_CLASS_INSTANCE(ofacm_ib_address_t,
|
||||||
opal_list_item_t,
|
opal_list_item_t,
|
||||||
xoob_ib_address_constructor,
|
xoob_ib_address_constructor,
|
||||||
xoob_ib_address_destructor);
|
xoob_ib_address_destructor);
|
||||||
@ -129,7 +129,7 @@ OBJ_CLASS_INSTANCE(pending_context_t,
|
|||||||
xoob_pending_context_constructor,
|
xoob_pending_context_constructor,
|
||||||
xoob_pending_context_destructor);
|
xoob_pending_context_destructor);
|
||||||
|
|
||||||
static void xoob_ib_address_constructor(ib_address_t *ib_addr)
|
static void xoob_ib_address_constructor(ofacm_ib_address_t *ib_addr)
|
||||||
{
|
{
|
||||||
ib_addr->key = NULL;
|
ib_addr->key = NULL;
|
||||||
ib_addr->subnet_id = 0;
|
ib_addr->subnet_id = 0;
|
||||||
@ -140,7 +140,7 @@ static void xoob_ib_address_constructor(ib_address_t *ib_addr)
|
|||||||
OBJ_CONSTRUCT(&ib_addr->pending_contexts, opal_list_t);
|
OBJ_CONSTRUCT(&ib_addr->pending_contexts, opal_list_t);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void xoob_ib_address_destructor(ib_address_t *ib_addr)
|
static void xoob_ib_address_destructor(ofacm_ib_address_t *ib_addr)
|
||||||
{
|
{
|
||||||
if(NULL != ib_addr->qps && NULL != ib_addr->qps[0].lcl_qp) {
|
if(NULL != ib_addr->qps && NULL != ib_addr->qps[0].lcl_qp) {
|
||||||
if(ibv_destroy_qp(ib_addr->qps[0].lcl_qp)) {
|
if(ibv_destroy_qp(ib_addr->qps[0].lcl_qp)) {
|
||||||
@ -154,7 +154,7 @@ static void xoob_ib_address_destructor(ib_address_t *ib_addr)
|
|||||||
OBJ_DESTRUCT(&ib_addr->pending_contexts);
|
OBJ_DESTRUCT(&ib_addr->pending_contexts);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int xoob_ib_address_init(ib_address_t *ib_addr, uint16_t lid, uint64_t s_id, ompi_jobid_t ep_jobid)
|
static int xoob_ib_address_init(ofacm_ib_address_t *ib_addr, uint16_t lid, uint64_t s_id, ompi_jobid_t ep_jobid)
|
||||||
{
|
{
|
||||||
ib_addr->key = malloc(SIZE_OF3(s_id, lid, ep_jobid));
|
ib_addr->key = malloc(SIZE_OF3(s_id, lid, ep_jobid));
|
||||||
if (NULL == ib_addr->key) {
|
if (NULL == ib_addr->key) {
|
||||||
@ -178,12 +178,12 @@ static int xoob_ib_address_init(ib_address_t *ib_addr, uint16_t lid, uint64_t s_
|
|||||||
* update the context pointer.
|
* update the context pointer.
|
||||||
* Before call to this function you need to protect with
|
* Before call to this function you need to protect with
|
||||||
*/
|
*/
|
||||||
static ib_address_t* xoob_ib_address_add_new (ompi_common_ofacm_xoob_module_t *xcpc,
|
static ofacm_ib_address_t* xoob_ib_address_add_new (ompi_common_ofacm_xoob_module_t *xcpc,
|
||||||
uint16_t lid, uint64_t s_id, ompi_jobid_t ep_jobid)
|
uint16_t lid, uint64_t s_id, ompi_jobid_t ep_jobid)
|
||||||
{
|
{
|
||||||
void *tmp;
|
void *tmp;
|
||||||
int ret;
|
int ret;
|
||||||
struct ib_address_t *ib_addr = OBJ_NEW(ib_address_t);
|
struct ofacm_ib_address_t *ib_addr = OBJ_NEW(ofacm_ib_address_t);
|
||||||
|
|
||||||
ret = xoob_ib_address_init(ib_addr, lid, s_id, ep_jobid);
|
ret = xoob_ib_address_init(ib_addr, lid, s_id, ep_jobid);
|
||||||
if (OMPI_SUCCESS != ret ) {
|
if (OMPI_SUCCESS != ret ) {
|
||||||
@ -207,7 +207,7 @@ static ib_address_t* xoob_ib_address_add_new (ompi_common_ofacm_xoob_module_t *x
|
|||||||
} else {
|
} else {
|
||||||
/* so we have this one in the table, just return the pointer */
|
/* so we have this one in the table, just return the pointer */
|
||||||
OBJ_DESTRUCT(ib_addr);
|
OBJ_DESTRUCT(ib_addr);
|
||||||
ib_addr = (ib_address_t *)tmp;
|
ib_addr = (ofacm_ib_address_t *)tmp;
|
||||||
OBJ_RETAIN(ib_addr);
|
OBJ_RETAIN(ib_addr);
|
||||||
assert(lid == ib_addr->lid && s_id == ib_addr->subnet_id);
|
assert(lid == ib_addr->lid && s_id == ib_addr->subnet_id);
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@ typedef enum {
|
|||||||
XOOB_ADDR_CLOSED
|
XOOB_ADDR_CLOSED
|
||||||
} ompi_common_ofacm_ib_addr_state_t;
|
} ompi_common_ofacm_ib_addr_state_t;
|
||||||
|
|
||||||
struct ib_address_t {
|
struct ofacm_ib_address_t {
|
||||||
opal_list_item_t super;
|
opal_list_item_t super;
|
||||||
void *key; /* the key with size 80bit - [subnet(64) LID(16bit)] */
|
void *key; /* the key with size 80bit - [subnet(64) LID(16bit)] */
|
||||||
uint64_t subnet_id; /* caching subnet_id */
|
uint64_t subnet_id; /* caching subnet_id */
|
||||||
@ -37,12 +37,12 @@ struct ib_address_t {
|
|||||||
opal_mutex_t addr_lock; /* protection */
|
opal_mutex_t addr_lock; /* protection */
|
||||||
ompi_common_ofacm_ib_addr_state_t status; /* ib port status */
|
ompi_common_ofacm_ib_addr_state_t status; /* ib port status */
|
||||||
};
|
};
|
||||||
typedef struct ib_address_t
|
typedef struct ofacm_ib_address_t
|
||||||
ib_address_t;
|
ofacm_ib_address_t;
|
||||||
|
|
||||||
struct ompi_common_ofacm_xoob_local_connection_context_t {
|
struct ompi_common_ofacm_xoob_local_connection_context_t {
|
||||||
ompi_common_ofacm_base_local_connection_context_t super;
|
ompi_common_ofacm_base_local_connection_context_t super;
|
||||||
ib_address_t *addr;
|
ofacm_ib_address_t *addr;
|
||||||
uint32_t xrc_recv_qp_num; /* in xrc we will use it as recv qp */
|
uint32_t xrc_recv_qp_num; /* in xrc we will use it as recv qp */
|
||||||
uint32_t xrc_recv_psn;
|
uint32_t xrc_recv_psn;
|
||||||
};
|
};
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user