From: no-reply@sashiko.virtuozzo.com
To: Konstantin Khorenko <khorenko@virtuozzo.com>,
Liu Kui <kui.liu@virtuozzo.com>
Cc: devel@openvz.org, azaitsev@virtuozzo.com
Subject: Re: [Devel] [PATCH hci-8.1 1/3] fs/fuse kio: teach pcs_umem about hugepage-backed mappings
Date: Wed, 30 Sep 2026 07:41:56 +0000 [thread overview]
Message-ID: <010701a0f1435502-816204c4-752e-4b1f-95ba-4a4f09b5312b-000000@eu-central-1.amazonses.com> (raw)
In-Reply-To: <20260930-sockio-refactor-8-1-v1-1-806348b9eb26@virtuozzo.com>
> pcs_umem pins every mapping as a flat array of 4k pages and the krpc
> bvec builder emits one bio_vec per page, so a 1M chunk costs 256 page
> pointers and 256 bio_vecs even when it sits in a single hugepage.
>
> Detect hugepage backing after pinning: if the range is 2M-aligned and
> each 2M chunk is backed by one folio (hugetlbfs or fully-mapped THP),
> keep only the folio head page per chunk and raise umem->page_shift to
> PMD_SHIFT. The bvec builder then caps bv_len at the backing unit
> instead of PAGE_SIZE, so a 1M chunk in a hugepage umem becomes a
> single bio_vec. Mixed or misaligned mappings stay at 4k.
>
> Also pin with pin_user_pages_fast(), which needs no mmap_lock, and
> fix the pcs_umem_get() error path, which leaked chunk page arrays and
> could deref a NULL page_chunk.
>
> https://virtuozzo.atlassian.net/browse/VSTOR-142166
>
> Signed-off-by: Liu Kui <kui.liu@virtuozzo.com>
Sashiko has reviewed this patch and found no issues. It looks great!
--
Sashiko AI review · https://sashiko.vzint.dev/#/patchset/20260930-sockio-refactor-8-1-v1-0-806348b9eb26@virtuozzo.com?part=1
_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel
next prev parent reply other threads:[~2026-09-30 7:43 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-30 7:34 [Devel] [PATCH hci-8.1 0/3] fs/fuse kio: cut per-4k-page sendmsg/recvmsg calls in the sockio path Liu Kui
2026-09-30 7:34 ` [Devel] [PATCH hci-8.1 1/3] fs/fuse kio: teach pcs_umem about hugepage-backed mappings Liu Kui
2026-09-30 7:41 ` no-reply [this message]
2026-09-30 7:34 ` [Devel] [PATCH hci-8.1 2/3] fs/fuse kio: refactor transmit path in pcs_sockio_send() Liu Kui
2026-09-30 7:42 ` no-reply
2026-09-30 16:29 ` Konstantin Khorenko
2026-09-30 7:34 ` [Devel] [PATCH hci-8.1 3/3] fs/fuse kio: refactor receive path in pcs_sockio_recv() Liu Kui
2026-09-30 7:42 ` no-reply
2026-09-30 16:09 ` [Devel] [PATCH hci-8.1 0/3] fs/fuse kio: cut per-4k-page sendmsg/recvmsg calls in the sockio path Konstantin Khorenko
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=010701a0f1435502-816204c4-752e-4b1f-95ba-4a4f09b5312b-000000@eu-central-1.amazonses.com \
--to=no-reply@sashiko.virtuozzo.com \
--cc=azaitsev@virtuozzo.com \
--cc=devel@openvz.org \
--cc=khorenko@virtuozzo.com \
--cc=kui.liu@virtuozzo.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.