]> Git Repo - linux.git/commit
mm: move the page fragment allocator from page_alloc into its own file
authorYunsheng Lin <[email protected]>
Mon, 28 Oct 2024 11:53:37 +0000 (19:53 +0800)
committerJakub Kicinski <[email protected]>
Mon, 11 Nov 2024 18:56:26 +0000 (10:56 -0800)
commit65941f10caf2c04781a7defa4ec0ab119dbd235a
treee4982d0c0f320176d20baf143178b53ce2bca854
parent7fef0dec415c08c16c31dd2c2501a8c734a4b3b8
mm: move the page fragment allocator from page_alloc into its own file

Inspired by [1], move the page fragment allocator from page_alloc
into its own c file and header file, as we are about to make more
change for it to replace another page_frag implementation in
sock.c

As this patchset is going to replace 'struct page_frag' with
'struct page_frag_cache' in sched.h, including page_frag_cache.h
in sched.h has a compiler error caused by interdependence between
mm_types.h and mm.h for asm-offsets.c, see [2]. So avoid the compiler
error by moving 'struct page_frag_cache' to mm_types_task.h as
suggested by Alexander, see [3].

1. https://lore.kernel.org/all/20230411160902.4134381[email protected]/
2. https://lore.kernel.org/all/15623dac-9358-4597-b3ee-3694a5956920@gmail.com/
3. https://lore.kernel.org/all/CAKgT0UdH1yD=LSCXFJ=YM_aiA4OomD-2wXykO42bizaWMt_HOA@mail.gmail.com/
CC: David Howells <[email protected]>
CC: Linux-MM <[email protected]>
Signed-off-by: Yunsheng Lin <[email protected]>
Acked-by: Andrew Morton <[email protected]>
Reviewed-by: Alexander Duyck <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
include/linux/gfp.h
include/linux/mm_types.h
include/linux/mm_types_task.h
include/linux/page_frag_cache.h [new file with mode: 0644]
include/linux/skbuff.h
mm/Makefile
mm/page_alloc.c
mm/page_frag_cache.c [new file with mode: 0644]
tools/testing/selftests/mm/page_frag/page_frag_test.c
This page took 0.05123 seconds and 4 git commands to generate.