[dpdk-dev] [PATCH] net/i40e: fix segment num in reassemble process
When freeing up last mbuf, start->nb_segs should be decremented by one. See also ixgbe process. Signed-off-by: Chenghu Yao --- drivers/net/i40e/i40e_rxtx_vec_common.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/i40e/i40e_rxtx_vec_common.h b/drivers/net/i40e/i40e_rxtx_vec_common.h index 6cb5dce..990520f 100644 --- a/drivers/net/i40e/i40e_rxtx_vec_common.h +++ b/drivers/net/i40e/i40e_rxtx_vec_common.h @@ -71,6 +71,7 @@ /* free up last mbuf */ struct rte_mbuf *secondlast = start; + start->nb_segs--; while (secondlast->next != end) secondlast = secondlast->next; secondlast->data_len -= (rxq->crc_len - -- 1.8.3.1
[dpdk-dev] [PATCH] net/ixgbe/base: clear redundant macro define
In head file "ixgbe_mbx.h", macro define IXGBE_VF_API_NEGOTIATE and IXGBE_VF_GET_QUEUES appears two times with the same name,value, and notes. Version 2.0 VF requests can inherit the two macro defines in previous version 1.0 and 1.1. Otherwise, may be cause confusion. Signed-off-by: Chenghu Yao --- drivers/net/ixgbe/base/ixgbe_mbx.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ixgbe/base/ixgbe_mbx.h b/drivers/net/ixgbe/base/ixgbe_mbx.h index 7556a81..483e9b3 100644 --- a/drivers/net/ixgbe/base/ixgbe_mbx.h +++ b/drivers/net/ixgbe/base/ixgbe_mbx.h @@ -128,8 +128,6 @@ enum ixgbe_pfvf_api_rev { #define IXGBE_PF_CONTROL_MSG 0x0100 /* PF control message */ /* mailbox API, version 2.0 VF requests */ -#define IXGBE_VF_API_NEGOTIATE 0x08 /* negotiate API version */ -#define IXGBE_VF_GET_QUEUES0x09 /* get queue configuration */ #define IXGBE_VF_ENABLE_MACADDR0x0A /* enable MAC address */ #define IXGBE_VF_DISABLE_MACADDR 0x0B /* disable MAC address */ #define IXGBE_VF_GET_MACADDRS 0x0C /* get all configured MAC addrs */ -- 1.8.3.1
[dpdk-dev] [PATCH v2] net/ixgbe/base: clear redundant macro define
In head file "ixgbe_mbx.h", macro define IXGBE_VF_API_NEGOTIATE and IXGBE_VF_GET_QUEUES appear two times with the same name, value, and notes. Version 2.0 VF requests can inherit the two macro defines in previous version 1.0 and 1.1. Otherwise, maybe cause confusion. Signed-off-by: Chenghu Yao --- v2: * eliminate commit warning --- drivers/net/ixgbe/base/ixgbe_mbx.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ixgbe/base/ixgbe_mbx.h b/drivers/net/ixgbe/base/ixgbe_mbx.h index 7556a81..483e9b3 100644 --- a/drivers/net/ixgbe/base/ixgbe_mbx.h +++ b/drivers/net/ixgbe/base/ixgbe_mbx.h @@ -128,8 +128,6 @@ enum ixgbe_pfvf_api_rev { #define IXGBE_PF_CONTROL_MSG 0x0100 /* PF control message */ /* mailbox API, version 2.0 VF requests */ -#define IXGBE_VF_API_NEGOTIATE 0x08 /* negotiate API version */ -#define IXGBE_VF_GET_QUEUES0x09 /* get queue configuration */ #define IXGBE_VF_ENABLE_MACADDR0x0A /* enable MAC address */ #define IXGBE_VF_DISABLE_MACADDR 0x0B /* disable MAC address */ #define IXGBE_VF_GET_MACADDRS 0x0C /* get all configured MAC addrs */ -- 1.8.3.1
[dpdk-dev] [PATCH] net/fm10k/base: add a break statement
In function fm10k_mbx_create_reply(), the last case branch has no break statement. Signed-off-by: Chenghu Yao --- drivers/net/fm10k/base/fm10k_mbx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/fm10k/base/fm10k_mbx.c b/drivers/net/fm10k/base/fm10k_mbx.c index 2e70434..45d6ddb 100644 --- a/drivers/net/fm10k/base/fm10k_mbx.c +++ b/drivers/net/fm10k/base/fm10k_mbx.c @@ -1084,6 +1084,7 @@ STATIC s32 fm10k_mbx_create_reply(struct fm10k_hw *hw, case FM10K_STATE_CLOSED: /* generate new header based on data */ fm10k_mbx_create_disconnect_hdr(mbx); + break; default: break; } -- 1.8.3.1