git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/txgbe: support VF promiscuous and allmulticast
[dpdk.git]
/
drivers
/
net
/
i40e
/
i40e_hash.c
diff --git
a/drivers/net/i40e/i40e_hash.c
b/drivers/net/i40e/i40e_hash.c
index
e07f806
..
b1cb24f
100644
(file)
--- a/
drivers/net/i40e/i40e_hash.c
+++ b/
drivers/net/i40e/i40e_hash.c
@@
-354,9
+354,10
@@
i40e_hash_get_pattern_type(const struct rte_flow_item pattern[],
}
/* Check the previous item allows this sub-item. */
}
/* Check the previous item allows this sub-item. */
- if (prev_item_type >= RTE_DIM(pattern_next_allow_items) ||
+ if (prev_item_type >= (enum rte_flow_item_type)
+ RTE_DIM(pattern_next_allow_items) ||
!(pattern_next_allow_items[prev_item_type] &
!(pattern_next_allow_items[prev_item_type] &
- BIT_ULL(pattern->type)))
+
BIT_ULL(pattern->type)))
goto not_sup;
/* For VLAN item, it does no matter about to pattern type
goto not_sup;
/* For VLAN item, it does no matter about to pattern type
@@
-372,7
+373,8
@@
i40e_hash_get_pattern_type(const struct rte_flow_item pattern[],
}
prev_item_type = last_item_type;
}
prev_item_type = last_item_type;
- assert(last_item_type < RTE_DIM(pattern_item_header));
+ assert(last_item_type < (enum rte_flow_item_type)
+ RTE_DIM(pattern_item_header));
item_hdr = pattern_item_header[last_item_type];
assert(item_hdr);
item_hdr = pattern_item_header[last_item_type];
assert(item_hdr);
@@
-676,10
+678,6
@@
i40e_hash_enable_pctype(struct i40e_hw *hw,
{
uint32_t reg, reg_val, mask;
{
uint32_t reg, reg_val, mask;
- /* For X722, get translated pctype in fd pctype register */
- if (hw->mac.type == I40E_MAC_X722)
- pctype = i40e_read_rx_ctl(hw, I40E_GLQF_FD_PCTYPES(pctype));
-
if (pctype < 32) {
mask = BIT(pctype);
reg = I40E_PFQF_HENA(0);
if (pctype < 32) {
mask = BIT(pctype);
reg = I40E_PFQF_HENA(0);
@@
-901,10
+899,12
@@
i40e_hash_parse_key(const struct rte_flow_action_rss *rss_act,
PMD_DRV_LOG(WARNING,
"RSS key length invalid, must be %u bytes, now set key to default",
(uint32_t)sizeof(rss_conf->key));
PMD_DRV_LOG(WARNING,
"RSS key length invalid, must be %u bytes, now set key to default",
(uint32_t)sizeof(rss_conf->key));
- key = (const uint8_t *)rss_key_default;
+
+ memcpy(rss_conf->key, rss_key_default, sizeof(rss_conf->key));
+ } else {
+ memcpy(rss_conf->key, key, sizeof(rss_conf->key));
}
}
- memcpy(rss_conf->key, key, sizeof(rss_conf->key));
rss_conf->conf.key = rss_conf->key;
rss_conf->conf.key_len = sizeof(rss_conf->key);
}
rss_conf->conf.key = rss_conf->key;
rss_conf->conf.key_len = sizeof(rss_conf->key);
}