Re: [PATCH v6 5/6] fuse: add zero-copy over io-uring
Joanne Koong <[email protected]>
| Newsgroups | dev.linux.lists.fuse-devel |
|---|---|
| Message-ID | <CAJnrk1bnohB5QPib4tKK1mYCyD_EeH2oMW+Qgo64k6HzmmK-Fw@mail.gmail.com> |
On Thu, Aug 13, 2026 at 1:42 PM Bernd Schubert <[email protected]> wrote: > > > >> As far as I know kmalloc will allocate continuos pages and might fail > >> under fragmentation if more than a page is needed. I'm not entirely sure > >> if kvmalloc for such a small allocation will actually do the job. > >> How about the attached patch? And with that maybe we should limit > >> max_nr_pages to 256 for ZC? > > > > I think kvmalloc should be fine. For size > PAGE_SIZE it tries kmalloc > > first and has a fallback to vmalloc. For small allocations, kvmalloc > > is just plain kmalloc. > > I think the patch I had attached is more elegant, but we can do that any > time later. I just found kvmalloc_flex, I guess that would be most suitable. > I'll change this to use kvmalloc_flex. Thanks, Joanne