lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAL+tcoBZD7M04svcbadQSdWupQCHvt3i0q21YgVjZ6azkrwFLg@mail.gmail.com>
Date:   Wed, 8 Feb 2023 10:03:19 +0800
From:   Jason Xing <kerneljasonxing@...il.com>
To:     Tony Nguyen <anthony.l.nguyen@...el.com>
Cc:     jesse.brandeburg@...el.com, davem@...emloft.net,
        edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com,
        richardcochran@...il.com, ast@...nel.org, daniel@...earbox.net,
        hawk@...nel.org, john.fastabend@...il.com,
        alexandr.lobakin@...el.com, maciej.fijalkowski@...el.com,
        intel-wired-lan@...ts.osuosl.org, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org, bpf@...r.kernel.org,
        Jason Xing <kernelxing@...cent.com>
Subject: Re: [PATCH net 2/3] i40e: add double of VLAN header when computing
 the max MTU

On Wed, Feb 8, 2023 at 3:03 AM Tony Nguyen <anthony.l.nguyen@...el.com> wrote:
>
>
>
> On 2/4/2023 5:35 AM, Jason Xing wrote:
> > From: Jason Xing <kernelxing@...cent.com>
> >
> > Include the second VLAN HLEN into account when computing the maximum
> > MTU size as other drivers do.
> >
> > Fixes: 0c8493d90b6b ("i40e: add XDP support for pass and drop actions")
> > Signed-off-by: Jason Xing <kernelxing@...cent.com>
> > ---
> >   drivers/net/ethernet/intel/i40e/i40e.h      | 2 ++
> >   drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +-
> >   2 files changed, 3 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/net/ethernet/intel/i40e/i40e.h b/drivers/net/ethernet/intel/i40e/i40e.h
> > index 60e351665c70..e03853d3c706 100644
> > --- a/drivers/net/ethernet/intel/i40e/i40e.h
> > +++ b/drivers/net/ethernet/intel/i40e/i40e.h
> > @@ -107,6 +107,8 @@
> >   #define I40E_BW_MBPS_DIVISOR                125000 /* rate / (1000000 / 8) Mbps */
> >   #define I40E_MAX_BW_INACTIVE_ACCUM  4 /* accumulate 4 credits max */
> >
> > +#define I40E_PACKET_HDR_PAD (ETH_HLEN + ETH_FCS_LEN + (VLAN_HLEN * 2))
>

> This already exists:
> https://elixir.bootlin.com/linux/latest/source/drivers/net/ethernet/intel/i40e/i40e_txrx.h#L112

Thanks for pointing out the duplication definition. I'll drop this in
the i40e.h file.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ