examples/ipsec-secgw: make local variables static
in sp4.c and sp6.c there are few globals that used only locally. Define them as static ones. Cc: stable@dpdk.org Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com> Acked-by: Radu Nicolau <radu.nicolau@intel.com> Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
This commit is contained in:
parent
aed6eb10ed
commit
d92fc70e14
@ -44,7 +44,7 @@ enum {
|
|||||||
RTE_ACL_IPV4_NUM
|
RTE_ACL_IPV4_NUM
|
||||||
};
|
};
|
||||||
|
|
||||||
struct rte_acl_field_def ip4_defs[NUM_FIELDS_IPV4] = {
|
static struct rte_acl_field_def ip4_defs[NUM_FIELDS_IPV4] = {
|
||||||
{
|
{
|
||||||
.type = RTE_ACL_FIELD_TYPE_BITMASK,
|
.type = RTE_ACL_FIELD_TYPE_BITMASK,
|
||||||
.size = sizeof(uint8_t),
|
.size = sizeof(uint8_t),
|
||||||
@ -85,11 +85,11 @@ struct rte_acl_field_def ip4_defs[NUM_FIELDS_IPV4] = {
|
|||||||
|
|
||||||
RTE_ACL_RULE_DEF(acl4_rules, RTE_DIM(ip4_defs));
|
RTE_ACL_RULE_DEF(acl4_rules, RTE_DIM(ip4_defs));
|
||||||
|
|
||||||
struct acl4_rules acl4_rules_out[MAX_ACL_RULE_NUM];
|
static struct acl4_rules acl4_rules_out[MAX_ACL_RULE_NUM];
|
||||||
uint32_t nb_acl4_rules_out;
|
static uint32_t nb_acl4_rules_out;
|
||||||
|
|
||||||
struct acl4_rules acl4_rules_in[MAX_ACL_RULE_NUM];
|
static struct acl4_rules acl4_rules_in[MAX_ACL_RULE_NUM];
|
||||||
uint32_t nb_acl4_rules_in;
|
static uint32_t nb_acl4_rules_in;
|
||||||
|
|
||||||
void
|
void
|
||||||
parse_sp4_tokens(char **tokens, uint32_t n_tokens,
|
parse_sp4_tokens(char **tokens, uint32_t n_tokens,
|
||||||
|
@ -34,7 +34,7 @@ enum {
|
|||||||
|
|
||||||
#define IP6_ADDR_SIZE 16
|
#define IP6_ADDR_SIZE 16
|
||||||
|
|
||||||
struct rte_acl_field_def ip6_defs[IP6_NUM] = {
|
static struct rte_acl_field_def ip6_defs[IP6_NUM] = {
|
||||||
{
|
{
|
||||||
.type = RTE_ACL_FIELD_TYPE_BITMASK,
|
.type = RTE_ACL_FIELD_TYPE_BITMASK,
|
||||||
.size = sizeof(uint8_t),
|
.size = sizeof(uint8_t),
|
||||||
@ -116,11 +116,11 @@ struct rte_acl_field_def ip6_defs[IP6_NUM] = {
|
|||||||
|
|
||||||
RTE_ACL_RULE_DEF(acl6_rules, RTE_DIM(ip6_defs));
|
RTE_ACL_RULE_DEF(acl6_rules, RTE_DIM(ip6_defs));
|
||||||
|
|
||||||
struct acl6_rules acl6_rules_out[MAX_ACL_RULE_NUM];
|
static struct acl6_rules acl6_rules_out[MAX_ACL_RULE_NUM];
|
||||||
uint32_t nb_acl6_rules_out;
|
static uint32_t nb_acl6_rules_out;
|
||||||
|
|
||||||
struct acl6_rules acl6_rules_in[MAX_ACL_RULE_NUM];
|
static struct acl6_rules acl6_rules_in[MAX_ACL_RULE_NUM];
|
||||||
uint32_t nb_acl6_rules_in;
|
static uint32_t nb_acl6_rules_in;
|
||||||
|
|
||||||
void
|
void
|
||||||
parse_sp6_tokens(char **tokens, uint32_t n_tokens,
|
parse_sp6_tokens(char **tokens, uint32_t n_tokens,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user