netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: patchwork-bot+netdevbpf@kernel.org
To: Eric Dumazet <edumazet@google.com>
Cc: davem@davemloft.net, kuba@kernel.org, pabeni@redhat.com,
	sdf@fomichev.me, horms@kernel.org, netdev@vger.kernel.org,
	eric.dumazet@gmail.com,
	syzbot+0c7bfd8cf3aecec92708@syzkaller.appspotmail.com
Subject: Re: [PATCH net-next] bpf: fix a possible NULL deref in bpf_map_offload_map_alloc()
Date: Sat, 08 Mar 2025 03:40:44 +0000	[thread overview]
Message-ID: <174140524498.2565853.1890386523722103613.git-patchwork-notify@kernel.org> (raw)
In-Reply-To: <20250307074303.1497911-1-edumazet@google.com>

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Fri,  7 Mar 2025 07:43:02 +0000 you wrote:
> Call bpf_dev_offload_check() before netdev_lock_ops().
> 
> This is needed if attr->map_ifindex is not valid.
> 
> Oops: general protection fault, probably for non-canonical address 0xdffffc0000000197: 0000 [#1] PREEMPT SMP KASAN PTI
> KASAN: null-ptr-deref in range [0x0000000000000cb8-0x0000000000000cbf]
>  RIP: 0010:netdev_need_ops_lock include/linux/netdevice.h:2792 [inline]
>  RIP: 0010:netdev_lock_ops include/linux/netdevice.h:2803 [inline]
>  RIP: 0010:bpf_map_offload_map_alloc+0x19a/0x910 kernel/bpf/offload.c:533
> Call Trace:
>  <TASK>
>   map_create+0x946/0x11c0 kernel/bpf/syscall.c:1455
>   __sys_bpf+0x6d3/0x820 kernel/bpf/syscall.c:5777
>   __do_sys_bpf kernel/bpf/syscall.c:5902 [inline]
>   __se_sys_bpf kernel/bpf/syscall.c:5900 [inline]
>   __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5900
>   do_syscall_x64 arch/x86/entry/common.c:52 [inline]
>   do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
> 
> [...]

Here is the summary with links:
  - [net-next] bpf: fix a possible NULL deref in bpf_map_offload_map_alloc()
    https://git.kernel.org/netdev/net-next/c/0a5c8b2c8ccb

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



      parent reply	other threads:[~2025-03-08  3:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-07  7:43 [PATCH net-next] bpf: fix a possible NULL deref in bpf_map_offload_map_alloc() Eric Dumazet
2025-03-07 15:21 ` Stanislav Fomichev
2025-03-08  3:40 ` patchwork-bot+netdevbpf [this message]

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=174140524498.2565853.1890386523722103613.git-patchwork-notify@kernel.org \
    --to=patchwork-bot+netdevbpf@kernel.org \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=eric.dumazet@gmail.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=sdf@fomichev.me \
    --cc=syzbot+0c7bfd8cf3aecec92708@syzkaller.appspotmail.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).