Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Jan 2021 18:44:12 GMT
From:      Andrew Gallatin <gallatin@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 52cd25eb1aa7 - main - mbuf: enable ext_pgs ("unmapped") mbufs by default
Message-ID:  <202101081844.108IiCHg070535@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by gallatin:

URL: https://cgit.FreeBSD.org/src/commit/?id=52cd25eb1aa75a28f6d3c3eb4757242c1f55d6cc

commit 52cd25eb1aa75a28f6d3c3eb4757242c1f55d6cc
Author:     Andrew Gallatin <gallatin@FreeBSD.org>
AuthorDate: 2021-01-08 18:18:42 +0000
Commit:     Andrew Gallatin <gallatin@FreeBSD.org>
CommitDate: 2021-01-08 18:43:30 +0000

    mbuf: enable ext_pgs ("unmapped") mbufs by default
    
    Ext_pg mbufs allow carrying multiple pages per mbuf. This
    reduces mbuf linked list traversals, especially in socket
    buffers, thereby reducing cache misses and CPU use for
    applications using sendfile.  Note that ext_pages use
    unmapped pages, eliminating KVA mapping costs on 32-bit
    platforms.
    
    Ext_pg mbufs are also required for ktls (KERN_TLS), and having
    them disabled by default is a stumbling block for those
    wishing to enable ktls.
    
    Reviewed-by:    jhb, glebius
    Sponsored by:   Netfix
---
 sys/kern/kern_mbuf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/kern/kern_mbuf.c b/sys/kern/kern_mbuf.c
index 84e068424427..a46c576bad90 100644
--- a/sys/kern/kern_mbuf.c
+++ b/sys/kern/kern_mbuf.c
@@ -116,7 +116,7 @@ int nmbjumbop;			/* limits number of page size jumbo clusters */
 int nmbjumbo9;			/* limits number of 9k jumbo clusters */
 int nmbjumbo16;			/* limits number of 16k jumbo clusters */
 
-bool mb_use_ext_pgs;		/* use M_EXTPG mbufs for sendfile & TLS */
+bool mb_use_ext_pgs = true;	/* use M_EXTPG mbufs for sendfile & TLS */
 SYSCTL_BOOL(_kern_ipc, OID_AUTO, mb_use_ext_pgs, CTLFLAG_RWTUN,
     &mb_use_ext_pgs, 0,
     "Use unmapped mbufs for sendfile(2) and TLS offload");



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202101081844.108IiCHg070535>