iscsi: make globals static where possible

Change-Id: Ibd226babd873ad7cc10cf531abd90e3db24005b9
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
This commit is contained in:
Daniel Verkamp 2016-08-08 10:48:26 -07:00
parent b8e5fbe688
commit d96fe93bb8
2 changed files with 23 additions and 23 deletions

View File

@ -67,7 +67,7 @@
offsetof(struct spdk_iscsi_conn, portal));
#define MICROSECOND_TO_TSC(x) ((x) * rte_get_timer_hz()/1000000)
int64_t g_conn_idle_interval_in_tsc = -1;
static int64_t g_conn_idle_interval_in_tsc = -1;
#define DEFAULT_CONNECTIONS_PER_LCORE 4
#define SPDK_MAX_POLLERS_PER_CORE 4096
@ -75,11 +75,11 @@ static int g_connections_per_lcore = DEFAULT_CONNECTIONS_PER_LCORE;
static rte_atomic32_t g_num_connections[RTE_MAX_LCORE];
struct spdk_iscsi_conn *g_conns_array;
char g_shm_name[64];
static char g_shm_name[64];
pthread_mutex_t g_conns_mutex;
static pthread_mutex_t g_conns_mutex;
struct rte_timer g_shutdown_timer;
static struct rte_timer g_shutdown_timer;
static uint32_t spdk_iscsi_conn_allocate_reactor(uint64_t cpumask);
static void __add_idle_conn(spdk_event_t event);

View File

@ -136,13 +136,13 @@ spdk_iscsi_config_dump_section(FILE *fp)
/* Portal groups */
const char *portal_group_section = \
"\n"
"# Users must change the PortalGroup section(s) to match the IP addresses\n"
"# for their environment.\n"
"# PortalGroup sections define which TCP ports the iSCSI server will use\n"
"# to listen for incoming connections. These are also used to determine\n"
"# which targets are accessible over each portal group.\n";
static const char *portal_group_section = \
"\n"
"# Users must change the PortalGroup section(s) to match the IP addresses\n"
"# for their environment.\n"
"# PortalGroup sections define which TCP ports the iSCSI server will use\n"
"# to listen for incoming connections. These are also used to determine\n"
"# which targets are accessible over each portal group.\n";
#define PORTAL_GROUP_TMPL \
"[PortalGroup%d]\n" \
@ -173,13 +173,13 @@ spdk_iscsi_config_dump_portal_groups(FILE *fp)
}
/* Initiator Groups */
const char *initiator_group_section = \
"\n"
"# Users must change the InitiatorGroup section(s) to match the IP\n"
"# addresses and initiator configuration in their environment.\n"
"# Netmask can be used to specify a single IP address or a range of IP addresses\n"
"# Netmask 192.168.1.20 <== single IP address\n"
"# Netmask 192.168.1.0/24 <== IP range 192.168.1.*\n";
static const char *initiator_group_section = \
"\n"
"# Users must change the InitiatorGroup section(s) to match the IP\n"
"# addresses and initiator configuration in their environment.\n"
"# Netmask can be used to specify a single IP address or a range of IP addresses\n"
"# Netmask 192.168.1.20 <== single IP address\n"
"# Netmask 192.168.1.0/24 <== IP range 192.168.1.*\n";
#define INITIATOR_GROUP_TMPL \
"[InitiatorGroup%d]\n" \
@ -220,11 +220,11 @@ spdk_iscsi_config_dump_initiator_groups(FILE *fp)
}
/* Target nodes */
const char *target_nodes_section = \
"\n"
"# Users should change the TargetNode section(s) below to match the\n"
"# desired iSCSI target node configuration.\n"
"# TargetName, Mapping, LUN0 are minimum required\n";
static const char *target_nodes_section = \
"\n"
"# Users should change the TargetNode section(s) below to match the\n"
"# desired iSCSI target node configuration.\n"
"# TargetName, Mapping, LUN0 are minimum required\n";
#define TARGET_NODE_TMPL \
"[TargetNode%d]\n" \