From: Vladimir Oltean <vladimir.oltean@nxp.com>
To: Lorenzo Bianconi <lorenzo@kernel.org>
Cc: netdev@vger.kernel.org, claudiu.manoil@nxp.com,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, lorenzo.bianconi@redhat.com
Subject: Re: [PATCH v3 net-next 0/2] enetc: unlock XDP_REDIRECT for XDP non-linear
Date: Mon, 12 Dec 2022 21:51:30 +0200 [thread overview]
Message-ID: <20221212195130.w2f5ykiwek4jrvqu@skbuf> (raw)
In-Reply-To: <cover.1670680119.git.lorenzo@kernel.org>
On Sat, Dec 10, 2022 at 02:53:09PM +0100, Lorenzo Bianconi wrote:
> Unlock XDP_REDIRECT for S/G XDP buffer and rely on XDP stack to properly
> take care of the frames.
> Remove xdp_redirect_sg counter and the related ethtool entry since it is
> no longer used.
>
> Changes since v2:
> - remove xdp_redirect_sg ethtool counter
> Changes since v1:
> - drop Fixes tag
> - unlock XDP_REDIRECT
> - populate missing XDP metadata
>
> Please note this patch is just compile tested
>
> Lorenzo Bianconi (2):
> net: ethernet: enetc: unlock XDP_REDIRECT for XDP non-linear buffers
> net: ethernet: enetc: get rid of xdp_redirect_sg counter
>
> drivers/net/ethernet/freescale/enetc/enetc.c | 25 ++++++++-----------
> drivers/net/ethernet/freescale/enetc/enetc.h | 1 -
> .../ethernet/freescale/enetc/enetc_ethtool.c | 2 --
> 3 files changed, 10 insertions(+), 18 deletions(-)
NACK.
xdp_redirect_cpu works, but OOM is still there if we XDP_REDIRECT to
another interface. That needs to be solved first.
root@debian:~# ./bpf/xdp_redirect eno0 eno2
[ 313.613983] fsl_enetc 0000:00:00.0 eno0: Link is Down
[ 313.699861] fsl_enetc 0000:00:00.0 eno0: PHY [0000:00:00.3:02] driver [Qualcomm Atheros AR8031/AR8033] (irq=POLL)
[ 313.735530] fsl_enetc 0000:00:00.0 eno0: configuring for inband/sgmii link mode
[ 313.754024] fsl_enetc 0000:00:00.2 eno2: Link is Down
[ 313.798565] fsl_enetc 0000:00:00.2 eno2: configuring for fixed/internal link mode
[ 313.806252] fsl_enetc 0000:00:00.2 eno2: Link is Up - 2.5Gbps/Full - flow control rx/tx
Redirecting from eno0 (ifindex 6; driver fsl_enetc) to eno2 (ifindex 7; driver fsl_enetc)
[ 315.791491] fsl_enetc 0000:00:00.0 eno0: Link is Up - 1Gbps/Full - flow control rx/tx
[ 315.799451] IPv6: ADDRCONF(NETDEV_CHANGE): eno0: link becomes ready
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 19806 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 81274 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 81275 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 81274 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 81274 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 75733 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 1562 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
eno0->eno2 0 rx/s 0 err,drop/s 0 xmit/s
^Z
[1]+ Stopped ./nxp_board_rootfs/bpf/xdp_redirect eno0 eno2
[ 347.901643] bash invoked oom-killer: gfp_mask=0x40cc0(GFP_KERNEL|__GFP_COMP), order=0, oom_score_adj=0
[ 347.911254] CPU: 1 PID: 412 Comm: bash Not tainted 6.1.0-rc8-07010-ga9b9500ffaac-dirty #754
[ 347.919676] Hardware name: LS1028A RDB Board (DT)
[ 347.924423] Call trace:
[ 347.926901] dump_backtrace.part.0+0xe8/0xf4
[ 347.931223] show_stack+0x20/0x50
[ 347.934579] dump_stack_lvl+0x8c/0xb8
[ 347.938288] dump_stack+0x18/0x34
[ 347.941644] dump_header+0x50/0x2ec
[ 347.945182] oom_kill_process+0x384/0x390
[ 347.949243] out_of_memory+0x218/0x670
[ 347.953039] __alloc_pages+0xf28/0x1080
[ 347.956919] cache_grow_begin+0x98/0x390
[ 347.960887] fallback_alloc+0x1f8/0x2bc
[ 347.964765] ____cache_alloc_node+0x17c/0x194
[ 347.969168] kmem_cache_alloc+0x214/0x2d0
[ 347.973222] getname_flags.part.0+0x3c/0x1a4
[ 347.977536] getname_flags+0x4c/0x7c
[ 347.981151] vfs_fstatat+0x4c/0x90
[ 347.984595] __do_sys_newfstatat+0x2c/0x70
[ 347.988737] __arm64_sys_newfstatat+0x28/0x34
[ 347.993140] invoke_syscall+0x50/0x120
[ 347.996939] el0_svc_common.constprop.0+0x68/0x124
next prev parent reply other threads:[~2022-12-12 19:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-10 13:53 [PATCH v3 net-next 0/2] enetc: unlock XDP_REDIRECT for XDP non-linear Lorenzo Bianconi
2022-12-10 13:53 ` [PATCH v3 net-next 1/2] net: ethernet: enetc: unlock XDP_REDIRECT for XDP non-linear buffers Lorenzo Bianconi
2022-12-10 13:53 ` [PATCH v3 net-next 2/2] net: ethernet: enetc: get rid of xdp_redirect_sg counter Lorenzo Bianconi
2022-12-12 19:51 ` Vladimir Oltean [this message]
2022-12-12 21:15 ` [PATCH v3 net-next 0/2] enetc: unlock XDP_REDIRECT for XDP non-linear Lorenzo Bianconi
2022-12-13 0:30 ` Vladimir Oltean
2022-12-13 8:50 ` Lorenzo Bianconi
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=20221212195130.w2f5ykiwek4jrvqu@skbuf \
--to=vladimir.oltean@nxp.com \
--cc=claudiu.manoil@nxp.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=lorenzo.bianconi@redhat.com \
--cc=lorenzo@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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