From: Ilias Apalodimas <ilias.apalodimas@linaro.org>
To: Yunsheng Lin <linyunsheng@huawei.com>
Cc: Matteo Croce <mcroce@linux.microsoft.com>,
Marcin Wojtas <mw@semihalf.com>,
"Russell King (Oracle)" <linux@armlinux.org.uk>,
Sven Auhagen <sven.auhagen@voleatech.de>,
David Miller <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
linuxarm@openeuler.org, yisen.zhuang@huawei.com,
salil.mehta@huawei.com,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
Jesper Dangaard Brouer <hawk@kernel.org>,
Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
John Fastabend <john.fastabend@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
Peter Zijlstra <peterz@infradead.org>,
Will Deacon <will@kernel.org>,
Matthew Wilcox <willy@infradead.org>,
Vlastimil Babka <vbabka@suse.cz>,
Fenghua Yu <fenghua.yu@intel.com>, Roman Gushchin <guro@fb.com>,
Peter Xu <peterx@redhat.com>,
feng.tang@intel.com, Jason Gunthorpe <jgg@ziepe.ca>,
Matteo Croce <mcroce@microsoft.com>,
Hugh Dickins <hughd@google.com>,
Jonathan Lemon <jonathan.lemon@gmail.com>,
Alexander Lobakin <alobakin@pm.me>,
Willem de Bruijn <willemb@google.com>, wenxu <wenxu@ucloud.cn>,
Cong Wang <cong.wang@bytedance.com>,
Kevin Hao <haokexin@gmail.com>,
Aleksandr Nogikh <nogikh@google.com>,
Marco Elver <elver@google.com>,
netdev@vger.kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
bpf@vger.kernel.org
Subject: Re: [PATCH net-next RFC 0/2] add elevated refcnt support for page pool
Date: Fri, 9 Jul 2021 09:42:30 +0300 [thread overview]
Message-ID: <YOfv1vHcZPBvyfaN@enceladus> (raw)
In-Reply-To: <14a92860-67cc-b2ac-efba-dd482f03204b@huawei.com>
On Fri, Jul 09, 2021 at 02:40:02PM +0800, Yunsheng Lin wrote:
> On 2021/7/9 12:15, Matteo Croce wrote:
> > On Wed, Jul 7, 2021 at 6:50 PM Marcin Wojtas <mw@semihalf.com> wrote:
> >>
> >> Hi,
> >>
> >>
> >> ??r., 7 lip 2021 o 01:20 Matteo Croce <mcroce@linux.microsoft.com> napisa??(a):
> >>>
> >>> On Tue, Jul 6, 2021 at 5:51 PM Russell King (Oracle)
> >>> <linux@armlinux.org.uk> wrote:
> >>>>
> >>>> On Fri, Jul 02, 2021 at 03:39:47PM +0200, Matteo Croce wrote:
> >>>>> On Wed, 30 Jun 2021 17:17:54 +0800
> >>>>> Yunsheng Lin <linyunsheng@huawei.com> wrote:
> >>>>>
> >>>>>> This patchset adds elevated refcnt support for page pool
> >>>>>> and enable skb's page frag recycling based on page pool
> >>>>>> in hns3 drvier.
> >>>>>>
> >>>>>> Yunsheng Lin (2):
> >>>>>> page_pool: add page recycling support based on elevated refcnt
> >>>>>> net: hns3: support skb's frag page recycling based on page pool
> >>>>>>
> >>>>>> drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 79 +++++++-
> >>>>>> drivers/net/ethernet/hisilicon/hns3/hns3_enet.h | 3 +
> >>>>>> drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 1 +
> >>>>>> drivers/net/ethernet/marvell/mvneta.c | 6 +-
> >>>>>> drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 +-
> >>>>>> include/linux/mm_types.h | 2 +-
> >>>>>> include/linux/skbuff.h | 4 +-
> >>>>>> include/net/page_pool.h | 30 ++-
> >>>>>> net/core/page_pool.c | 215
> >>>>>> +++++++++++++++++---- 9 files changed, 285 insertions(+), 57
> >>>>>> deletions(-)
> >>>>>>
> >>>>>
> >>>>> Interesting!
> >>>>> Unfortunately I'll not have access to my macchiatobin anytime soon, can
> >>>>> someone test the impact, if any, on mvpp2?
> >>>>
> >>>> I'll try to test. Please let me know what kind of testing you're
> >>>> looking for (I haven't been following these patches, sorry.)
> >>>>
> >>>
> >>> A drop test or L2 routing will be enough.
> >>> BTW I should have the macchiatobin back on friday.
> >>
> >> I have a 10G packet generator connected to 10G ports of CN913x-DB - I
> >> will stress mvpp2 in l2 forwarding early next week (I'm mostly AFK
> >> this until Monday).
> >>
> >
> > I managed to to a drop test on mvpp2. Maybe there is a slowdown but
> > it's below the measurement uncertainty.
> >
> > Perf top before:
> >
> > Overhead Shared O Symbol
> > 8.48% [kernel] [k] page_pool_put_page
> > 2.57% [kernel] [k] page_pool_refill_alloc_cache
> > 1.58% [kernel] [k] page_pool_alloc_pages
> > 0.75% [kernel] [k] page_pool_return_skb_page
> >
> > after:
> >
> > Overhead Shared O Symbol
> > 8.34% [kernel] [k] page_pool_put_page
> > 4.52% [kernel] [k] page_pool_return_skb_page
> > 4.42% [kernel] [k] page_pool_sub_bias
> > 3.16% [kernel] [k] page_pool_alloc_pages
> > 2.43% [kernel] [k] page_pool_refill_alloc_cache
>
> Hi, Matteo
> Thanks for the testing.
> it seems you have adapted the mvpp2 driver to use the new frag
> API for page pool, There is one missing optimization for XDP case,
> the page is always returned to the pool->ring regardless of the
> context of page_pool_put_page() for elevated refcnt case.
>
> Maybe adding back that optimization will close some gap of the above
> performance difference if the drop is happening in softirq context.
>
I think what Matteo did was a pure netstack test. We'll need testing on
both XDP and normal network cases to be able to figure out the exact
impact.
Thanks
/Ilias
> >
> > Regards,
> >
prev parent reply other threads:[~2021-07-09 6:42 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-30 9:17 [PATCH net-next RFC 0/2] add elevated refcnt support for page pool Yunsheng Lin
2021-06-30 9:17 ` [PATCH net-next RFC 1/2] page_pool: add page recycling support based on elevated refcnt Yunsheng Lin
2021-06-30 15:08 ` kernel test robot
2021-06-30 17:14 ` kernel test robot
2021-07-02 9:42 ` Jesper Dangaard Brouer
2021-07-02 10:15 ` Yunsheng Lin
2021-07-06 4:54 ` Ilias Apalodimas
2021-07-06 6:46 ` Yunsheng Lin
2021-07-06 8:18 ` Ilias Apalodimas
2021-07-06 20:45 ` Alexander Duyck
2021-07-07 3:05 ` Yunsheng Lin
2021-07-07 15:01 ` Alexander Duyck
2021-07-07 19:03 ` Ilias Apalodimas
2021-07-07 21:49 ` Alexander Duyck
2021-07-08 14:21 ` Ilias Apalodimas
2021-07-08 14:24 ` Alexander Duyck
2021-07-08 14:50 ` Ilias Apalodimas
2021-07-08 15:17 ` Ilias Apalodimas
2021-07-08 15:29 ` Alexander Duyck
2021-07-08 15:36 ` Ilias Apalodimas
2021-07-08 15:41 ` Alexander Duyck
2021-07-08 15:47 ` Ilias Apalodimas
2021-07-08 2:27 ` Yunsheng Lin
2021-07-08 15:36 ` Alexander Duyck
2021-07-09 6:26 ` Yunsheng Lin
2021-07-09 14:15 ` Alexander Duyck
2021-07-10 9:16 ` [Linuxarm] " Yunsheng Lin
2021-06-30 9:17 ` [PATCH net-next RFC 2/2] net: hns3: support skb's frag page recycling based on page pool Yunsheng Lin
2021-07-02 8:36 ` [PATCH net-next RFC 0/2] add elevated refcnt support for " Ilias Apalodimas
2021-07-02 13:39 ` Matteo Croce
2021-07-06 15:51 ` Russell King (Oracle)
2021-07-06 23:19 ` Matteo Croce
2021-07-07 16:50 ` Marcin Wojtas
2021-07-09 4:15 ` Matteo Croce
2021-07-09 6:40 ` Yunsheng Lin
2021-07-09 6:42 ` Ilias Apalodimas [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=YOfv1vHcZPBvyfaN@enceladus \
--to=ilias.apalodimas@linaro.org \
--cc=akpm@linux-foundation.org \
--cc=alobakin@pm.me \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=cong.wang@bytedance.com \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=elver@google.com \
--cc=feng.tang@intel.com \
--cc=fenghua.yu@intel.com \
--cc=guro@fb.com \
--cc=haokexin@gmail.com \
--cc=hawk@kernel.org \
--cc=hughd@google.com \
--cc=jgg@ziepe.ca \
--cc=john.fastabend@gmail.com \
--cc=jonathan.lemon@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=linuxarm@openeuler.org \
--cc=linyunsheng@huawei.com \
--cc=mcroce@linux.microsoft.com \
--cc=mcroce@microsoft.com \
--cc=mw@semihalf.com \
--cc=netdev@vger.kernel.org \
--cc=nogikh@google.com \
--cc=peterx@redhat.com \
--cc=peterz@infradead.org \
--cc=salil.mehta@huawei.com \
--cc=sven.auhagen@voleatech.de \
--cc=thomas.petazzoni@bootlin.com \
--cc=vbabka@suse.cz \
--cc=wenxu@ucloud.cn \
--cc=will@kernel.org \
--cc=willemb@google.com \
--cc=willy@infradead.org \
--cc=yisen.zhuang@huawei.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.