[dpdk-dev] [PATCH 3/3] fm10k: update VLAN offload features

He, Shaopeng shaopeng.he at intel.com
Wed Jun 10 08:03:00 CEST 2015


> -----Original Message-----
> From: Qiu, Michael
> Sent: Tuesday, June 09, 2015 11:41 PM
> To: Chen, Jing D; He, Shaopeng; dev at dpdk.org
> Subject: Re: [PATCH 3/3] fm10k: update VLAN offload features
> 
> On 2015/6/9 11:27, Chen, Jing D wrote:
> > Hi,
> >
> >
> >> -----Original Message-----
> >> From: He, Shaopeng
> >> Sent: Tuesday, June 02, 2015 10:59 AM
> >> To: dev at dpdk.org
> >> Cc: Chen, Jing D; Qiu, Michael; He, Shaopeng
> >> Subject: [PATCH 3/3] fm10k: update VLAN offload features
> >>
> >> Fm10k PF/VF does not support QinQ; VLAN strip and filter are always
> >> on for PF/VF ports.
> >>
> >> Signed-off-by: Shaopeng He <shaopeng.he at intel.com>
> >> ---
> >>  drivers/net/fm10k/fm10k_ethdev.c | 22 ++++++++++++++++++++++
> >>  1 file changed, 22 insertions(+)
> >>
> >> diff --git a/drivers/net/fm10k/fm10k_ethdev.c
> >> b/drivers/net/fm10k/fm10k_ethdev.c
> >> index 4f23bf1..9b198a7 100644
> >> --- a/drivers/net/fm10k/fm10k_ethdev.c
> >> +++ b/drivers/net/fm10k/fm10k_ethdev.c
> >> @@ -884,6 +884,27 @@ fm10k_vlan_filter_set(struct rte_eth_dev *dev,
> >> uint16_t vlan_id, int on)
> >>  		return (-EIO);
> >>  }
> >>
> >> +static void
> >> +fm10k_vlan_offload_set(__rte_unused struct rte_eth_dev *dev, int
> >> +mask) {
> >> +	if (mask & ETH_VLAN_STRIP_MASK) {
> >> +		if (!dev->data->dev_conf.rxmode.hw_vlan_strip)
> >> +			PMD_INIT_LOG(ERR, "VLAN stripping is "
> >> +					"always on in fm10k");
> >> +	}
> >> +
> >> +	if (mask & ETH_VLAN_EXTEND_MASK) {
> >> +		if (dev->data->dev_conf.rxmode.hw_vlan_extend)
> >> +			PMD_INIT_LOG(ERR, "VLAN QinQ is not "
> >> +					"supported in fm10k");
> >> +	}
> >> +
> >> +	if (mask & ETH_VLAN_FILTER_MASK) {
> >> +		if (!dev->data->dev_conf.rxmode.hw_vlan_filter)
> >> +			PMD_INIT_LOG(ERR, "VLAN filter is always on in
> >> fm10k");
> >> +	}
> >> +}
> >> +
> > Update fm10k_dev_infos_get() to configure above options to expected
> values?
> 
> Could it be better to add CRC strip options to expected values by convenient?
Thanks for the comments; but this patch is for the VLAN offload, may not be good
place to fix other bugs. By the way, current struct rte_eth_dev_info 
which fm10k_dev_infos_get() returns does not have 
any setting for CRC strip options (please correct me if I am wrong).



More information about the dev mailing list