[...]
> > + TP_ARGS(map_id, processed, sched, xdp_stats),
> >
> > TP_STRUCT__entry(
> > __field(int, map_id)
> > __field(u32, act)
> > __field(int, cpu)
> > - __field(unsigned int, drops)
> > __field(unsigned int, processed)
>
> So,
discarded packets,
remove drop counter from xdp_cpumap_kthread tracepoint and update related
xdp samples.
Signed-off-by: Lorenzo Bianconi
---
Changes since v2:
- remove drop counter and update related xdp samples
- rebased on top of bpf-next
Changes since v1:
- fixed comment
- rebased on top of bpf
> On Sun, Apr 18, 2021 at 6:18 PM Jesper Dangaard Brouer
> wrote:
> >
> > On Fri, 16 Apr 2021 16:27:18 +0200
> > Magnus Karlsson wrote:
> >
> > > On Thu, Apr 8, 2021 at 2:51 PM Lorenzo Bianconi
> > > wrote:
> > > >
> > > &
gt; > bpd: add multi-buffer support to xdp copy helpers
> > bpf: add new frame_length field to the XDP ctx
> > bpf: update xdp_adjust_tail selftest to include multi-buffer
> >
> > Lorenzo Bianconi (10):
> > xdp: introduce mb in xdp_buff/xdp_frame
> > xdp: a
> On 4/15/21 9:03 AM, Lorenzo Bianconi wrote:
> >> On 4/15/21 8:05 AM, Daniel Borkmann wrote:
> >
> > [...]
> >>>> &stats);
> >>>
> >>> Given we stop counting drops with the netif_receive_skb_list(), we
> >>> should t
> On 4/15/21 8:05 AM, Daniel Borkmann wrote:
[...]
> >> &stats);
> >
> > Given we stop counting drops with the netif_receive_skb_list(), we
> > should then
> > also remove drops from trace_xdp_cpumap_kthread(), imho, as otherwise it
> > is rather
> > misleading (as in: drops actually happening, b
[...]
> @@ -8683,7 +8676,10 @@ static int igb_clean_rx_irq(struct igb_q_vector
> *q_vector, const int budget)
> while (likely(total_packets < budget)) {
> union e1000_adv_rx_desc *rx_desc;
> struct igb_rx_buffer *rx_buffer;
> + ktime_t timestamp = 0;
>
cpumap entry and then to the networking stack.
UDP frames are generated using pkt_gen.
$xdp_redirect_cpu --cpu --progname xdp_cpu_map0 --dev
bpf-next: ~2.2Mpps
bpf-next + cpumap skb-list: ~3.15Mpps
Signed-off-by: Lorenzo Bianconi
---
Changes since v1:
- fixed comment
- rebased on top of bpf-next
> Lorenzo Bianconi wrote:
[...]
>
> I just read the commit messages for v8 so far. But, I'm still wondering how
> to handle use cases where we want to put extra bytes at the end of the
> packet, or really anywhere in the general case. We can extend tail with above
>
> On Thu, Apr 08, 2021 at 02:51:01PM +0200, Lorenzo Bianconi wrote:
> > From: Eelco Chaudron
> >
> > This patch adds support for multi-buffer for the following helpers:
> > - bpf_xdp_output()
> > - bpf_perf_event_output()
> >
> > Signed-off-b
> On Thu, Apr 08, 2021 at 10:15:47PM +0300, Vladimir Oltean wrote:
> > > + if (unlikely(offset > ((int)(xdp->data_end - xdp->data) +
> > > +xdp_sinfo->data_length -
> > > +ETH_HLEN)))
> >
> > Also: should we have some sort of
> On Thu, Apr 08, 2021 at 02:50:57PM +0200, Lorenzo Bianconi wrote:
> > Introduce the capability to map non-linear xdp buffer running
> > mvneta_xdp_submit_frame() for XDP_TX and XDP_REDIRECT
> >
> > Signed-off-by: Lorenzo Bianconi
> > ---
> > dri
> On Thu, Apr 08, 2021 at 02:50:56PM +0200, Lorenzo Bianconi wrote:
> > Take into account if the received xdp_buff/xdp_frame is non-linear
> > recycling/returning the frame memory to the allocator or into
> > xdp_frame_bulk.
> > Introduce xdp_return_num_frags_from_buff
> On Thu, Apr 08, 2021 at 02:50:55PM +0200, Lorenzo Bianconi wrote:
> > Update multi-buffer bit (mb) in xdp_buff to notify XDP/eBPF layer and
> > XDP remote drivers if this is a "non-linear" XDP buffer. Access
> > xdp_shared_info only if xdp_buff mb is set.
> >
> On Thu, Apr 08, 2021 at 02:50:53PM +0200, Lorenzo Bianconi wrote:
> > Introduce multi-buffer bit (mb) in xdp_frame/xdp_buffer data structure
> > in order to specify if this is a linear buffer (mb = 0) or a multi-buffer
> > frame (mb = 1). In the latter case the shared_info a
> Hi Lorenzo,
>
> On Thu, Apr 08, 2021 at 02:50:54PM +0200, Lorenzo Bianconi wrote:
> > Introduce xdp_shared_info data structure to contain info about
> > "non-linear" xdp frame. xdp_shared_info will alias skb_shared_info
> > allowing to keep mos
From: Eelco Chaudron
This change adds test cases for the multi-buffer scenarios when shrinking
and growing.
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
.../bpf/prog_tests/xdp_adjust_tail.c | 105 ++
.../bpf/progs/test_xdp_adjust_tail_grow.c
introduce xdp_shared_info pointer in bpf_test_finish signature in order
to copy back paged data from a xdp multi-buff frame to userspace buffer
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 48 ++
1 file changed, 40 insertions(+), 8
Introduce the capability to allocate a xdp multi-buff in
bpf_prog_test_run_xdp routine. This is a preliminary patch to introduce
the selftests for new xdp multi-buff ebpf helpers
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 52 +++---
1 file
Rely on data_size_in in bpf_test_init routine signature. This is a
preliminary patch to introduce xdp multi-buff selftest
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 13 +++--
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/net/bpf/test_run.c b/net/bpf
From: Eelco Chaudron
This patch adds support for multi-buffer for the following helpers:
- bpf_xdp_output()
- bpf_perf_event_output()
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
net/core/filter.c | 63 -
.../selftests/bpf
< ctx->frame_length) {
/* Fragements exists. /*
}
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
include/linux/filter.h | 7 +++
include/net/xdp.h | 15 +++
include/uapi/linux/bpf.h | 1 +
net/core/filter.c | 8 ++
From: Eelco Chaudron
This change adds support for tail growing and shrinking for XDP multi-buff.
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 5
net/core/filter.c | 63 +++
2 files changed, 68
Introduce xdp multi-buff support to
__xdp_build_skb_from_frame/xdp_build_skb_from_fram utility
routines.
Signed-off-by: Lorenzo Bianconi
---
net/core/xdp.c | 26 ++
1 file changed, 26 insertions(+)
diff --git a/net/core/xdp.c b/net/core/xdp.c
index 430f516259d9
Enable the capability to receive jumbo frames even if the interface is
running in XDP mode
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 10 --
1 file changed, 10 deletions(-)
diff --git a/drivers/net/ethernet/marvell/mvneta.c
b/drivers/net/ethernet
Introduce xdp_shared_info data structure to contain info about
"non-linear" xdp frame. xdp_shared_info will alias skb_shared_info
allowing to keep most of the frags in the same cache-line.
Introduce some xdp_shared_info helpers aligned to skb_frag* ones
Signed-off-by: Lorenz
Update multi-buffer bit (mb) in xdp_buff to notify XDP/eBPF layer and
XDP remote drivers if this is a "non-linear" XDP buffer. Access
xdp_shared_info only if xdp_buff mb is set.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 26
Take into account if the received xdp_buff/xdp_frame is non-linear
recycling/returning the frame memory to the allocator or into
xdp_frame_bulk.
Introduce xdp_return_num_frags_from_buff to return a given number of
fragments from a xdp multi-buff starting from the tail.
Signed-off-by: Lorenzo
Introduce the capability to map non-linear xdp buffer running
mvneta_xdp_submit_frame() for XDP_TX and XDP_REDIRECT
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 94 +--
1 file changed, 58 insertions(+), 36 deletions(-)
diff --git a/drivers
.
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/include/net/xdp.h b/include/net/xdp.h
index a5bc214a49d9..842580a61563 100644
--- a/include/net/xdp.h
+++ b/include/net/xdp.h
@@ -73,7 +73,10 @@ struct xdp_buff
dd-XDP-support-to-a-NIC-driver
(XDPmulti-buffers section)
Eelco Chaudron (4):
bpf: add multi-buff support to the bpf_xdp_adjust_tail() API
bpd: add multi-buffer support to xdp copy helpers
bpf: add new frame_length field to the XDP ctx
bpf: update xdp_adjust_tail selftest to include multi-buffer
> On Thu, Apr 1, 2021 at 9:49 AM Lorenzo Bianconi wrote:
> >
> > > On Thu, Apr 1, 2021 at 1:57 AM Lorenzo Bianconi
> > > wrote:
> > > >
> >
> > [...]
> >
> > > > - /* Inject into network stac
> On Thu, Apr 1, 2021 at 1:57 AM Lorenzo Bianconi wrote:
> >
[...]
> > - /* Inject into network stack */
> > - ret = netif_receive_skb_core(skb);
> > - if (ret == NET_RX_DROP)
> > -
cpumap entry and then to the networking stack.
UDP frames are generated using pkt_gen.
$xdp_redirect_cpu --cpu --progname xdp_cpu_map0 --dev
bpf-next: ~2.2Mpps
bpf-next + cpumap skb-list: ~3.15Mpps
Signed-off-by: Lorenzo Bianconi
---
kernel/bpf/cpumap.c | 9 -
1 file changed, 4
[...]
> > diff --git a/drivers/net/ethernet/marvell/mvneta.c
> > b/drivers/net/ethernet/marvell/mvneta.c
> > index a635cf84608a..8b3250394703 100644
> > --- a/drivers/net/ethernet/marvell/mvneta.c
> > +++ b/drivers/net/ethernet/marvell/mvneta.c
> > @@ -2332,7 +2332,7 @@ mvneta_swbm_build_skb(struc
introduce xdp_shared_info pointer in bpf_test_finish signature in order
to copy back paged data from a xdp multi-buff frame to userspace buffer
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 48 ++
1 file changed, 40 insertions(+), 8
From: Eelco Chaudron
This change adds test cases for the multi-buffer scenarios when shrinking
and growing.
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
.../bpf/prog_tests/xdp_adjust_tail.c | 105 ++
.../bpf/progs/test_xdp_adjust_tail_grow.c
Introduce the capability to allocate a xdp multi-buff in
bpf_prog_test_run_xdp routine. This is a preliminary patch to introduce
the selftests for new xdp multi-buff ebpf helpers
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 52 +++---
1 file
< ctx->frame_length) {
/* Fragements exists. /*
}
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
include/linux/filter.h | 7 +++
include/net/xdp.h | 12
include/uapi/linux/bpf.h | 1 +
net/core/filter.c | 8 ++
Rely on data_size_in in bpf_test_init routine signature. This is a
preliminary patch to introduce xdp multi-buff selftest
Signed-off-by: Lorenzo Bianconi
---
net/bpf/test_run.c | 13 +++--
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/net/bpf/test_run.c b/net/bpf
From: Eelco Chaudron
This patch adds support for multi-buffer for the following helpers:
- bpf_xdp_output()
- bpf_perf_event_output()
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
net/core/filter.c | 60 -
.../selftests/bpf
From: Eelco Chaudron
This change adds support for tail growing and shrinking for XDP multi-buff.
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 5
net/core/filter.c | 63 +++
2 files changed, 68
Enable the capability to receive jumbo frames even if the interface is
running in XDP mode
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 10 --
1 file changed, 10 deletions(-)
diff --git a/drivers/net/ethernet/marvell/mvneta.c
b/drivers/net/ethernet
Introduce xdp multi-buff support to
__xdp_build_skb_from_frame/xdp_build_skb_from_fram utility
routines.
Signed-off-by: Lorenzo Bianconi
---
net/core/xdp.c | 26 ++
1 file changed, 26 insertions(+)
diff --git a/net/core/xdp.c b/net/core/xdp.c
index 430f516259d9
Update multi-buffer bit (mb) in xdp_buff to notify XDP/eBPF layer and
XDP remote drivers if this is a "non-linear" XDP buffer. Access
xdp_shared_info only if xdp_buff mb is set.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 26
Take into account if the received xdp_buff/xdp_frame is non-linear
recycling/returning the frame memory to the allocator or into
xdp_frame_bulk.
Introduce xdp_return_num_frags_from_buff to return a given number of
fragments from a xdp multi-buff starting from the tail.
Signed-off-by: Lorenzo
Introduce the capability to map non-linear xdp buffer running
mvneta_xdp_submit_frame() for XDP_TX and XDP_REDIRECT
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 91 ---
1 file changed, 55 insertions(+), 36 deletions(-)
diff --git a/drivers
Introduce xdp_shared_info data structure to contain info about
"non-linear" xdp frame. xdp_shared_info will alias skb_shared_info
allowing to keep most of the frags in the same cache-line.
Introduce some xdp_shared_info helpers aligned to skb_frag* ones
Signed-off-by: Lorenz
.
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/include/net/xdp.h b/include/net/xdp.h
index a5bc214a49d9..b57ff2c81e7c 100644
--- a/include/net/xdp.h
+++ b/include/net/xdp.h
@@ -73,7 +73,8 @@ struct xdp_buff
ail() API
bpd: add multi-buffer support to xdp copy helpers
bpf: add new frame_length field to the XDP ctx
bpf: update xdp_adjust_tail selftest to include multi-buffer
Lorenzo Bianconi (10):
xdp: introduce mb in xdp_buff/xdp_frame
xdp: add xdp_shared_info data structure
net: mvneta: up
For wireless devices (e.g. mt76 driver) multiple net_devices belongs to
the same wireless phy and the napi object is registered in a dummy
netdevice related to the wireless phy.
Export dev_set_threaded in order to be reused in device drivers enabling
threaded NAPI.
Signed-off-by: Lorenzo Bianconi
new APIs:
- veth
- virtio-net
- mvneta
- mvpp2
- socionext
- amazon ena
- bnxt
- freescale (dpaa2, dpaa)
- xen-frontend
- qede
- ice
- igb
- ixgbe
- i40e
- mlx5
- ti (cpsw, cpsw-new)
- tun
- sfc
Acked-by: Edward Cree
Reviewed-by: Ioana Ciornei
Reviewed-by: Ilias Apalodimas
Signed-off-by: Lorenzo
> On Mon, 1 Mar 2021 13:23:06 +0200
> Shay Agroskin wrote:
>
> > Jesper Dangaard Brouer writes:
> >
> > > On Sun, 28 Feb 2021 23:27:25 +0100
> > > Lorenzo Bianconi wrote:
> > >
> > >> > > drops = bq->count - sen
>
> Lorenzo Bianconi writes:
>
> > ...
> > diff --git a/drivers/net/ethernet/amazon/ena/ena_netdev.c
> > b/drivers/net/ethernet/amazon/ena/ena_netdev.c
> > index 102f2c91fdb8..7ad0557dedbd 100644
> > --- a/drivers/net/ethernet/amazon/ena/ena_netdev.c
&g
new APIs:
- veth
- virtio-net
- mvneta
- mvpp2
- socionext
- amazon ena
- bnxt
- freescale (dpaa2, dpaa)
- xen-frontend
- qede
- ice
- igb
- ixgbe
- i40e
- mlx5
- ti (cpsw, cpsw-new)
- tun
- sfc
Acked-by: Edward Cree
Signed-off-by: Lorenzo Bianconi
---
More details about the new ndo_xdp_xmit design
> On 2/17/21 2:56 PM, Lorenzo Bianconi wrote:
> > We want to change the current ndo_xdp_xmit drop semantics because
> > it will allow us to implement better queue overflow handling.
> > This is working towards the larger goal of a XDP TX queue-hook.
> > Move XDP_REDIRE
/xdp-project/blob/master/areas/core/redesign01_ndo_xdp_xmit.org
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/amazon/ena/ena_netdev.c | 18 ++---
drivers/net/ethernet/broadcom/bnxt/bnxt_xdp.c | 20 ++
.../net/ethernet/freescale/dpaa/dpaa_eth.c| 12
> Hi,
>
Hi Colin,
a fix for this issue has been already posted upstream:
https://patchwork.kernel.org/project/linux-wireless/patch/857ff74f736d4e593f5ad602cee7ac67ebfca5ca.1612867656.git.lore...@kernel.org/
Regards,
Lorenzo
> Static analysis with Coverity on linux-next has found an issue with
/redesign01_ndo_xdp_xmit.org
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/amazon/ena/ena_netdev.c | 18 ++---
drivers/net/ethernet/broadcom/bnxt/bnxt_xdp.c | 20 ++
.../net/ethernet/freescale/dpaa/dpaa_eth.c| 12 -
.../net/ethernet/freescale/dpaa2/dpaa2-eth.c | 2
On Feb 08, Kalle Valo wrote:
> Lorenzo Bianconi writes:
>
> >> So what's the plan? Is there going to be a followup patch? And should
> >> that also go to v5.11 or can it wait v5.12?
> >>
> >> --
> >> https://patchwork
>
> >
>
> [...]
>
> >
> > So what's the plan? Is there going to be a followup patch? And should
> > that also go to v5.11 or can it wait v5.12?
> >
> > --
> > https://patchwork.kernel.org/project/linux-wireless/list/
> >
> > https://wireless.wiki.kernel.org/en/developers/documentation/submittingpat
>
[...]
>
> So what's the plan? Is there going to be a followup patch? And should
> that also go to v5.11 or can it wait v5.12?
>
> --
> https://patchwork.kernel.org/project/linux-wireless/list/
>
> https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
>
Hi Kalle,
I wil
> On Fri, 5 Feb 2021 16:34:34 + (UTC) Kalle Valo wrote:
> > Hi,
> >
> > here's a pull request to net tree, more info below. Please let me know if
> > there
> > are any problems.
>
> Pulled, thanks! One thing to confirm tho..
>
> > ath9k
> >
> > * fix build regression related to LEDS_CLASS
interface (XDP_TX). This patch allows the
system administrator to very the device is receiving data correctly.
Signed-off-by: Lorenzo Bianconi
---
- this patch is compile-only tested
---
drivers/net/ethernet/ti/cpsw.c | 4 +---
drivers/net/ethernet/ti/cpsw_new.c | 4 +---
drivers/net
> Hi Lorenzo,
Hi Daniel,
sorry for the delay.
>
> On 1/19/21 9:20 PM, Lorenzo Bianconi wrote:
> > This series introduce XDP multi-buffer support. The mvneta driver is
> > the first to support these new "non-linear" xdp_{buff,frame}. Reviewers
> > please
veth0 --> (remote-ns) veth1 --> XDP_PASS
XDP_REDIRECT: xdp_redirect_map bpf sample
XDP_PASS: xdp_rxq_info bpf sample
traffic generator: pkt_gen sending udp traffic on a remote device
bpf-next master: ~3.64Mpps
bpf-next + skb bulking allocation: ~3.79Mpps
Signed-off-by: Lorenzo Bianconi
On Jan 29, Lorenzo Bianconi wrote:
> On Jan 29, Jesper Dangaard Brouer wrote:
> > On Fri, 29 Jan 2021 17:02:16 +0100
> > Jesper Dangaard Brouer wrote:
> >
> > > > + for (i = 0; i < n_skb; i++) {
> > > > + struct sk_buff *skb = s
On Jan 29, Jesper Dangaard Brouer wrote:
> On Fri, 29 Jan 2021 17:02:16 +0100
> Jesper Dangaard Brouer wrote:
>
> > > + for (i = 0; i < n_skb; i++) {
> > > + struct sk_buff *skb = skbs[i];
> > > +
> > > + memset(skb, 0, offsetof(struct sk_buff, tail));
> >
> > It is very subtle
> On 2021/01/29 4:41, Lorenzo Bianconi wrote:
> > Split ndo_xdp_xmit and ndo_start_xmit use cases in veth_xdp_rcv routine
> > in order to alloc skbs in bulk for XDP_PASS verdict.
> > Introduce xdp_alloc_skb_bulk utility routine to alloc skb bulk list.
> > The proposed
> On 2021/01/27 3:41, Lorenzo Bianconi wrote:
> > Introduce bulking support for XDP_PASS verdict forwarding skbs to
> > the networking stack
> >
> > Signed-off-by: Lorenzo Bianconi
> > ---
> > drivers/net/veth.c | 43 ++---
ple
traffic generator: pkt_gen sending udp traffic on a remote device
bpf-next master: ~3.64Mpps
bpf-next + skb bulking allocation: ~3.75Mpps
Lorenzo Bianconi (3):
net: veth: introduce bulking for XDP_PASS
net: xdp: move XDP_BATCH_SIZE in common header
net: veth: alloc skb in bulk for
Move CPUMAP_BATCH macro in xdp common header and rename it to
XDP_BATCH_SIZE in order to be reused in veth driver
Signed-off-by: Lorenzo Bianconi
---
drivers/net/veth.c | 2 +-
include/net/xdp.h | 1 +
kernel/bpf/cpumap.c | 13 +
3 files changed, 7 insertions(+), 9 deletions
Split ndo_xdp_xmit and ndo_start_xmit use cases in veth_xdp_rcv routine
in order to alloc skbs in bulk for XDP_PASS verdict.
Introduce xdp_alloc_skb_bulk utility routine to alloc skb bulk list.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/veth.c | 96
Introduce bulking support for XDP_PASS verdict forwarding skbs to
the networking stack
Signed-off-by: Lorenzo Bianconi
---
drivers/net/veth.c | 43 ++-
1 file changed, 26 insertions(+), 17 deletions(-)
diff --git a/drivers/net/veth.c b/drivers/net/veth.c
section)
Eelco Chaudron (1):
bpf: add multi-buff support to the bpf_xdp_adjust_tail() API
Lorenzo Bianconi (7):
xdp: introduce mb in xdp_buff/xdp_frame
xdp: add xdp_shared_info data structure
net: mvneta: update mb bit before passing the xdp buffer to eBPF layer
xdp: add multi-buff support
.
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/include/net/xdp.h b/include/net/xdp.h
index c4bfdc9a8b79..945767813fdd 100644
--- a/include/net/xdp.h
+++ b/include/net/xdp.h
@@ -73,7 +73,8 @@ struct xdp_buff
Introduce xdp multi-buff support to
__xdp_build_skb_from_frame/xdp_build_skb_from_fram utility
routines.
Signed-off-by: Lorenzo Bianconi
---
net/core/xdp.c | 26 ++
1 file changed, 26 insertions(+)
diff --git a/net/core/xdp.c b/net/core/xdp.c
index af9b9c1194fc
Update multi-buffer bit (mb) in xdp_buff to notify XDP/eBPF layer and
XDP remote drivers if this is a "non-linear" XDP buffer. Access
xdp_shared_info only if xdp_buff mb is set.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 26
Enable the capability to receive jumbo frames even if the interface is
running in XDP mode
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 10 --
1 file changed, 10 deletions(-)
diff --git a/drivers/net/ethernet/marvell/mvneta.c
b/drivers/net/ethernet
Take into account if the received xdp_buff/xdp_frame is non-linear
recycling/returning the frame memory to the allocator or into
xdp_frame_bulk.
Introduce xdp_return_num_frags_from_buff to return a given number of
fragments from a xdp multi-buff starting from the tail.
Signed-off-by: Lorenzo
From: Eelco Chaudron
This change adds support for tail growing and shrinking for XDP multi-buff.
Signed-off-by: Eelco Chaudron
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 5
net/core/filter.c | 63 +++
2 files changed, 68
Introduce the capability to map non-linear xdp buffer running
mvneta_xdp_submit_frame() for XDP_TX and XDP_REDIRECT
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/marvell/mvneta.c | 94 ---
1 file changed, 56 insertions(+), 38 deletions(-)
diff --git a/drivers
Introduce xdp_shared_info data structure to contain info about
"non-linear" xdp frame. xdp_shared_info will alias skb_shared_info
allowing to keep most of the frags in the same cache-line.
Introduce some xdp_shared_info helpers aligned to skb_frag* ones
Signed-off-by: Lorenz
missing metadata support in veth_xdp_rcv_one().
Reviewed-by: Toshiaki Makita
Acked-by: Jesper Dangaard Brouer
Signed-off-by: Lorenzo Bianconi
---
drivers/net/veth.c | 18 +++---
include/net/xdp.h | 2 ++
net/core/xdp.c | 15 +++
3 files changed, 20 insertions
since v1:
- fix a checkpatch warning
- improve commit log in patch 2/2
Lorenzo Bianconi (2):
net: xdp: introduce __xdp_build_skb_from_frame utility routine
net: xdp: introduce xdp_build_skb_from_frame utility routine
drivers/net/veth.c | 18 +++---
include/net/xdp.h | 5
Introduce __xdp_build_skb_from_frame utility routine to build
the skb from xdp_frame. Rely on __xdp_build_skb_from_frame in
cpumap code.
Acked-by: Jesper Dangaard Brouer
Signed-off-by: Lorenzo Bianconi
---
include/net/xdp.h | 3 +++
kernel/bpf/cpumap.c | 46
> On 1/12/21 5:08 PM, Lorenzo Bianconi wrote:
> > > Introduce __xdp_build_skb_from_frame and xdp_build_skb_from_frame
> > > routines to
> > > build the skb from a xdp_frame. Respect to __xdp_build_skb_from_frame,
> > > xdp_build_skb_from_frame will
veth
> code.
Hi Daniel/Alexei,
since this series is marked as "archived" in patchwork, do I need to resubmit
it?
Regards,
Lorenzo
>
> Lorenzo Bianconi (2):
> net: xdp: introduce __xdp_build_skb_from_frame utility routine
> net: xdp: introduce xdp_build_skb_from_fr
send_message to be
> more neutral like mt7615_mcu_send_message.
>
> Fixes: e637763b606b ("mt76: move mcu queues to mt76_dev q_mcu array")
> Link: https://github.com/ClangBuiltLinux/linux/issues/1229
> Signed-off-by: Nathan Chancellor
Acked-by: Lorenzo Bianconi
> ---
>
> > + hard_start = page_address(rx_buffer->page) +
> > + rx_buffer->page_offset - offset;
> > + xdp_prepare_buff(&xdp, hard_start, offset, size,
> > true);
> > #if (PAGE_SIZE > 4096)
> > /* At larger P
Introduce xdp_prepare_buff utility routine to initialize per-descriptor
xdp_buff fields (e.g. xdp_buff pointers). Rely on xdp_prepare_buff() in
all XDP capable drivers.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/amazon/ena/ena_netdev.c | 7 +++
drivers/net/ethernet/broadcom
p->data as hard_start + headroom and save it in a local
variable to reuse it for xdp->data_end and xdp->data_meta in
xdp_prepare_buff()
Changes since v1:
- introduce xdp_prepare_buff utility routine
Lorenzo Bianconi (2):
net: xdp: introduce xdp_init_buff utility routine
net: xdp: introdu
Introduce xdp_init_buff utility routine to initialize xdp_buff fields
const over NAPI iterations (e.g. frame_sz or rxq pointer). Rely on
xdp_init_buff in all XDP capable drivers.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/amazon/ena/ena_netdev.c| 3 +--
drivers/net
On Mon, Dec 21, 2020 at 9:37 AM Jesper Dangaard Brouer
wrote:
>
> On Sat, 19 Dec 2020 18:55:00 +0100
> Lorenzo Bianconi wrote:
>
> > diff --git a/include/net/xdp.h b/include/net/xdp.h
> > index 11ec93f827c0..323340caef88 100644
> > --- a/include/net/xdp.h
> >
On Sat, Dec 19, 2020 at 4:56 PM Shay Agroskin wrote:
>
>
> Lorenzo Bianconi writes:
>
> > Introduce the capability to map non-linear xdp buffer running
> > mvneta_xdp_submit_frame() for XDP_TX and XDP_REDIRECT
> >
> > Signed-off-by: Lorenzo Bianconi
>
>
>
> Lorenzo Bianconi writes:
>
> > Introduce __xdp_build_skb_from_frame and
> > xdp_build_skb_from_frame
> > utility routines to build the skb from xdp_frame.
> > Add xdp multi-buff support to cpumap
> >
> > Signed-off-by: Lorenzo Bianconi
> &
>
>
> Lorenzo Bianconi writes:
>
> >> On Mon, 2020-12-07 at 17:32 +0100, Lorenzo Bianconi wrote:
> >> > Introduce xdp_shared_info data structure to contain info
> >> > about
> >> > "non-linear" xdp frame. xdp_shared_info will ali
>
>
> Lorenzo Bianconi writes:
>
> > Introduce xdp_init_buff and xdp_prepare_buff utility routines to
> > initialize
> > xdp_buff data structure and remove duplicated code in all XDP
> > capable
> > drivers.
> >
> > Changes sin
Introduce xdp_prepare_buff utility routine to initialize per-descriptor
xdp_buff fields (e.g. xdp_buff pointers). Rely on xdp_prepare_buff() in
all XDP capable drivers.
Signed-off-by: Lorenzo Bianconi
---
drivers/net/ethernet/amazon/ena/ena_netdev.c | 7 +++
drivers/net/ethernet
xdp_prepare_buff()
Changes since v1:
- introduce xdp_prepare_buff utility routine
Lorenzo Bianconi (2):
net: xdp: introduce xdp_init_buff utility routine
net: xdp: introduce xdp_prepare_buff utility routine
Acked-by: Martin Habets
Acked-by: Camelia Groza
drivers/net/ethernet/amazon/ena
1 - 100 of 614 matches
Mail list logo