[Pvfs2-cvs] commit by slang in pvfs2/src/io/bmi:
bmi-method-callback.h bmi-method-support.c
bmi-method-support.h bmi.c op-list.c op-list.h
reference-list.c reference-list.h
CVS commit program
cvs at parl.clemson.edu
Tue Nov 6 18:08:33 EST 2007
Update of /projects/cvsroot/pvfs2/src/io/bmi
In directory parlweb1:/tmp/cvs-serv10213/src/io/bmi
Modified Files:
bmi-method-callback.h bmi-method-support.c
bmi-method-support.h bmi.c op-list.c op-list.h
reference-list.c reference-list.h
Log Message:
bmi cleanups.
Index: bmi-method-callback.h
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/bmi-method-callback.h,v
diff -p -u -r1.6 -r1.7
--- bmi-method-callback.h 9 Oct 2007 21:58:29 -0000 1.6
+++ bmi-method-callback.h 6 Nov 2007 23:08:33 -0000 1.7
@@ -9,7 +9,7 @@
#include "bmi-method-support.h"
-PVFS_BMI_addr_t bmi_method_addr_reg_callback(method_addr_p map);
+PVFS_BMI_addr_t bmi_method_addr_reg_callback(bmi_method_addr_p map);
int bmi_method_addr_forget_callback(PVFS_BMI_addr_t addr);
#endif /* __BMI_METHOD_CALLBACK_H */
Index: bmi-method-support.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/bmi-method-support.c,v
diff -p -u -r1.11 -r1.12
--- bmi-method-support.c 22 Aug 2007 16:12:44 -0000 1.11
+++ bmi-method-support.c 6 Nov 2007 23:08:33 -0000 1.12
@@ -23,7 +23,7 @@
*
* returns a pointer to the new structure on success, NULL on failure.
*/
-method_op_p alloc_method_op(bmi_size_t payload_size)
+method_op_p bmi_alloc_method_op(bmi_size_t payload_size)
{
/* we are going to allocate the full operation structure as a
@@ -63,7 +63,7 @@ method_op_p alloc_method_op(bmi_size_t p
*
* no return value
*/
-void dealloc_method_op(method_op_p op_p)
+void bmi_dealloc_method_op(method_op_p op_p)
{
id_gen_fast_unregister(op_p->op_id);
free(op_p);
@@ -81,7 +81,7 @@ void dealloc_method_op(method_op_p op_p)
* Returns a pointer to an allocated method_addr struct on success,
* NULL on failure.
*/
-struct method_addr *alloc_method_addr(int method_type,
+struct bmi_method_addr *bmi_alloc_method_addr(int method_type,
bmi_size_t payload_size)
{
@@ -90,10 +90,10 @@ struct method_addr *alloc_method_addr(in
* the memory address immediately following the method_addr
* structure.
*/
- struct method_addr *my_method_addr = NULL;
- int ssize = sizeof(struct method_addr);
+ struct bmi_method_addr *my_method_addr = NULL;
+ int ssize = sizeof(struct bmi_method_addr);
/* generic component */
- my_method_addr = (struct method_addr *) malloc(ssize + payload_size);
+ my_method_addr = (struct bmi_method_addr *) malloc(ssize + payload_size);
if (!my_method_addr)
{
return (NULL);
@@ -116,7 +116,7 @@ struct method_addr *alloc_method_addr(in
*
* no return value
*/
-void dealloc_method_addr(method_addr_p my_method_addr)
+void bmi_dealloc_method_addr(bmi_method_addr_p my_method_addr)
{
free(my_method_addr);
my_method_addr = NULL;
Index: bmi-method-support.h
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/bmi-method-support.h,v
diff -p -u -r1.29 -r1.30
--- bmi-method-support.h 18 Jul 2007 21:32:57 -0000 1.29
+++ bmi-method-support.h 6 Nov 2007 23:08:33 -0000 1.30
@@ -39,18 +39,19 @@
* information for every protocol we support. The method routines
* upcast the void* to find their particular device information.
*/
-struct method_addr
+struct bmi_method_addr
{
int method_type;
+ struct bmi_method_ops *ops;
void *method_data; /* area to be used by specific methods */
};
-typedef struct method_addr method_addr_st, *method_addr_p;
+typedef struct bmi_method_addr bmi_method_addr_st, *bmi_method_addr_p;
/* used to describe unexpected messages that arrive */
-struct method_unexpected_info
+struct bmi_method_unexpected_info
{
bmi_error_code_t error_code;
- method_addr_p addr;
+ bmi_method_addr_p addr;
void *buffer;
bmi_size_t size;
bmi_msg_tag_t tag;
@@ -62,112 +63,105 @@ struct method_unexpected_info
struct bmi_method_ops
{
const char *method_name;
- int (*BMI_meth_initialize) (method_addr_p,
- int,
- int);
- int (*BMI_meth_finalize) (void);
- int (*BMI_meth_set_info) (int,
- void *);
- int (*BMI_meth_get_info) (int,
- void *);
- void *(*BMI_meth_memalloc) (bmi_size_t,
- enum bmi_op_type);
- int (*BMI_meth_memfree) (void *,
- bmi_size_t,
- enum bmi_op_type);
-
- int (*BMI_meth_unexpected_free) (void *);
-
- int (*BMI_meth_post_send) (bmi_op_id_t *,
- method_addr_p,
- const void *,
- bmi_size_t,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_post_sendunexpected) (bmi_op_id_t *,
- method_addr_p,
- const void *,
- bmi_size_t,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_post_recv) (bmi_op_id_t *,
- method_addr_p,
- void *,
- bmi_size_t,
- bmi_size_t *,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_test) (bmi_op_id_t,
- int *,
- bmi_error_code_t *,
- bmi_size_t *,
- void **,
- int,
- bmi_context_id);
- int (*BMI_meth_testsome) (int,
- bmi_op_id_t *,
- int *,
- int *,
- bmi_error_code_t *,
- bmi_size_t *,
- void **,
- int,
- bmi_context_id);
- int (*BMI_meth_testcontext) (int,
- bmi_op_id_t*,
- int *,
- bmi_error_code_t *,
- bmi_size_t *,
- void **,
- int,
- bmi_context_id);
- int (*BMI_meth_testunexpected) (int,
- int *,
- struct method_unexpected_info *,
- int);
- method_addr_p (*BMI_meth_method_addr_lookup) (const char *);
- int (*BMI_meth_post_send_list) (bmi_op_id_t *,
- method_addr_p,
- const void *const *,
- const bmi_size_t *,
- int,
- bmi_size_t,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_post_recv_list) (bmi_op_id_t *,
- method_addr_p,
- void *const *,
- const bmi_size_t *,
- int,
- bmi_size_t,
- bmi_size_t *,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_post_sendunexpected_list) (bmi_op_id_t *,
- method_addr_p,
- const void *const *,
- const bmi_size_t *,
- int,
- bmi_size_t,
- enum bmi_buffer_type,
- bmi_msg_tag_t,
- void *,
- bmi_context_id);
- int (*BMI_meth_open_context)(bmi_context_id);
- void (*BMI_meth_close_context)(bmi_context_id);
- int (*BMI_meth_cancel)(bmi_op_id_t, bmi_context_id);
- const char* (*BMI_meth_rev_lookup_unexpected)(method_addr_p);
- int (*BMI_meth_query_addr_range)(method_addr_p, const char *, int);
+ int (*initialize) (bmi_method_addr_p, int, int);
+ int (*finalize) (void);
+ int (*set_info) (int, void *);
+ int (*get_info) (int, void *);
+ void *(*memalloc) (bmi_size_t, enum bmi_op_type);
+ int (*memfree) (void *, bmi_size_t, enum bmi_op_type);
+
+ int (*unexpected_free) (void *);
+
+ int (*post_send) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ const void *,
+ bmi_size_t,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*post_sendunexpected) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ const void *,
+ bmi_size_t,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*post_recv) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ void *,
+ bmi_size_t,
+ bmi_size_t *,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*test) (bmi_op_id_t,
+ int *,
+ bmi_error_code_t *,
+ bmi_size_t *,
+ void **,
+ int,
+ bmi_context_id);
+ int (*testsome) (int,
+ bmi_op_id_t *,
+ int *,
+ int *,
+ bmi_error_code_t *,
+ bmi_size_t *,
+ void **,
+ int,
+ bmi_context_id);
+ int (*testcontext) (int,
+ bmi_op_id_t*,
+ int *,
+ bmi_error_code_t *,
+ bmi_size_t *,
+ void **,
+ int,
+ bmi_context_id);
+ int (*testunexpected) (int,
+ int *,
+ struct bmi_method_unexpected_info *,
+ int);
+ bmi_method_addr_p (*method_addr_lookup) (const char *);
+ int (*post_send_list) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ const void *const *,
+ const bmi_size_t *,
+ int,
+ bmi_size_t,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*post_recv_list) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ void *const *,
+ const bmi_size_t *,
+ int,
+ bmi_size_t,
+ bmi_size_t *,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*post_sendunexpected_list) (bmi_op_id_t *,
+ bmi_method_addr_p,
+ const void *const *,
+ const bmi_size_t *,
+ int,
+ bmi_size_t,
+ enum bmi_buffer_type,
+ bmi_msg_tag_t,
+ void *,
+ bmi_context_id);
+ int (*open_context)(bmi_context_id);
+ void (*close_context)(bmi_context_id);
+ int (*cancel)(bmi_op_id_t, bmi_context_id);
+ const char* (*rev_lookup_unexpected)(bmi_method_addr_p);
+ int (*query_addr_range)(bmi_method_addr_p, const char *, int);
};
@@ -190,7 +184,7 @@ struct method_op
void *buffer; /* the memory region to transfer */
bmi_size_t actual_size; /* total size of the transfer */
bmi_size_t expected_size; /* expected size of the transfer */
- method_addr_st *addr; /* peer address involved in the communication */
+ bmi_method_addr_st *addr; /* peer address involved in the communication */
int mode; /* operation mode */
bmi_context_id context_id; /* context */
struct qlist_head op_list_entry; /* op_list link */
@@ -212,7 +206,7 @@ typedef struct method_op method_op_st, *
struct method_drop_addr_query
{
- struct method_addr* addr;
+ struct bmi_method_addr* addr;
int response;
};
@@ -221,13 +215,13 @@ struct method_drop_addr_query
*/
/* functions for managing operations */
-method_op_p alloc_method_op(bmi_size_t payload_size);
-void dealloc_method_op(method_op_p op_p);
+method_op_p bmi_alloc_method_op(bmi_size_t payload_size);
+void bmi_dealloc_method_op(method_op_p op_p);
/* These functions can be used to manage generic address structures */
-method_addr_p alloc_method_addr(int method_type,
+bmi_method_addr_p bmi_alloc_method_addr(int method_type,
bmi_size_t payload_size);
-void dealloc_method_addr(method_addr_p old_method_addr);
+void bmi_dealloc_method_addr(bmi_method_addr_p old_method_addr);
/* string parsing utilities */
char *string_key(const char *key,
Index: bmi.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/bmi.c,v
diff -p -u -r1.88 -r1.89
--- bmi.c 20 Oct 2007 15:40:13 -0000 1.88
+++ bmi.c 6 Nov 2007 23:08:33 -0000 1.89
@@ -214,7 +214,7 @@ int BMI_initialize(const char *method_li
if(!strncmp(listen_addrs[j], proto, strlen(proto)))
{
/* found the right addr */
- this_addr = listen_addrs[j];
+ this_addr = strstr(listen_addrs[j], "://") + 3;
break;
}
}
@@ -265,7 +265,7 @@ int BMI_initialize(const char *method_li
{
if (active_method_table[i])
{
- active_method_table[i]->BMI_meth_finalize();
+ active_method_table[i]->finalize();
}
}
free(active_method_table);
@@ -471,7 +471,7 @@ int BMI_finalize(void)
/* attempt to shut down active methods */
for (i = 0; i < active_method_count; i++)
{
- active_method_table[i]->BMI_meth_finalize();
+ active_method_table[i]->finalize();
}
active_method_count = 0;
free(active_method_table);
@@ -524,7 +524,7 @@ int BMI_open_context(bmi_context_id* con
/* tell all of the modules about the new context */
for (i = 0; i < active_method_count; i++)
{
- ret = active_method_table[i]->BMI_meth_open_context(
+ ret = active_method_table[i]->open_context(
context_index);
if(ret < 0)
{
@@ -535,7 +535,7 @@ int BMI_open_context(bmi_context_id* con
--i;
while (i >= 0)
{
- active_method_table[i]->BMI_meth_close_context(
+ active_method_table[i]->close_context(
context_index);
--i;
}
@@ -572,7 +572,7 @@ void BMI_close_context(bmi_context_id co
gen_mutex_lock(&active_method_count_mutex);
for (i = 0; i < active_method_count; i++)
{
- active_method_table[i]->BMI_meth_close_context(context_id);
+ active_method_table[i]->close_context(context_id);
}
context_array[context_id] = 0;
gen_mutex_unlock(&active_method_count_mutex);
@@ -614,7 +614,7 @@ int BMI_post_recv(bmi_op_id_t * id,
}
gen_mutex_unlock(&ref_mutex);
- ret = tmp_ref->interface->BMI_meth_post_recv(
+ ret = tmp_ref->interface->post_recv(
id, tmp_ref->method_addr, buffer, expected_size, actual_size,
buffer_type, tag, user_ptr, context_id);
return (ret);
@@ -652,7 +652,7 @@ int BMI_post_send(bmi_op_id_t * id,
}
gen_mutex_unlock(&ref_mutex);
- ret = tmp_ref->interface->BMI_meth_post_send(
+ ret = tmp_ref->interface->post_send(
id, tmp_ref->method_addr, buffer, size, buffer_type, tag,
user_ptr, context_id);
return (ret);
@@ -690,7 +690,7 @@ int BMI_post_sendunexpected(bmi_op_id_t
}
gen_mutex_unlock(&ref_mutex);
- ret = tmp_ref->interface->BMI_meth_post_sendunexpected(
+ ret = tmp_ref->interface->post_sendunexpected(
id, tmp_ref->method_addr, buffer, size, buffer_type, tag,
user_ptr, context_id);
return (ret);
@@ -721,7 +721,7 @@ int BMI_test(bmi_op_id_t id,
assert(target_op->op_id == id);
ret = active_method_table[
- target_op->addr->method_type]->BMI_meth_test(
+ target_op->addr->method_type]->test(
id, outcount, error_code, actual_size, user_ptr,
max_idle_time_ms, context_id);
@@ -773,7 +773,7 @@ int BMI_testsome(int incount,
if (tmp_active_method_count == 1) {
/* shortcircuit for perhaps common case of only one method */
- ret = active_method_table[0]->BMI_meth_testsome(
+ ret = active_method_table[0]->testsome(
incount, id_array, outcount, index_array,
error_code_array, actual_size_array, user_ptr_array,
max_idle_time_ms, context_id);
@@ -823,7 +823,7 @@ int BMI_testsome(int incount,
if(need_to_test)
{
tmp_outcount = 0;
- ret = active_method_table[i]->BMI_meth_testsome(
+ ret = active_method_table[i]->testsome(
need_to_test, tmp_id_array, &tmp_outcount,
&(index_array[*outcount]),
&(error_code_array[*outcount]),
@@ -917,7 +917,7 @@ int BMI_testunexpected(int incount,
int ret = -1;
int position = 0;
int tmp_outcount = 0;
- struct method_unexpected_info sub_info[incount];
+ struct bmi_method_unexpected_info sub_info[incount];
ref_st_p tmp_ref = NULL;
int tmp_active_method_count = 0;
@@ -938,7 +938,7 @@ int BMI_testunexpected(int incount,
while (position < incount && i < tmp_active_method_count)
{
if (method_usage[i].plan) {
- ret = active_method_table[i]->BMI_meth_testunexpected(
+ ret = active_method_table[i]->testunexpected(
(incount - position), &tmp_outcount,
(&(sub_info[position])), max_idle_time_ms);
if (ret < 0)
@@ -1031,7 +1031,7 @@ int BMI_testcontext(int incount,
while (position < incount && i < tmp_active_method_count)
{
if (method_usage[i].plan) {
- ret = active_method_table[i]->BMI_meth_testcontext(
+ ret = active_method_table[i]->testcontext(
incount - position,
&out_id_array[position],
&tmp_outcount,
@@ -1120,12 +1120,12 @@ const char* BMI_addr_rev_lookup_unexpect
}
gen_mutex_unlock(&ref_mutex);
- if(!tmp_ref->interface->BMI_meth_rev_lookup_unexpected)
+ if(!tmp_ref->interface->rev_lookup_unexpected)
{
return("UNKNOWN");
}
- return(tmp_ref->interface->BMI_meth_rev_lookup_unexpected(
+ return(tmp_ref->interface->rev_lookup_unexpected(
tmp_ref->method_addr));
}
@@ -1152,7 +1152,7 @@ void *BMI_memalloc(PVFS_BMI_addr_t addr,
gen_mutex_unlock(&ref_mutex);
/* allocate the buffer using the method's mechanism */
- new_buffer = tmp_ref->interface->BMI_meth_memalloc(size, send_recv);
+ new_buffer = tmp_ref->interface->memalloc(size, send_recv);
return (new_buffer);
}
@@ -1180,7 +1180,7 @@ int BMI_memfree(PVFS_BMI_addr_t addr,
gen_mutex_unlock(&ref_mutex);
/* free the memory */
- ret = tmp_ref->interface->BMI_meth_memfree(buffer, size, send_recv);
+ ret = tmp_ref->interface->memfree(buffer, size, send_recv);
return (ret);
}
@@ -1206,13 +1206,13 @@ int BMI_unexpected_free(PVFS_BMI_addr_t
}
gen_mutex_unlock(&ref_mutex);
- if (!tmp_ref->interface->BMI_meth_unexpected_free)
+ if (!tmp_ref->interface->unexpected_free)
{
- gossip_err("unimplemented BMI_meth_unexpected_free callback\n");
+ gossip_err("unimplemented unexpected_free callback\n");
return bmi_errno_to_pvfs(-EOPNOTSUPP);
}
/* free the memory */
- ret = tmp_ref->interface->BMI_meth_unexpected_free(buffer);
+ ret = tmp_ref->interface->unexpected_free(buffer);
return (ret);
}
@@ -1244,7 +1244,7 @@ int BMI_set_info(PVFS_BMI_addr_t addr,
gen_mutex_lock(&active_method_count_mutex);
for (i = 0; i < active_method_count; i++)
{
- ret = active_method_table[i]->BMI_meth_set_info(
+ ret = active_method_table[i]->set_info(
option, inout_parameter);
/* we bail out if even a single set_info fails */
if (ret < 0)
@@ -1320,7 +1320,7 @@ int BMI_set_info(PVFS_BMI_addr_t addr,
gen_mutex_unlock(&ref_mutex);
- ret = tmp_ref->interface->BMI_meth_set_info(option, inout_parameter);
+ ret = tmp_ref->interface->set_info(option, inout_parameter);
return (ret);
}
@@ -1358,7 +1358,7 @@ int BMI_get_info(PVFS_BMI_addr_t addr,
gen_mutex_lock(&active_method_count_mutex);
for (i = 0; i < active_method_count; i++)
{
- ret = active_method_table[i]->BMI_meth_get_info(
+ ret = active_method_table[i]->get_info(
option, &tmp_maxsize);
if (ret < 0)
{
@@ -1397,7 +1397,7 @@ int BMI_get_info(PVFS_BMI_addr_t addr,
return (bmi_errno_to_pvfs(-EINVAL));
}
gen_mutex_unlock(&ref_mutex);
- ret = tmp_ref->interface->BMI_meth_get_info(
+ ret = tmp_ref->interface->get_info(
option, inout_parameter);
if(ret < 0)
{
@@ -1464,9 +1464,9 @@ int BMI_query_addr_range (PVFS_BMI_addr_
/* provided name matches this interface */
if (!strncmp(active_method_name, provided_method_name, provided_method_length))
{
- int (*meth_fnptr)(method_addr_p, const char *, int);
+ int (*meth_fnptr)(bmi_method_addr_p, const char *, int);
failed = 0;
- if ((meth_fnptr = active_method_table[i]->BMI_meth_query_addr_range) == NULL)
+ if ((meth_fnptr = active_method_table[i]->query_addr_range) == NULL)
{
ret = -ENOSYS;
gossip_lerr("Error: method doesn't implement querying address range/wildcards! Cannot implement FS export options!\n");
@@ -1498,7 +1498,7 @@ int BMI_addr_lookup(PVFS_BMI_addr_t * ne
{
ref_st_p new_ref = NULL;
- method_addr_p meth_addr = NULL;
+ bmi_method_addr_p meth_addr = NULL;
int ret = -1;
int i = 0;
int failed;
@@ -1531,8 +1531,7 @@ int BMI_addr_lookup(PVFS_BMI_addr_t * ne
i = 0;
gen_mutex_lock(&active_method_count_mutex);
while ((i < active_method_count) &&
- !(meth_addr = active_method_table[i]->
- BMI_meth_method_addr_lookup(id_string)))
+ !(meth_addr = active_method_table[i]->method_addr_lookup(id_string)))
{
i++;
}
@@ -1559,7 +1558,7 @@ int BMI_addr_lookup(PVFS_BMI_addr_t * ne
break;
}
meth_addr = known_method_table[i]->
- BMI_meth_method_addr_lookup(id_string);
+ method_addr_lookup(id_string + strlen(name) + 3);
i = active_method_count - 1; /* point at the new one */
break;
}
@@ -1606,7 +1605,7 @@ int BMI_addr_lookup(PVFS_BMI_addr_t * ne
if (meth_addr)
{
- active_method_table[i]->BMI_meth_set_info(
+ active_method_table[i]->set_info(
BMI_DROP_ADDR, meth_addr);
}
@@ -1666,9 +1665,9 @@ int BMI_post_send_list(bmi_op_id_t * id,
}
gen_mutex_unlock(&ref_mutex);
- if (tmp_ref->interface->BMI_meth_post_send_list)
+ if (tmp_ref->interface->post_send_list)
{
- ret = tmp_ref->interface->BMI_meth_post_send_list(
+ ret = tmp_ref->interface->post_send_list(
id, tmp_ref->method_addr, buffer_list, size_list,
list_count, total_size, buffer_type, tag, user_ptr,
context_id);
@@ -1733,9 +1732,9 @@ int BMI_post_recv_list(bmi_op_id_t * id,
}
gen_mutex_unlock(&ref_mutex);
- if (tmp_ref->interface->BMI_meth_post_recv_list)
+ if (tmp_ref->interface->post_recv_list)
{
- ret = tmp_ref->interface->BMI_meth_post_recv_list(
+ ret = tmp_ref->interface->post_recv_list(
id, tmp_ref->method_addr, buffer_list, size_list,
list_count, total_expected_size, total_actual_size,
buffer_type, tag, user_ptr, context_id);
@@ -1799,9 +1798,9 @@ int BMI_post_sendunexpected_list(bmi_op_
}
gen_mutex_unlock(&ref_mutex);
- if (tmp_ref->interface->BMI_meth_post_send_list)
+ if (tmp_ref->interface->post_send_list)
{
- ret = tmp_ref->interface->BMI_meth_post_sendunexpected_list(
+ ret = tmp_ref->interface->post_sendunexpected_list(
id, tmp_ref->method_addr, buffer_list, size_list,
list_count, total_size, buffer_type, tag, user_ptr,
context_id);
@@ -1842,10 +1841,10 @@ int BMI_cancel(bmi_op_id_t id,
assert(target_op->op_id == id);
- if(active_method_table[target_op->addr->method_type]->BMI_meth_cancel)
+ if(active_method_table[target_op->addr->method_type]->cancel)
{
ret = active_method_table[
- target_op->addr->method_type]->BMI_meth_cancel(
+ target_op->addr->method_type]->cancel(
id, context_id);
}
else
@@ -1870,12 +1869,12 @@ int BMI_cancel(bmi_op_id_t id,
* of a socket accept() and get a new connection.
*
* Do not call this function for active lookups, that is from your
- * BMI_meth_method_addr_lookup. BMI already knows about the address in
+ * method_addr_lookup. BMI already knows about the address in
* this case, since the user provided it.
*
* returns 0 on success, -errno on failure
*/
-PVFS_BMI_addr_t bmi_method_addr_reg_callback(method_addr_p map)
+PVFS_BMI_addr_t bmi_method_addr_reg_callback(bmi_method_addr_p map)
{
ref_st_p new_ref = NULL;
@@ -1939,7 +1938,7 @@ activate_method(const char *name, const
int i, ret;
void *x;
struct bmi_method_ops *meth;
- method_addr_p new_addr;
+ bmi_method_addr_p new_addr;
/* already active? */
for (i=0; i<active_method_count; i++)
@@ -1995,7 +1994,7 @@ activate_method(const char *name, const
/* initialize it */
new_addr = 0;
if (listen_addr) {
- new_addr = meth->BMI_meth_method_addr_lookup(listen_addr);
+ new_addr = meth->method_addr_lookup(listen_addr);
if (!new_addr) {
gossip_err(
"Error: failed to lookup listen address %s for method %s.\n",
@@ -2006,7 +2005,7 @@ activate_method(const char *name, const
/* this is a bit of a hack */
new_addr->method_type = active_method_count - 1;
}
- ret = meth->BMI_meth_initialize(new_addr, active_method_count - 1, flags);
+ ret = meth->initialize(new_addr, active_method_count - 1, flags);
if (ret < 0) {
gossip_debug(GOSSIP_BMI_DEBUG_CONTROL,
"failed to initialize method %s.\n", name);
@@ -2017,7 +2016,7 @@ activate_method(const char *name, const
/* tell it about any open contexts */
for (i=0; i<BMI_MAX_CONTEXTS; i++)
if (context_array[i]) {
- ret = meth->BMI_meth_open_context(i);
+ ret = meth->open_context(i);
if (ret < 0)
break;
}
@@ -2151,7 +2150,7 @@ static void bmi_addr_drop(ref_st_p tmp_r
* the address; TCP will tell us to drop addresses for which the
* socket has died with no possibility of reconnect
*/
- ret = tmp_ref->interface->BMI_meth_get_info(BMI_DROP_ADDR_QUERY,
+ ret = tmp_ref->interface->get_info(BMI_DROP_ADDR_QUERY,
&query);
if(ret == 0 && query.response == 1)
{
Index: op-list.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/op-list.c,v
diff -p -u -r1.8 -r1.9
--- op-list.c 28 Jul 2004 14:32:39 -0000 1.8
+++ op-list.c 6 Nov 2007 23:08:33 -0000 1.9
@@ -130,7 +130,7 @@ void op_list_cleanup(op_list_p olp)
{
tmp_method_op = qlist_entry(iterator, struct method_op,
op_list_entry);
- dealloc_method_op(tmp_method_op);
+ bmi_dealloc_method_op(tmp_method_op);
}
free(olp);
olp = NULL;
Index: op-list.h
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/op-list.h,v
diff -p -u -r1.6 -r1.7
--- op-list.h 28 Jul 2004 14:32:39 -0000 1.6
+++ op-list.h 6 Nov 2007 23:08:33 -0000 1.7
@@ -26,7 +26,7 @@ typedef struct qlist_head *op_list_p;
*/
struct op_list_search_key
{
- method_addr_p method_addr;
+ bmi_method_addr_p method_addr;
int method_addr_yes;
bmi_msg_tag_t msg_tag;
int msg_tag_yes;
Index: reference-list.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/reference-list.c,v
diff -p -u -r1.12 -r1.13
--- reference-list.c 20 Aug 2007 01:39:57 -0000 1.12
+++ reference-list.c 6 Nov 2007 23:08:33 -0000 1.13
@@ -91,7 +91,7 @@ ref_st_p ref_list_search_addr(ref_list_p
* returns a pointer to the structure on success, NULL on failure.
*/
ref_st_p ref_list_search_method_addr(ref_list_p rlp,
- method_addr_p map)
+ bmi_method_addr_p map)
{
ref_list_p tmp_link = NULL;
ref_st_p tmp_entry = NULL;
@@ -231,8 +231,7 @@ void dealloc_ref_st(ref_st_p deadref)
if (deadref->method_addr)
{
- deadref->interface->BMI_meth_set_info(BMI_DROP_ADDR,
- deadref->method_addr);
+ deadref->interface->set_info(BMI_DROP_ADDR, deadref->method_addr);
}
id_gen_fast_unregister(deadref->bmi_addr);
Index: reference-list.h
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/io/bmi/reference-list.h,v
diff -p -u -r1.7 -r1.8
--- reference-list.h 28 Jul 2004 14:32:39 -0000 1.7
+++ reference-list.h 6 Nov 2007 23:08:33 -0000 1.8
@@ -29,7 +29,7 @@ struct ref_st
{
PVFS_BMI_addr_t bmi_addr; /* the identifier passed out of the BMI layer */
char *id_string; /* the id string that represents this reference */
- method_addr_p method_addr; /* address structure used by the method */
+ bmi_method_addr_p method_addr; /* address structure used by the method */
/* pointer to the appropriate method interface */
struct bmi_method_ops *interface;
@@ -53,7 +53,7 @@ ref_st_p ref_list_search_addr(ref_list_p
ref_st_p ref_list_rem(ref_list_p rlp,
PVFS_BMI_addr_t my_addr);
ref_st_p ref_list_search_method_addr(ref_list_p rlp,
- method_addr_p map);
+ bmi_method_addr_p map);
ref_st_p ref_list_search_str(ref_list_p rlp,
const char *idstring);
void ref_list_cleanup(ref_list_p rlp);
More information about the Pvfs2-cvs
mailing list