Netdev Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Nikolay Aleksandrov <nikolay@nvidia.com>
To: Jussi Maki <joamaki@gmail.com>, netdev@vger.kernel.org
Cc: jtoppins@redhat.com
Subject: Re: [PATCH net-next] net, bonding: Disallow vlan+srcmac with XDP
Date: Thu, 12 Aug 2021 18:01:34 +0300	[thread overview]
Message-ID: <d741b3f0-2c42-274a-21af-5bb55a1d9a1b@nvidia.com> (raw)
In-Reply-To: <20210812145241.12449-1-joamaki@gmail.com>

On 12/08/2021 17:52, Jussi Maki wrote:
> The new vlan+srcmac xmit policy is not implementable with XDP since
> in many cases the 802.1Q payload is not present in the packet. This
> can be for example due to hardware offload or in the case of veth
> due to use of skbuffs internally.
> 
> This also fixes the NULL deref with the vlan+srcmac xmit policy
> reported by Jonathan Toppins by additionally checking the skb
> pointer.
> 
> Fixes: a815bde56b15 ("net, bonding: Refactor bond_xmit_hash for use with xdp_buff")
> Reported-by: Jonathan Toppins <jtoppins@redhat.com>
> Signed-off-by: Jussi Maki <joamaki@gmail.com>
> ---
>  drivers/net/bonding/bond_main.c | 18 +++++++++++-------
>  1 file changed, 11 insertions(+), 7 deletions(-)
> 

Hi Jussi,
Could you please share the null ptr deref trace?
I'm curious how we can get a null skb at that point.

Also how are the xdp and null ptr deref changes related ?

Thanks,
 Nik

  reply	other threads:[~2021-08-12 15:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-12 14:52 [PATCH net-next] net, bonding: Disallow vlan+srcmac with XDP Jussi Maki
2021-08-12 15:01 ` Nikolay Aleksandrov [this message]
2021-08-12 15:12   ` Jussi Maki
2021-08-12 15:21     ` Nikolay Aleksandrov
2021-08-13 19:40 ` Jonathan Toppins
2021-08-13 21:10 ` patchwork-bot+netdevbpf

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=d741b3f0-2c42-274a-21af-5bb55a1d9a1b@nvidia.com \
    --to=nikolay@nvidia.com \
    --cc=joamaki@gmail.com \
    --cc=jtoppins@redhat.com \
    --cc=netdev@vger.kernel.org \
    /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).