Page MenuHomeFreeBSD

mbuf: Don't force all M_EXTPG mbufs to be read-only
ClosedPublic

Authored by jhb on Sep 25 2024, 3:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Oct 9, 2:32 AM
Unknown Object (File)
Wed, Oct 8, 3:17 PM
Unknown Object (File)
Fri, Sep 26, 3:14 AM
Unknown Object (File)
Mon, Sep 22, 6:29 PM
Unknown Object (File)
Sep 11 2025, 3:24 AM
Unknown Object (File)
Sep 1 2025, 9:18 AM
Unknown Object (File)
Aug 28 2025, 10:08 AM
Unknown Object (File)
Aug 28 2025, 7:33 AM
Subscribers

Details

Summary

Some M_EXTPG mbufs are read-only (e.g. those backing sendfile
requests), but others are not. Add a flags argument to
mb_alloc_ext_pgs that can be used to set M_RDONLY when needed rather
than setting it unconditionally. Update mb_unmapped_to_ext to
preserve M_RDONLY from the unmapped mbuf.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable