On Tue, Apr 30, 2024 at 11:55 AM Jens Axboe wrote:
>
> On 4/30/24 12:29 PM, Mina Almasry wrote:
> > On Tue, Apr 30, 2024 at 6:46?AM Jens Axboe wrote:
> >>
> >> On 4/26/24 8:11 PM, Mina Almasry wrote:
> >>> On Fri, Apr 26, 2024 at 5:18?PM David Wei
Sorry for the late reply.
On Wed, May 1, 2024 at 12:55 AM Christoph Hellwig wrote:
>
> Still NAK to creating aⅺbitrary hooks here.
Is the concern still that folks may be able to hook proprietary stuff
into this like you mentioned before[1]?
I don't see how that can be done as currently written.
On Tue, May 7, 2024 at 9:24 AM Christoph Hellwig wrote:
>
> On Tue, May 07, 2024 at 01:18:57PM -0300, Jason Gunthorpe wrote:
> > On Tue, May 07, 2024 at 05:05:12PM +0100, Pavel Begunkov wrote:
> > > > even in tree if you give them enough rope, and they should not have
> > > > that rope when the on
On Tue, May 7, 2024 at 9:55 AM Pavel Begunkov wrote:
>
> On 5/7/24 17:23, Christoph Hellwig wrote:
> > On Tue, May 07, 2024 at 01:18:57PM -0300, Jason Gunthorpe wrote:
> >> On Tue, May 07, 2024 at 05:05:12PM +0100, Pavel Begunkov wrote:
> even in tree if you give them enough rope, and they sh
plit & RSS & flow steering support.
Cc: Pavel Begunkov
Cc: David Wei
Cc: Jason Gunthorpe
Cc: Yunsheng Lin
Cc: Shailend Chand
Cc: Harshitha Ramamurthy
Cc: Shakeel Butt
Cc: Jeroen de Borst
Cc: Praveen Kaligineedi
Jakub Kicinski (1):
net: page_pool: create hooks for custom page
Add netdev_rx_queue_restart() function to netdev_rx_queue.h
Signed-off-by: David Wei
Signed-off-by: Mina Almasry
---
v9: https://lore.kernel.org/all/20240502045410.3524155-4...@davidwei.uk/
(submitted by David).
- fixed SPDX license identifier (Simon).
- Rebased on top of merged queue API
references to be gone before feeding this
page back into the pool.
Signed-off-by: Jakub Kicinski
Signed-off-by: Mina Almasry
---
- This is implemented by Jakub in his RFC:
https://lore.kernel.org/netdev/f8270765-a27b-6ccf-33ea-cda097168...@redhat.com/T/
I take no credit for the idea or impleme
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v7:
- Use flags: [ admin-perm ] instead of a CAP_NET_ADMIN check.
Changes in v1:
- Add rx-queue-type
s, and re-initializes its page
pool.
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v9: https://lore.kernel.org/all/20240403002053.
ff-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v8:
- Rename netdev_dmabuf_binding -> net_devmem_dmabuf_binding to avoid
patch-by-patch build error.
- Move niov->pp_magic/pp/pp_ref_counter usage to later patch to avoid
patch-by-patch build
hange is factored out on its own to limit the code
churn to this 1 patch, for ease of code review.
Signed-off-by: Mina Almasry
---
v9:
- Fix sparse error (Simon).
v8:
- Fix napi_pp_put_page() taking netmem instead of page to fix
patch-by-patch build error.
- Add net/netmem.h include in this pat
hether the underlying type is page or net_iov.
Implement checks for net_iov in netmem helpers which delegate to mm
APIs, to ensure net_iov are never passed to the mm stack.
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-8-almasrym...@google.com/
- Rem
is omitted for simplicity & p.order !=
0.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v8:
- Use skb_frag_size instead of frag->bv_len to fix patch-by-patch build
error
v6:
- refactor new memory provider functions into net/core/devme
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevant callers to handle this case.
Signed-off-by: Mina Almasry
---
v6:
- Rebased on top of the merged netmem changes.
Changes in v1:
- Fix illegal_highdma() (Yunsheng).
- Rework napi_pp_put_page
ags of
devmem skbs and avoid coalescing devmem skbs with non devmem skbs.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-11-almasrym...@google.com/
- change skb->readable to skb->unrea
er_frags, and each page passed to userspace is get_page()'d.
This reference is dropped once the userspace indicates that it is
done reading this page. All pages are released when the socket is
destroyed.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
Add an interface for the user to notify the kernel that it is done
reading the devmem dmabuf frags returned as cmsg. The kernel will
drop the reference on the frags to make them available for reuse.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Add documentation outlining the usage and details of devmem TCP.
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-14-almasrym...@google.com/
- Bagas doc suggestions.
v8:
- Applied docs suggestions (Randy). Thanks!
v7:
- Applied docs suggestions
, ncdevmem has a validation mode,
where it sends a specific pattern and validates this pattern on the
receiver side to ensure data integrity.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-15-almasrym...@google.com/
- Remove
On Mon, May 13, 2024 at 4:31 PM Jakub Kicinski wrote:
>
> On Fri, 10 May 2024 16:21:11 -0700 Mina Almasry wrote:
> > Device Memory TCP
>
> Sorry Mina, this is too big to apply during the merge window :(
No worries at all. I'll repost once it re-opens with any feedbac
On Wed, May 22, 2024 at 11:02 PM David Wei wrote:
>
> On 2024-05-10 16:21, Mina Almasry wrote:
> > +/* On error, returns the -errno. On success, returns number of bytes sent
> > to the
> > + * user. May not consume all of @remaining_len.
> > + */
> > +stati
On Tue, May 28, 2024 at 7:42 PM Pavel Begunkov wrote:
>
> On 5/28/24 18:36, Mina Almasry wrote:
> > On Wed, May 22, 2024 at 11:02 PM David Wei wrote:
> ...
> >>> + */
> >>> +
On Sat, May 18, 2024 at 11:46 AM David Wei wrote:
>
> On 2024-05-10 16:21, Mina Almasry wrote:
> > +void net_devmem_unbind_dmabuf(struct net_devmem_dmabuf_binding *binding)
> > +{
> > + struct netdev_rx_queue *rxq;
> > + unsigned long xa_idx;
son Gunthorpe
Cc: Yunsheng Lin
Cc: Shailend Chand
Cc: Harshitha Ramamurthy
Cc: Shakeel Butt
Cc: Jeroen de Borst
Cc: Praveen Kaligineedi
Jakub Kicinski (1):
net: page_pool: create hooks for custom page providers
Mina Almasry (13):
netdev: add netdev_rx_queue_restart()
net: netdev netlink
Add netdev_rx_queue_restart() function to netdev_rx_queue.h
Signed-off-by: David Wei
Signed-off-by: Mina Almasry
---
v9: https://lore.kernel.org/all/20240502045410.3524155-4...@davidwei.uk/
(submitted by David).
- fixed SPDX license identifier (Simon).
- Rebased on top of merged queue API
references to be gone before feeding this
page back into the pool.
Signed-off-by: Jakub Kicinski
Signed-off-by: Mina Almasry
---
- This is implemented by Jakub in his RFC:
https://lore.kernel.org/netdev/f8270765-a27b-6ccf-33ea-cda097168...@redhat.com/T/
I take no credit for the idea or impleme
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v7:
- Use flags: [ admin-perm ] instead of a CAP_NET_ADMIN check.
Changes in v1:
- Add rx-queue-type
ff-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v8:
- Rename netdev_dmabuf_binding -> net_devmem_dmabuf_binding to avoid
patch-by-patch build error.
- Move niov->pp_magic/pp/pp_ref_counter usage to later patch to avoid
patch-by-patch build
s, and re-initializes its page
pool.
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v10:
- Moved net_iov_dma_addr() to devmem.h an
hange is factored out on its own to limit the code
churn to this 1 patch, for ease of code review.
Signed-off-by: Mina Almasry
---
v9:
- Fix sparse error (Simon).
v8:
- Fix napi_pp_put_page() taking netmem instead of page to fix
patch-by-patch build error.
- Add net/netmem.h include in this pat
hether the underlying type is page or net_iov.
Implement checks for net_iov in netmem helpers which delegate to mm
APIs, to ensure net_iov are never passed to the mm stack.
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-8-almasrym...@google.com/
- Rem
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevant callers to handle this case.
Signed-off-by: Mina Almasry
---
v10:
- Fixed newly generated kdoc warnings found by patchwork. While we're
at it, fix the Return section of the functions I to
is omitted for simplicity & p.order !=
0.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v8:
- Use skb_frag_size instead of frag->bv_len to fix patch-by-patch build
error
v6:
- refactor new memory provider functions into net/core/devme
ags of
devmem skbs and avoid coalescing devmem skbs with non devmem skbs.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-11-almasrym...@google.com/
- change skb->readable to skb->unrea
er_frags, and each page passed to userspace is get_page()'d.
This reference is dropped once the userspace indicates that it is
done reading this page. All pages are released when the socket is
destroyed.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
---
Add an interface for the user to notify the kernel that it is done
reading the devmem dmabuf frags returned as cmsg. The kernel will
drop the reference on the frags to make them available for reuse.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Add documentation outlining the usage and details of devmem TCP.
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-14-almasrym...@google.com/
- Bagas doc suggestions.
v8:
- Applied docs suggestions (Randy). Thanks!
v7:
- Applied docs suggestions
, ncdevmem has a validation mode,
where it sends a specific pattern and validates this pattern on the
receiver side to ensure data integrity.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v9:
https://lore.kernel.org/netdev/20240403002053.2376017-15-almasrym...@google.com/
- Remove
On Fri, May 31, 2024 at 10:35 PM Christoph Hellwig wrote:
>
> On Thu, May 30, 2024 at 08:16:01PM +, Mina Almasry wrote:
> > I'm unsure if the discussion has been resolved yet. Sending the series
> > anyway to get reviews/feedback on the (unrelated) rest of the se
On Mon, Jun 3, 2024 at 7:52 AM Pavel Begunkov wrote:
>
> On 6/3/24 15:17, Mina Almasry wrote:
> > On Fri, May 31, 2024 at 10:35 PM Christoph Hellwig
> > wrote:
> >>
> >> On Thu, May 30, 2024 at 08:16:01PM +, Mina Almasry wrote:
> >>> I&
On Tue, Jul 30, 2024 at 4:38 AM Markus Elfring wrote:
>
> …
> > +++ b/include/net/devmem.h
> > @@ -0,0 +1,115 @@
> …
> > +#ifndef _NET_DEVMEM_H
> > +#define _NET_DEVMEM_H
> …
>
> I suggest to omit leading underscores from such identifiers.
> https://wiki.sei.cmu.edu/confluence/display/c/DCL37-C.+D
a dependency on a specific dmabuf provider.
** Test Setup
Kernel: net-next with this series and memory provider API cherry-picked
locally.
Hardware: Google Cloud A3 VMs.
NIC: GVE with header split & RSS & flow steering support.
Cc: Pavel Begunkov
Cc: David Wei
Cc: Jason Gunthorpe
Cc
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
Reviewed-by: Donald Hunter
Reviewed-by: Jakub Kicinski
---
v16:
- Use subset-of: queue queue-id instead
ff-by: Mina Almasry
Reviewed-by: Pavel Begunkov
Reviewed-by: Jakub Kicinski
---
v18:
- Add more color to commit message (Xuan Zhuo).
v17:
- Use ASSERT_RTNL() (Jakub).
v13:
- Add reviewed-by from Pavel (thanks!)
- Fixed comment (Pavel)
v11:
- Fix not checking dev->queue_mgmt_ops (Pavel
ff-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v17:
- Don't acquire a binding ref for every allocation (Jakub).
v11:
- Fix extraneous inline directive (Paolo)
v8:
- Rename netdev_dmabuf_binding -> net_devmem_dmabuf_bin
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov # excluding netlink
Acked-by: Daniel Vetter
---
v17:
- Add missing kfree(o
These helpers are used for setup and init of buffers, and their
implementation need not be static inline in the header file.
Moving the implementation to the .c file allows us to hide netmem
implementation details in internal header files rather than the public
file.
Signed-off-by: Mina Almasry
hether the underlying type is page or net_iov.
Implement checks for net_iov in netmem helpers which delegate to mm
APIs, to ensure net_iov are never passed to the mm stack.
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v17:
- Rename netmem_to_pfn to netmem_pfn_trace (Jakub)
- Move some
is omitted for simplicity & p.order !=
0.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v17:
- Use ASSERT_RTNL (Jakub)
v16:
- Add DEBUG_NET_WARN_ON_ONCE(!rtnl_is_locked()), to catch cases if
page_pool_init
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevant callers to handle this case.
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v10:
- Fixed newly generated kdoc warnings found by patchwork. While we're
at it, fix the Return se
ags of
devmem skbs and avoid coalescing devmem skbs with non devmem skbs.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v16:
- Fix unreadable handling in skb_split_no_header() (Eric).
v11:
- drop excessive checks for
er_frags, and each page passed to userspace is get_page()'d.
This reference is dropped once the userspace indicates that it is
done reading this page. All pages are released when the socket is
destroyed.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Re
Add an interface for the user to notify the kernel that it is done
reading the devmem dmabuf frags returned as cmsg. The kernel will
drop the reference on the frags to make them available for reuse.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Add documentation outlining the usage and details of devmem TCP.
Signed-off-by: Mina Almasry
Reviewed-by: Bagas Sanjaya
Reviewed-by: Donald Hunter
---
v16:
- Add documentation on unbinding the NIC from dmabuf (Donald).
- Add note that any dmabuf should work (Donald).
v9:
https
7;inflight': 1023,
'inflight-mem': 4190208},
And queue stats:
$ ./cli.py --spec ../netlink/specs/netdev.yaml --dump queue-get
...
{'dmabuf': 10, 'id': 8, 'ifindex': 3, 'type': 'rx'},
{'dmabuf': 10, 'id': 9,
, ncdevmem has a validation mode,
where it sends a specific pattern and validates this pattern on the
receiver side to ensure data integrity.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v16:
- Remove outdated -n option (Taehee).
- Use 'ifname' instead of accidentally hardc
On Tue, Aug 6, 2024 at 4:59 PM Jakub Kicinski wrote:
>
...
> On Mon, 5 Aug 2024 21:25:20 +0000 Mina Almasry wrote:
> > + if (pool->p.queue) {
> > + /* We rely on rtnl_lock()ing to make sure netdev_rx_queue
> > + * configuration doesn't
On Thu, Aug 8, 2024 at 10:24 PM Jakub Kicinski wrote:
>
> On Thu, 8 Aug 2024 16:36:24 -0400 Mina Almasry wrote:
> > > How do you know that the driver:
> > > - supports net_iov at all (let's not make implicit assumptions based
> > >on presence of qu
On Fri, Aug 9, 2024 at 11:52 PM Jakub Kicinski wrote:
>
> On Fri, 9 Aug 2024 16:45:50 +0100 Pavel Begunkov wrote:
> > > I think this is good, and it doesn't seem hacky to me, because we can
> > > check the page_pools of the netdev while we hold rtnl, so we can be
> > > sure nothing is messing with
On Mon, Aug 12, 2024 at 1:57 PM Jakub Kicinski wrote:
>
> On Sun, 11 Aug 2024 22:51:13 +0100 Pavel Begunkov wrote:
> > > I think we're talking about 2 slightly different flags, AFAIU.>
> > > Pavel and I are suggesting the driver reports "I support memory
> > > providers" directly to core (via the
On Mon, Aug 12, 2024 at 8:15 PM Jakub Kicinski wrote:
> BTW, Mina, the core should probably also check that XDP isn't installed
> before / while the netmem is bound to a queue.
Sorry if noob question, but what is the proper check for this? I tried
adding this to net_devmem_bind_dmabuf_to_queue():
On Tue, Aug 13, 2024 at 4:39 AM Mina Almasry wrote:
>
> On Mon, Aug 12, 2024 at 8:15 PM Jakub Kicinski wrote:
> > BTW, Mina, the core should probably also check that XDP isn't installed
> > before / while the netmem is bound to a queue.
>
> Sorry if noob question,
to end without
a dependency on a specific dmabuf provider.
** Test Setup
Kernel: net-next with this series and memory provider API cherry-picked
locally.
Hardware: Google Cloud A3 VMs.
NIC: GVE with header split & RSS & flow steering support.
Cc: Pavel Begunkov
Cc: David Wei
Cc: Jaso
ff-by: Mina Almasry
Reviewed-by: Pavel Begunkov
Reviewed-by: Jakub Kicinski
---
v18:
- Add more color to commit message (Xuan Zhuo).
v17:
- Use ASSERT_RTNL() (Jakub).
v13:
- Add reviewed-by from Pavel (thanks!)
- Fixed comment (Pavel)
v11:
- Fix not checking dev->queue_mgmt_ops (Pavel
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
Reviewed-by: Donald Hunter
Reviewed-by: Jakub Kicinski
---
v16:
- Use subset-of: queue queue-id instead
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov # excluding netlink
Acked-by: Daniel Vetter
---
v19:
- Prevent deactiva
ff-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v19:
- Don't reset dma_addr on allocation/free (Jakub)
v17:
- Don't acquire a binding ref for every allocation (Jakub).
v11:
- Fix extraneous inline directive (Paolo
hether the underlying type is page or net_iov.
Implement checks for net_iov in netmem helpers which delegate to mm
APIs, to ensure net_iov are never passed to the mm stack.
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v19:
- Move page_pool_set_dma_addr(_netmem) to page_pool_priv.h
- D
is omitted for simplicity & p.order !=
0.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v19:
- Add PP_FLAG_ALLOW_UNREADABLE_NETMEM flag. It serves 2 purposes, (a)
it guards drivers that don't support unrea
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevant callers to handle this case.
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v10:
- Fixed newly generated kdoc warnings found by patchwork. While we're
at it, fix the Return se
ags of
devmem skbs and avoid coalescing devmem skbs with non devmem skbs.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v16:
- Fix unreadable handling in skb_split_no_header() (Eric).
v11:
- drop excessive checks for
er_frags, and each page passed to userspace is get_page()'d.
This reference is dropped once the userspace indicates that it is
done reading this page. All pages are released when the socket is
destroyed.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Re
Add an interface for the user to notify the kernel that it is done
reading the devmem dmabuf frags returned as cmsg. The kernel will
drop the reference on the frags to make them available for reuse.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Add documentation outlining the usage and details of devmem TCP.
Signed-off-by: Mina Almasry
Reviewed-by: Bagas Sanjaya
Reviewed-by: Donald Hunter
---
v16:
- Add documentation on unbinding the NIC from dmabuf (Donald).
- Add note that any dmabuf should work (Donald).
v9:
https
, ncdevmem has a validation mode,
where it sends a specific pattern and validates this pattern on the
receiver side to ensure data integrity.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v19:
- Check return code of ethtool commands.
- Add test for deactivating mp bound rx queues
7;inflight': 1023,
'inflight-mem': 4190208},
And queue stats:
$ ./cli.py --spec ../netlink/specs/netdev.yaml --dump queue-get
...
{'dmabuf': 10, 'id': 8, 'ifindex': 3, 'type': 'rx'},
{'dmabuf': 10, 'id': 9,
On Wed, Aug 14, 2024 at 10:11 AM Pavel Begunkov wrote:
...
> > diff --git a/net/core/devmem.c b/net/core/devmem.c
> > index 301f4250ca82..2f2a7f4dee4c 100644
> > --- a/net/core/devmem.c
> > +++ b/net/core/devmem.c
> > @@ -17,6 +17,7 @@
> > #include
> > #include
> > #include
> > +#include
On Thu, Aug 15, 2024 at 9:22 PM Jakub Kicinski wrote:
>
> On Wed, 14 Aug 2024 17:32:53 +0100 Pavel Begunkov wrote:
> > > This is where I get a bit confused. Jakub did mention that it is
> > > desirable for core to verify that the driver did the right thing,
> > > instead of trusting that a driver
On Thu, Aug 15, 2024 at 8:48 PM Jakub Kicinski wrote:
>
> On Tue, 13 Aug 2024 21:13:05 +0000 Mina Almasry wrote:
> > +int dev_get_max_mp_channel(const struct net_device *dev)
> > +{
> > + int i, max = -1;
>
> I presume the bug from yesterday is self eviden
On Sat, Aug 17, 2024 at 9:58 AM Taehee Yoo wrote:
>
> On Wed, Aug 14, 2024 at 6:13 AM Mina Almasry wrote:
> >
>
> Hi Mina,
>
> > In tcp_recvmsg_locked(), detect if the skb being received by the user
> > is a devmem skb. In this case - if the user provided the M
end without
a dependency on a specific dmabuf provider.
** Test Setup
Kernel: net-next with this series and memory provider API cherry-picked
locally.
Hardware: Google Cloud A3 VMs.
NIC: GVE with header split & RSS & flow steering support.
Cc: Pavel Begunkov
Cc: David Wei
Cc: Jason Gunthor
ff-by: Mina Almasry
Reviewed-by: Pavel Begunkov
Reviewed-by: Jakub Kicinski
---
v18:
- Add more color to commit message (Xuan Zhuo).
v17:
- Use ASSERT_RTNL() (Jakub).
v13:
- Add reviewed-by from Pavel (thanks!)
- Fixed comment (Pavel)
v11:
- Fix not checking dev->queue_mgmt_ops (Pavel
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
Reviewed-by: Donald Hunter
Reviewed-by: Jakub Kicinski
---
v16:
- Use subset-of: queue queue-id instead
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov # excluding netlink
Acked-by: Daniel Vetter
---
v20:
- re
ff-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v20:
- Removed dma_addr field in dmabuf_genpool_chunk_owner not used in this
patch (moved to later patch where it's used).
v19:
- Don't reset dma_addr on allocation/fr
hether the underlying type is page or net_iov.
Implement checks for net_iov in netmem helpers which delegate to mm
APIs, to ensure net_iov are never passed to the mm stack.
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v19:
- Move page_pool_set_dma_addr(_netmem) to page_pool_priv.h
- D
Make skb_frag_page() fail in the case where the frag is not backed
by a page, and fix its relevant callers to handle this case.
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v10:
- Fixed newly generated kdoc warnings found by patchwork. While we're
at it, fix the Return se
is omitted for simplicity & p.order !=
0.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov
---
v20:
- Moved queue pp_params field from fast path entries to slow path
entries.
- Moved page_pool_check_memory_provider()
ags of
devmem skbs and avoid coalescing devmem skbs with non devmem skbs.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Eric Dumazet
---
v16:
- Fix unreadable handling in skb_split_no_header() (Eric).
v11:
- drop excessive checks for
er_frags, and each page passed to userspace is get_page()'d.
This reference is dropped once the userspace indicates that it is
done reading this page. All pages are released when the socket is
destroyed.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Re
Add an interface for the user to notify the kernel that it is done
reading the devmem dmabuf frags returned as cmsg. The kernel will
drop the reference on the frags to make them available for reuse.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Add documentation outlining the usage and details of devmem TCP.
Signed-off-by: Mina Almasry
Reviewed-by: Bagas Sanjaya
Reviewed-by: Donald Hunter
---
v16:
- Add documentation on unbinding the NIC from dmabuf (Donald).
- Add note that any dmabuf should work (Donald).
v9:
https
, ncdevmem has a validation mode,
where it sends a specific pattern and validates this pattern on the
receiver side to ensure data integrity.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
---
v20:
- Remove unnecessary sleep(1)
- Add test to ensure dmabuf binding fails if header split is
7;inflight': 1023,
'inflight-mem': 4190208},
And queue stats:
$ ./cli.py --spec ../netlink/specs/netdev.yaml --dump queue-get
...
{'dmabuf': 10, 'id': 8, 'ifindex': 3, 'type': 'rx'},
{'dmabuf': 10, 'id': 9,
On Sun, Aug 18, 2024 at 11:54 PM Mina Almasry wrote:
>
> v20:
> https://patchwork.kernel.org/project/netdevbpf/list/?series=879373&state=*
>
>
> v20 aims to resolve a couple of bug reports against v19, and addresses
> some review comments around the page_p
On Mon, Aug 19, 2024 at 6:53 PM Jakub Kicinski wrote:
>
> On Mon, 19 Aug 2024 00:44:27 +0900 Taehee Yoo wrote:
> > > @@ -9537,6 +9540,10 @@ static int dev_xdp_attach(struct net_device *dev,
> > > struct netlink_ext_ack *extack
> > > NL_SET_ERR_MSG(extack, "Native and gener
d memory provider API cherry-picked
locally.
Hardware: Google Cloud A3 VMs.
NIC: GVE with header split & RSS & flow steering support.
Cc: Pavel Begunkov
Cc: David Wei
Cc: Jason Gunthorpe
Cc: Yunsheng Lin
Cc: Shailend Chand
Cc: Harshitha Ramamurthy
Cc: Shakeel Butt
Cc: Jeroen de Borst
Cc: P
ff-by: Mina Almasry
Reviewed-by: Pavel Begunkov
Reviewed-by: Jakub Kicinski
---
v18:
- Add more color to commit message (Xuan Zhuo).
v17:
- Use ASSERT_RTNL() (Jakub).
v13:
- Add reviewed-by from Pavel (thanks!)
- Fixed comment (Pavel)
v11:
- Fix not checking dev->queue_mgmt_ops (Pavel
API takes the dma-buf fd as input, and binds it to the netdevice. The
user can specify the rx queues to bind the dma-buf to.
Suggested-by: Stanislav Fomichev
Signed-off-by: Mina Almasry
Reviewed-by: Donald Hunter
Reviewed-by: Jakub Kicinski
---
v16:
- Use subset-of: queue queue-id instead
The netdev_dmabuf_binding struct is refcounted, and releases its
resources only when all the refs are released.
Signed-off-by: Willem de Bruijn
Signed-off-by: Kaiyuan Zhang
Signed-off-by: Mina Almasry
Reviewed-by: Pavel Begunkov # excluding netlink
Acked-by: Daniel Vetter
---
v21:
- Move definitio
301 - 400 of 462 matches
Mail list logo