RDS/IB: print string constants in more places
This prints the constant identifier for work completion status and rdma cm event types, like we already do for IB event types. A core string array helper is added that each string type uses. Signed-off-by: Zach Brown <zach.brown@oracle.com>
This commit is contained in:

zatwierdzone przez
Andy Grover

rodzic
4518071ac1
commit
59f740a6ae
@@ -40,6 +40,15 @@
|
||||
|
||||
#include "rds.h"
|
||||
|
||||
char *rds_str_array(char **array, size_t elements, size_t index)
|
||||
{
|
||||
if ((index < elements) && array[index])
|
||||
return array[index];
|
||||
else
|
||||
return "unknown";
|
||||
}
|
||||
EXPORT_SYMBOL(rds_str_array);
|
||||
|
||||
/* this is just used for stats gathering :/ */
|
||||
static DEFINE_SPINLOCK(rds_sock_lock);
|
||||
static unsigned long rds_sock_count;
|
||||
|
Reference in New Issue
Block a user