From: Chas Williams <3chas3@gmail.com>
To: wangyunjian@huawei.com
Cc: dev@dpdk.org, stone.zhou@huawei.com
Subject: Re: [dpdk-dev] [PATCH] net/bonding: add support to match on 0x88A8 ethertype
Date: Thu, 16 Aug 2018 08:56:23 -0400 [thread overview]
Message-ID: <CAG2-Gkk8_2_ovpSx33WOdkPjcTHcaOXOA06LSrzb2gSVNtxrZw@mail.gmail.com> (raw)
In-Reply-To: <1533629446-5712-1-git-send-email-wangyunjian@huawei.com>
On Tue, Aug 7, 2018 at 4:11 AM wangyunjian <wangyunjian@huawei.com> wrote:
> From: Yunjian Wang <wangyunjian@huawei.com>
>
> We assume VLAN ethtertype is 0x8100 in get_vlan_offset() function,
> but it could be 0x88A8 if QinQ is supported.
>
> Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
>
Acked-by: Chas Williams <chas3@att.com>
> ---
> drivers/net/bonding/rte_eth_bond_pmd.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c
> b/drivers/net/bonding/rte_eth_bond_pmd.c
> index 58f7377..4417422 100644
> --- a/drivers/net/bonding/rte_eth_bond_pmd.c
> +++ b/drivers/net/bonding/rte_eth_bond_pmd.c
> @@ -37,7 +37,8 @@
> {
> size_t vlan_offset = 0;
>
> - if (rte_cpu_to_be_16(ETHER_TYPE_VLAN) == *proto) {
> + if (rte_cpu_to_be_16(ETHER_TYPE_VLAN) == *proto ||
> + rte_cpu_to_be_16(ETHER_TYPE_QINQ) == *proto) {
> struct vlan_hdr *vlan_hdr = (struct vlan_hdr *)(eth_hdr +
> 1);
>
> vlan_offset = sizeof(struct vlan_hdr);
> --
> 1.8.3.1
>
>
>
next prev parent reply other threads:[~2018-08-16 12:56 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-07 8:10 wangyunjian
2018-08-16 12:56 ` Chas Williams [this message]
2018-08-23 13:38 ` Ferruh Yigit
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAG2-Gkk8_2_ovpSx33WOdkPjcTHcaOXOA06LSrzb2gSVNtxrZw@mail.gmail.com \
--to=3chas3@gmail.com \
--cc=dev@dpdk.org \
--cc=stone.zhou@huawei.com \
--cc=wangyunjian@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).