v1 2026-08-18

引入直接映射大 folio 池分配器 · v1

引入Direct-Map Large Folio Pool和Scratchpad bump分配器,将nf_tables/bpf/lockdep等分配路由到folio_pool。

原始补丁链接

子 Patch(9)

1/9
lib/folio_pool: Introduce Direct-Map Large Folio Pool & Scratchpad bump allocators
新增基于direct-map大页的folio_scratchpad与folio_pool线性bump分配器,支持任意/固定大小分配及O(1)批量释放,并用static key控制开关。
2/9
netfilter/nf_tables: Add folio_scratchpad collector to struct nftables_pernet
在nftables_pernet内嵌folio_scratchpad,将nft_trans_alloc改走该分配器,commit/abort时O(1)批量释放事务对象,减少SLUB开销。
3/9
bpf/verifier: Route verifier stack state node allocations to folio_pool
在bpf_verifier_env内嵌folio_pool,将bpf_verifier_stack_elem帧分配改用大页池,bpf_check结束时批量释放全部帧。
4/9
drm/gpuvm: Route gpuva_op allocations to folio_scratchpad
在drm_gpuvm内嵌folio_scratchpad,gpuva_op_alloc改用它分配,drm_gpuvm_fini时O(1)批量释放,绕过SLUB。
5/9
bpf/syscall: Route generic_map_update_batch key/value allocations to folio_scratchpad
bpf map批量更新时,临时key/value缓冲区改用folio_scratchpad分配,避免SLUB缓存频繁分配释放。
6/9
locking/lockdep: Fallback to folio_pool in alloc_list_entry when static pool is full
Thank you for your contribution! Sashiko AI review found 3 potential issue(s) to consider: - [High] Atomic context violation and RT-deadlock in lockdep dynamic allocation. - [High] Use-After-Free and
7/9
locking/lockdep: Traverse adjacency lists directly in zap_class()
Thank you for your contribution! Sashiko AI review found 3 potential issue(s) to consider: New issues: - [High] zap_class() incorrectly searches the zapped class’s own dependency lists instead of the
8/9
locking/lockdep: Shrink static list_entries array to early bootstrap buffer
Thank you for your contribution! Sashiko AI review found 6 potential issue(s) to consider: New issues: - [High] Dynamically allocated lock_list entries from lockdep_pool are permanently leaked when l
9/9
locking/lockdep: Migrate and compact boot-time dependency graph from __initdata
Thank you for your contribution! Sashiko AI review found 4 potential issue(s) to consider: - [High] Invalid Wait Context on PREEMPT_RT and potential buddy allocator recursion. - [High] Use-After-Free