mm: Remove stray references to pagevec
Subsystems (33)
v2 cover mm: Remove stray references to pagevec
struct pagevec was removed in commit 1e0877d58b1e ("mm: remove struct pagevec"). Remove any stray references to it and rename relevant files and macros accordingly.
While at it, remove unnecessary #includes of pagevec.h (now folio_batch.h) in .c files. There are probably more of these that could be removed in .h files, but those are more complex to verify.
---
Changes in v2:
- Add tags from Matthew, David, and Chris (thanks!).
- Add 3 new patches with more cleanups.
- Link to v1: https://lore.kernel.org/r/[email protected]
---
Tal Zussman (4):
mm: Remove stray references to struct pagevec
fs: Remove unncessary pagevec.h includes
folio_batch: Rename pagevec.h to folio_batch.h
folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
MAINTAINERS | 1 +
drivers/gpu/drm/drm_gem.c | 2 +-
drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +-
drivers/gpu/drm/i915/gt/intel_gtt.h | 2 +-
drivers/gpu/drm/i915/i915_gpu_error.c | 2 +-
fs/afs/internal.h | 1 -
fs/afs/write.c | 1 -
fs/btrfs/compression.c | 2 +-
fs/btrfs/extent_io.c | 6 +++---
fs/btrfs/tests/extent-io-tests.c | 2 +-
fs/buffer.c | 2 +-
fs/ceph/addr.c | 2 +-
fs/dax.c | 1 -
fs/ext4/file.c | 1 -
fs/ext4/inode.c | 2 +-
fs/ext4/page-io.c | 1 -
fs/ext4/readpage.c | 1 -
fs/f2fs/checkpoint.c | 2 +-
fs/f2fs/compress.c | 2 +-
fs/f2fs/data.c | 2 +-
fs/f2fs/f2fs.h | 2 --
fs/f2fs/file.c | 1 -
fs/f2fs/node.c | 2 +-
fs/gfs2/aops.c | 2 +-
fs/hugetlbfs/inode.c | 2 +-
fs/mpage.c | 1 -
fs/netfs/buffered_write.c | 1 -
fs/nfs/blocklayout/blocklayout.c | 1 -
fs/nfs/dir.c | 1 -
fs/nilfs2/btree.c | 2 +-
fs/nilfs2/page.c | 2 +-
fs/nilfs2/segment.c | 2 +-
fs/ocfs2/refcounttree.c | 1 -
fs/ramfs/file-nommu.c | 2 +-
fs/smb/client/connect.c | 1 -
fs/smb/client/file.c | 1 -
include/linux/{pagevec.h => folio_batch.h} | 16 ++++++++--------
include/linux/folio_queue.h | 8 ++++----
include/linux/iomap.h | 2 +-
include/linux/sunrpc/svc.h | 2 +-
include/linux/swap.h | 2 --
include/linux/writeback.h | 2 +-
mm/filemap.c | 2 +-
mm/gup.c | 2 +-
mm/memcontrol.c | 2 +-
mm/mlock.c | 2 +-
mm/page-writeback.c | 2 +-
mm/page_alloc.c | 2 +-
mm/shmem.c | 6 +++---
mm/swap.c | 4 ++--
mm/swap_state.c | 4 ++--
mm/truncate.c | 8 ++++----
mm/vmscan.c | 2 +-
53 files changed, 56 insertions(+), 73 deletions(-)---
base-commit: 957a3fab8811b455420128ea5f41c51fd23eb6c7
change-id: 20260225-pagevec_cleanup-d47c16cb0f2d
Best regards,
Signature · 1 line
Tal Zussman <[email protected]>
PATCH v2 1/4 mm: Remove stray references to struct pagevec
struct pagevec was removed in commit 1e0877d58b1e ("mm: remove struct pagevec"). Remove remaining forward declarations and change __folio_batch_release()'s declaration to match its definition.
--- fs/afs/internal.h | 1 - fs/f2fs/f2fs.h | 2 -- include/linux/pagevec.h | 2 +- include/linux/swap.h | 2 -- 4 files changed, 1 insertion(+), 6 deletions(-)
fs/afs/internal.h +0 -1
@@ -31,7 +31,6 @@#define AFS_CELL_MAX_ADDRS 15 -struct pagevec ;struct afs_call ;struct afs_vnode ;struct afs_server_probe ;
fs/f2fs/f2fs.h +0 -2
@@ -28,8 +28,6 @@#include <linux/fscrypt.h> #include <linux/fsverity.h> -struct pagevec ; -#ifdef CONFIG_F2FS_CHECK_FS #define f2fs_bug_on (sbi, condition) BUG_ON(condition)#else
include/linux/pagevec.h +1 -1
@@ -93,7 +93,7 @@ static inline struct folio *folio_batch_next(struct folio_batch *fbatch)return fbatch->folios[fbatch->i++]; } -void __folio_batch_release (struct folio_batch *pvec); +void __folio_batch_release (struct folio_batch *fbatch);static inline void folio_batch_release (struct folio_batch *fbatch) {
include/linux/swap.h +0 -2
@@ -20,8 +20,6 @@ struct notifier_block;struct bio ; -struct pagevec ; -#define SWAP_FLAG_PREFER 0x8000/* set if swap priority specified */ #define SWAP_FLAG_PRIO_MASK 0x7fff#define SWAP_FLAG_DISCARD 0x10000/* enable discard for swap */
Signature · 1 line
2.39.5
Re: [PATCH v2 1/4] mm: Remove stray references to struct pagevec
Quoted 8 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Remove remaining forward declarations and change __folio_batch_release()'s declaration to match its definition.Reviewed-by Matthew Wilcox (Oracle) <[email protected]>Acked-by Chris Li <[email protected]>Signed-off-by Tal Zussman <[email protected]>
Quoted 7 lines
--- fs/afs/internal.h | 1 - fs/f2fs/f2fs.h | 2 -- include/linux/pagevec.h | 2 +- include/linux/swap.h | 2 -- 4 files changed, 1 insertion(+), 6 deletions(-)
LGTM.
Best Regards,
Yan, Zi
Re: [PATCH v2 1/4] mm: Remove stray references to struct pagevec
In reply to Tal ZussmanQuoted 8 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Remove remaining forward declarations and change __folio_batch_release()'s declaration to match its definition.Reviewed-by Matthew Wilcox (Oracle) <[email protected]>Acked-by Chris Li <[email protected]>Signed-off-by Tal Zussman <[email protected]>
LGTM, so:
Quoted 62 lines
--- fs/afs/internal.h | 1 - fs/f2fs/f2fs.h | 2 -- include/linux/pagevec.h | 2 +- include/linux/swap.h | 2 -- 4 files changed, 1 insertion(+), 6 deletions(-)fs/afs/internal.h +0
-1@@ -31,7 +31,6 @@#define AFS_CELL_MAX_ADDRS 15 -struct pagevec ;struct afs_call ;struct afs_vnode ;struct afs_server_probe ;fs/f2fs/f2fs.h +0
-2@@ -28,8 +28,6 @@#include <linux/fscrypt.h> #include <linux/fsverity.h> -struct pagevec ; -#ifdef CONFIG_F2FS_CHECK_FS #define f2fs_bug_on (sbi, condition) BUG_ON(condition)#else include/linux/pagevec.h +1
-1@@ -93,7 +93,7 @@ static inline struct folio *folio_batch_next(struct folio_batch *fbatch)return fbatch->folios[fbatch->i++]; } -void __folio_batch_release (struct folio_batch *pvec); +void __folio_batch_release (struct folio_batch *fbatch);static inline void folio_batch_release (struct folio_batch *fbatch) {include/linux/swap.h +0
-3@@ -20,8 +20,6 @@ struct notifier_block;struct bio ; -struct pagevec ; -#define SWAP_FLAG_PREFER 0x8000/* set if swap priority specified */ #define SWAP_FLAG_PRIO_MASK 0x7fff#define SWAP_FLAG_DISCARD 0x10000/* enable discard for swap */ --2.39.5
PATCH v2 2/4 fs: Remove unncessary pagevec.h includes
In reply to Tal ZussmanRemove unused pagevec.h includes from .c files. These were found with the following command:
grep -rl '#include.*pagevec\.h' --include='*.c' | while read f; do grep -qE 'PAGEVEC_SIZE|folio_batch' "$f" || echo "$f" done
There are probably more removal candidates in .h files, but those are more complex to analyze.
--- fs/afs/write.c | 1 - fs/dax.c | 1 - fs/ext4/file.c | 1 - fs/ext4/page-io.c | 1 - fs/ext4/readpage.c | 1 - fs/f2fs/file.c | 1 - fs/mpage.c | 1 - fs/netfs/buffered_write.c | 1 - fs/nfs/blocklayout/blocklayout.c | 1 - fs/nfs/dir.c | 1 - fs/ocfs2/refcounttree.c | 1 - fs/smb/client/connect.c | 1 - fs/smb/client/file.c | 1 - 13 files changed, 13 deletions(-)
fs/afs/write.c +0 -1
@@ -10,7 +10,6 @@#include <linux/fs.h> #include <linux/pagemap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/netfs.h> #include <trace/events/netfs.h> #include "internal.h"
fs/dax.c +0 -1
@@ -15,7 +15,6 @@#include <linux/memcontrol.h> #include <linux/mm.h> #include <linux/mutex.h> -#include <linux/pagevec.h> #include <linux/sched.h> #include <linux/sched/signal.h> #include <linux/uio.h>
fs/ext4/file.c +0 -1
@@ -27,7 +27,6 @@#include <linux/dax.h> #include <linux/filelock.h> #include <linux/quotaops.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/mman.h> #include <linux/backing-dev.h>
fs/ext4/page-io.c +0 -1
@@ -16,7 +16,6 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/mpage.h> #include <linux/namei.h> #include <linux/uio.h>
fs/ext4/readpage.c +0 -1
@@ -43,7 +43,6 @@#include <linux/mpage.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "ext4.h" #include <trace/events/ext4.h>
fs/f2fs/file.c +0 -1
@@ -17,7 +17,6 @@#include <linux/compat.h> #include <linux/uaccess.h> #include <linux/mount.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/uuid.h> #include <linux/file.h>
fs/mpage.c +0 -1
@@ -28,7 +28,6 @@#include <linux/mm_inline.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "internal.h" /*
fs/netfs/buffered_write.c +0 -1
@@ -10,7 +10,6 @@#include <linux/mm.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> #include "internal.h" static void __netfs_set_group (struct folio *folio,struct netfs_group *netfs_group)
fs/nfs/blocklayout/blocklayout.c +0 -1
@@ -36,7 +36,6 @@#include <linux/namei.h> #include <linux/bio.h> /* struct bio */ #include <linux/prefetch.h> -#include <linux/pagevec.h> #include "../pnfs.h" #include "../nfs4session.h"
fs/nfs/dir.c +0 -1
@@ -32,7 +32,6 @@#include <linux/nfs_fs.h> #include <linux/nfs_mount.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/namei.h> #include <linux/mount.h> #include <linux/swap.h>
fs/ocfs2/refcounttree.c +0 -1
@@ -31,7 +31,6 @@#include <linux/blkdev.h> #include <linux/slab.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/swap.h> #include <linux/security.h> #include <linux/string.h>
fs/smb/client/connect.c +0 -1
@@ -20,7 +20,6 @@#include <linux/delay.h> #include <linux/completion.h> #include <linux/kthread.h> -#include <linux/pagevec.h> #include <linux/freezer.h> #include <linux/namei.h> #include <linux/uuid.h>
fs/smb/client/file.c +0 -1
@@ -15,7 +15,6 @@#include <linux/stat.h> #include <linux/fcntl.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/writeback.h> #include <linux/task_io_accounting_ops.h> #include <linux/delay.h>
Signature · 1 line
2.39.5
Re: [PATCH v2 2/4] fs: Remove unncessary pagevec.h includes
Quoted 11 lines · Tal Zussman
Remove unused
pagevec.hincludes from .c files. These were found with the following command:grep -rl '#include.*pagevec\.h' --include='*.c' | while read f; do grep -qE 'PAGEVEC_SIZE|folio_batch' "$f" || echo "$f" doneThere are probably more removal candidates in .h files, but those are more complex to analyze.
Signed-off-by Tal Zussman <[email protected]>
If it compiles than it's nice to get rid of. Feel free to add:
Honza
Quoted 176 lines
--- fs/afs/write.c | 1 - fs/dax.c | 1 - fs/ext4/file.c | 1 - fs/ext4/page-io.c | 1 - fs/ext4/readpage.c | 1 - fs/f2fs/file.c | 1 - fs/mpage.c | 1 - fs/netfs/buffered_write.c | 1 - fs/nfs/blocklayout/blocklayout.c | 1 - fs/nfs/dir.c | 1 - fs/ocfs2/refcounttree.c | 1 - fs/smb/client/connect.c | 1 - fs/smb/client/file.c | 1 - 13 files changed, 13 deletions(-)fs/afs/write.c +0
-1@@ -10,7 +10,6 @@#include <linux/fs.h> #include <linux/pagemap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/netfs.h> #include <trace/events/netfs.h> #include "internal.h" fs/dax.c +0
-1@@ -15,7 +15,6 @@#include <linux/memcontrol.h> #include <linux/mm.h> #include <linux/mutex.h> -#include <linux/pagevec.h> #include <linux/sched.h> #include <linux/sched/signal.h> #include <linux/uio.h> fs/ext4/file.c +0
-1@@ -27,7 +27,6 @@#include <linux/dax.h> #include <linux/filelock.h> #include <linux/quotaops.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/mman.h> #include <linux/backing-dev.h> fs/ext4/page-io.c +0
-1@@ -16,7 +16,6 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/mpage.h> #include <linux/namei.h> #include <linux/uio.h> fs/ext4/readpage.c +0
-1@@ -43,7 +43,6 @@#include <linux/mpage.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "ext4.h" #include <trace/events/ext4.h> fs/f2fs/file.c +0
-1@@ -17,7 +17,6 @@#include <linux/compat.h> #include <linux/uaccess.h> #include <linux/mount.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/uuid.h> #include <linux/file.h> fs/mpage.c +0
-1@@ -28,7 +28,6 @@#include <linux/mm_inline.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "internal.h" /* fs/netfs/buffered_write.c +0
-1@@ -10,7 +10,6 @@#include <linux/mm.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> #include "internal.h" static void __netfs_set_group (struct folio *folio,struct netfs_group *netfs_group)fs/nfs/blocklayout/blocklayout.c +0
-1@@ -36,7 +36,6 @@#include <linux/namei.h> #include <linux/bio.h> /* struct bio */ #include <linux/prefetch.h> -#include <linux/pagevec.h> #include "../pnfs.h" #include "../nfs4session.h" fs/nfs/dir.c +0
-1@@ -32,7 +32,6 @@#include <linux/nfs_fs.h> #include <linux/nfs_mount.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/namei.h> #include <linux/mount.h> #include <linux/swap.h> fs/ocfs2/refcounttree.c +0
-1@@ -31,7 +31,6 @@#include <linux/blkdev.h> #include <linux/slab.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/swap.h> #include <linux/security.h> #include <linux/string.h> fs/smb/client/connect.c +0
-1@@ -20,7 +20,6 @@#include <linux/delay.h> #include <linux/completion.h> #include <linux/kthread.h> -#include <linux/pagevec.h> #include <linux/freezer.h> #include <linux/namei.h> #include <linux/uuid.h> fs/smb/client/file.c +0
-1@@ -15,7 +15,6 @@#include <linux/stat.h> #include <linux/fcntl.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/writeback.h> #include <linux/task_io_accounting_ops.h> #include <linux/delay.h> Signature · 2 lines
-- 2.39.5
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Re: [PATCH v2 2/4] Remove unncessary pagevec.h includes
In reply to Tal ZussmanQuoted 11 lines · Tal Zussman
Remove unused
pagevec.hincludes from .c files. These were found with the following command:grep -rl '#include.*pagevec\.h' --include='*.c' | while read f; do grep -qE 'PAGEVEC_SIZE|folio_batch' "$f" || echo "$f" doneThere are probably more removal candidates in .h files, but those are more complex to analyze.
Signed-off-by Tal Zussman <[email protected]>
Quoted 16 lines
--- fs/afs/write.c | 1 - fs/dax.c | 1 - fs/ext4/file.c | 1 - fs/ext4/page-io.c | 1 - fs/ext4/readpage.c | 1 - fs/f2fs/file.c | 1 - fs/mpage.c | 1 - fs/netfs/buffered_write.c | 1 - fs/nfs/blocklayout/blocklayout.c | 1 - fs/nfs/dir.c | 1 - fs/ocfs2/refcounttree.c | 1 - fs/smb/client/connect.c | 1 - fs/smb/client/file.c | 1 - 13 files changed, 13 deletions(-)
Best Regards,
Yan, Zi
Re: [PATCH v2 2/4] fs: Remove unncessary pagevec.h includes
In reply to Tal ZussmanQuoted 4 lines · Tal Zussman
Remove unused
pagevec.hincludes from .c files. These were found with the following command:
Quoted 8 lines
grep -rl '#include.*pagevec\.h' --include='*.c' | while read f; do grep -qE 'PAGEVEC_SIZE|folio_batch' "$f" || echo "$f" doneThere are probably more removal candidates in .h files, but those are more complex to analyze.
Signed-off-by Tal Zussman <[email protected]>
Chris
Re: [PATCH v2 2/4] fs: Remove unncessary pagevec.h includes
In reply to Tal ZussmanQuoted 11 lines · Tal Zussman
Remove unused
pagevec.hincludes from .c files. These were found with the following command:grep -rl '#include.*pagevec\.h' --include='*.c' | while read f; do grep -qE 'PAGEVEC_SIZE|folio_batch' "$f" || echo "$f" doneThere are probably more removal candidates in .h files, but those are more complex to analyze.
Signed-off-by Tal Zussman <[email protected]>
Nice, LGTM so:
Quoted 176 lines
--- fs/afs/write.c | 1 - fs/dax.c | 1 - fs/ext4/file.c | 1 - fs/ext4/page-io.c | 1 - fs/ext4/readpage.c | 1 - fs/f2fs/file.c | 1 - fs/mpage.c | 1 - fs/netfs/buffered_write.c | 1 - fs/nfs/blocklayout/blocklayout.c | 1 - fs/nfs/dir.c | 1 - fs/ocfs2/refcounttree.c | 1 - fs/smb/client/connect.c | 1 - fs/smb/client/file.c | 1 - 13 files changed, 13 deletions(-)fs/afs/write.c +0
-1@@ -10,7 +10,6 @@#include <linux/fs.h> #include <linux/pagemap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/netfs.h> #include <trace/events/netfs.h> #include "internal.h" fs/dax.c +0
-1@@ -15,7 +15,6 @@#include <linux/memcontrol.h> #include <linux/mm.h> #include <linux/mutex.h> -#include <linux/pagevec.h> #include <linux/sched.h> #include <linux/sched/signal.h> #include <linux/uio.h> fs/ext4/file.c +0
-1@@ -27,7 +27,6 @@#include <linux/dax.h> #include <linux/filelock.h> #include <linux/quotaops.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/mman.h> #include <linux/backing-dev.h> fs/ext4/page-io.c +0
-1@@ -16,7 +16,6 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/mpage.h> #include <linux/namei.h> #include <linux/uio.h> fs/ext4/readpage.c +0
-1@@ -43,7 +43,6 @@#include <linux/mpage.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "ext4.h" #include <trace/events/ext4.h> fs/f2fs/file.c +0
-1@@ -17,7 +17,6 @@#include <linux/compat.h> #include <linux/uaccess.h> #include <linux/mount.h> -#include <linux/pagevec.h> #include <linux/uio.h> #include <linux/uuid.h> #include <linux/file.h> fs/mpage.c +0
-1@@ -28,7 +28,6 @@#include <linux/mm_inline.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> #include "internal.h" /* fs/netfs/buffered_write.c +0
-1@@ -10,7 +10,6 @@#include <linux/mm.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> #include "internal.h" static void __netfs_set_group (struct folio *folio,struct netfs_group *netfs_group)fs/nfs/blocklayout/blocklayout.c +0
-1@@ -36,7 +36,6 @@#include <linux/namei.h> #include <linux/bio.h> /* struct bio */ #include <linux/prefetch.h> -#include <linux/pagevec.h> #include "../pnfs.h" #include "../nfs4session.h" fs/nfs/dir.c +0
-1@@ -32,7 +32,6 @@#include <linux/nfs_fs.h> #include <linux/nfs_mount.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/namei.h> #include <linux/mount.h> #include <linux/swap.h> fs/ocfs2/refcounttree.c +0
-1@@ -31,7 +31,6 @@#include <linux/blkdev.h> #include <linux/slab.h> #include <linux/writeback.h> -#include <linux/pagevec.h> #include <linux/swap.h> #include <linux/security.h> #include <linux/string.h> fs/smb/client/connect.c +0
-1@@ -20,7 +20,6 @@#include <linux/delay.h> #include <linux/completion.h> #include <linux/kthread.h> -#include <linux/pagevec.h> #include <linux/freezer.h> #include <linux/namei.h> #include <linux/uuid.h> fs/smb/client/file.c +0
-2@@ -15,7 +15,6 @@#include <linux/stat.h> #include <linux/fcntl.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> #include <linux/writeback.h> #include <linux/task_io_accounting_ops.h> #include <linux/delay.h> --2.39.5
PATCH v2 3/4 folio_batch: Rename pagevec.h to folio_batch.h
In reply to Tal Zussmanstruct pagevec was removed in commit 1e0877d58b1e ("mm: remove struct pagevec"). Rename include/linux/pagevec.h to reflect reality and update includes tree-wide. Add the new filename to MAINTAINERS explicitly, as it no longer matches the "include/linux/page[-_]*" pattern in MEMORY MANAGEMENT - CORE.
---
MAINTAINERS | 1 +
drivers/gpu/drm/drm_gem.c | 2 +-
drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +-
drivers/gpu/drm/i915/gt/intel_gtt.h | 2 +-
drivers/gpu/drm/i915/i915_gpu_error.c | 2 +-
fs/btrfs/compression.c | 2 +-
fs/btrfs/extent_io.c | 2 +-
fs/btrfs/tests/extent-io-tests.c | 2 +-
fs/buffer.c | 2 +-
fs/ceph/addr.c | 2 +-
fs/ext4/inode.c | 2 +-
fs/f2fs/checkpoint.c | 2 +-
fs/f2fs/compress.c | 2 +-
fs/f2fs/data.c | 2 +-
fs/f2fs/node.c | 2 +-
fs/gfs2/aops.c | 2 +-
fs/hugetlbfs/inode.c | 2 +-
fs/nilfs2/btree.c | 2 +-
fs/nilfs2/page.c | 2 +-
fs/nilfs2/segment.c | 2 +-
fs/ramfs/file-nommu.c | 2 +-
include/linux/{pagevec.h => folio_batch.h} | 8 ++++----
include/linux/folio_queue.h | 2 +-
include/linux/iomap.h | 2 +-
include/linux/sunrpc/svc.h | 2 +-
include/linux/writeback.h | 2 +-
mm/filemap.c | 2 +-
mm/gup.c | 2 +-
mm/memcontrol.c | 2 +-
mm/mlock.c | 2 +-
mm/page-writeback.c | 2 +-
mm/page_alloc.c | 2 +-
mm/shmem.c | 2 +-
mm/swap.c | 2 +-
mm/swap_state.c | 2 +-
mm/truncate.c | 2 +-
mm/vmscan.c | 2 +-
37 files changed, 40 insertions(+), 39 deletions(-)MAINTAINERS +1 -0
@@ -16664,6 +16664,7 @@ L: [email protected] S: Maintained W: http://www.linux-mm.org T: git git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm +F: include/linux/folio_batch.h F: include/linux/gfp.h F: include/linux/gfp_types.h F: include/linux/highmem.h
drivers/gpu/drm/drm_gem.c +1 -1
@@ -38,7 +38,7 @@#include <linux/mman.h> #include <linux/module.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h> #include <linux/slab.h>
drivers/gpu/drm/i915/gem/i915_gem_shmem.c +1 -1
@@ -3,7 +3,7 @@* Copyright © 2014-2016 Intel Corporation */ -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/shmem_fs.h> #include <linux/swap.h> #include <linux/uio.h>
drivers/gpu/drm/i915/gt/intel_gtt.h +1 -1
@@ -19,7 +19,7 @@#include <linux/io-mapping.h> #include <linux/kref.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/workqueue.h>
drivers/gpu/drm/i915/i915_gpu_error.c +1 -1
@@ -31,7 +31,7 @@#include <linux/debugfs.h> #include <linux/highmem.h> #include <linux/nmi.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/string_helpers.h> #include <linux/utsname.h>
fs/btrfs/compression.c +1 -1
@@ -8,7 +8,7 @@#include <linux/file.h> #include <linux/fs.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/highmem.h> #include <linux/kthread.h> #include <linux/time.h>
fs/btrfs/extent_io.c +1 -1
@@ -11,7 +11,7 @@#include <linux/blkdev.h> #include <linux/swap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/fsverity.h> #include "extent_io.h"
fs/btrfs/tests/extent-io-tests.c +1 -1
@@ -4,7 +4,7 @@*/ #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched.h> #include <linux/slab.h> #include <linux/sizes.h>
fs/buffer.c +1 -1
@@ -45,7 +45,7 @@#include <linux/bitops.h> #include <linux/mpage.h> #include <linux/bit_spinlock.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <trace/events/block.h> #include <linux/fscrypt.h>
fs/ceph/addr.c +1 -1
@@ -7,7 +7,7 @@#include <linux/swap.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/signal.h> #include <linux/iversion.h>
fs/ext4/inode.c +1 -1
@@ -29,7 +29,7 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/rmap.h> #include <linux/namei.h>
fs/f2fs/checkpoint.c +1 -1
@@ -11,7 +11,7 @@#include <linux/writeback.h> #include <linux/blkdev.h> #include <linux/f2fs_fs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include <linux/kthread.h> #include <linux/delayacct.h>
fs/f2fs/compress.c +1 -1
@@ -13,7 +13,7 @@#include <linux/lzo.h> #include <linux/lz4.h> #include <linux/zstd.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "f2fs.h" #include "node.h"
fs/f2fs/data.c +1 -1
@@ -10,7 +10,7 @@#include <linux/sched/mm.h> #include <linux/mpage.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/blkdev.h> #include <linux/bio.h> #include <linux/blk-crypto.h>
fs/f2fs/node.c +1 -1
@@ -10,7 +10,7 @@#include <linux/mpage.h> #include <linux/sched/mm.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include "f2fs.h"
fs/gfs2/aops.c +1 -1
@@ -10,7 +10,7 @@#include <linux/completion.h> #include <linux/buffer_head.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/fs.h> #include <linux/writeback.h>
fs/hugetlbfs/inode.c +1 -1
@@ -25,7 +25,7 @@#include <linux/ctype.h> #include <linux/backing-dev.h> #include <linux/hugetlb.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/fs_parser.h> #include <linux/mman.h> #include <linux/slab.h>
fs/nilfs2/btree.c +1 -1
@@ -10,7 +10,7 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/errno.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "nilfs.h" #include "page.h" #include "btnode.h"
fs/nilfs2/page.c +1 -1
@@ -14,7 +14,7 @@#include <linux/page-flags.h> #include <linux/list.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/gfp.h> #include "nilfs.h" #include "page.h"
fs/nilfs2/segment.c +1 -1
@@ -19,7 +19,7 @@#include <linux/freezer.h> #include <linux/kthread.h> #include <linux/crc32.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/slab.h> #include <linux/sched/signal.h>
fs/ramfs/file-nommu.c +1 -1
@@ -14,7 +14,7 @@#include <linux/string.h> #include <linux/backing-dev.h> #include <linux/ramfs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mman.h> #include <linux/sched.h> #include <linux/slab.h>
include/linux/folio_batch.h renamed from include/linux/pagevec.h +4 -4
@@ -1,13 +1,13 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* include/linux/pagevec.h +* include/linux/folio_batch.h * * In many places it is efficient to batch an operation up against multiple * folios. A folio_batch is a container which is used for that. */ -#ifndef _LINUX_PAGEVEC_H -#define _LINUX_PAGEVEC_H +#ifndef _LINUX_FOLIO_BATCH_H +#define _LINUX_FOLIO_BATCH_H#include <linux/types.h>
@@ -102,4 +102,4 @@ static inline void folio_batch_release(struct folio_batch *fbatch) }void folio_batch_remove_exceptionals (struct folio_batch *fbatch); -#endif /* _LINUX_PAGEVEC_H */ +#endif /* _LINUX_FOLIO_BATCH_H */
include/linux/folio_queue.h +1 -1
@@ -14,7 +14,7 @@#ifndef _LINUX_FOLIO_QUEUE_H#define _LINUX_FOLIO_QUEUE_H -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mm.h> /*
include/linux/iomap.h +1 -1
@@ -9,7 +9,7 @@#include <linux/types.h> #include <linux/mm_types.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct address_space ;struct fiemap_extent_info ;
include/linux/sunrpc/svc.h +1 -1
@@ -20,7 +20,7 @@#include <linux/lwq.h> #include <linux/wait.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/kthread.h> /*
include/linux/writeback.h +1 -1
@@ -11,7 +11,7 @@#include <linux/flex_proportions.h> #include <linux/backing-dev-defs.h> #include <linux/blk_types.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct bio ;
mm/filemap.c +1 -1
@@ -31,7 +31,7 @@#include <linux/hash.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/security.h> #include <linux/cpuset.h> #include <linux/hugetlb.h>
mm/gup.c +1 -1
@@ -18,7 +18,7 @@#include <linux/hugetlb.h> #include <linux/migrate.h> #include <linux/mm_inline.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h>
mm/memcontrol.c +1 -1
@@ -34,7 +34,7 @@#include <linux/shmem_fs.h> #include <linux/hugetlb.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/vm_event_item.h> #include <linux/smp.h> #include <linux/page-flags.h>
mm/mlock.c +1 -1
@@ -13,7 +13,7 @@#include <linux/swap.h> #include <linux/swapops.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/pagewalk.h> #include <linux/mempolicy.h> #include <linux/syscalls.h>
mm/page-writeback.c +1 -1
@@ -33,7 +33,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/syscalls.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/timer.h> #include <linux/sched/rt.h> #include <linux/sched/signal.h>
mm/page_alloc.c +1 -1
@@ -31,7 +31,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/cpuset.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/memory_hotplug.h> #include <linux/nodemask.h> #include <linux/vmstat.h>
mm/shmem.c +1 -1
@@ -61,7 +61,7 @@ static struct vfsmount *shm_mnt __ro_after_init;#include <linux/slab.h> #include <linux/backing-dev.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/percpu_counter.h> #include <linux/falloc.h> #include <linux/splice.h>
mm/swap.c +1 -1
@@ -20,7 +20,7 @@#include <linux/swap.h> #include <linux/mman.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/init.h> #include <linux/export.h> #include <linux/mm_inline.h>
mm/swap_state.c +1 -1
@@ -15,7 +15,7 @@#include <linux/leafops.h> #include <linux/init.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/backing-dev.h> #include <linux/blkdev.h> #include <linux/migrate.h>
mm/truncate.c +1 -1
@@ -17,7 +17,7 @@#include <linux/export.h> #include <linux/pagemap.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/shmem_fs.h> #include <linux/rmap.h>
mm/vmscan.c +1 -1
@@ -44,7 +44,7 @@#include <linux/sysctl.h> #include <linux/memory-tiers.h> #include <linux/oom.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/printk.h> #include <linux/dax.h>
Signature · 1 line
2.39.5
Re: [PATCH v2 3/4] folio_batch: Rename pagevec.h to folio_batch.h
Quoted 7 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Renameinclude/linux/pagevec.hto reflect reality and update includes tree-wide. Add the new filename toMAINTAINERSexplicitly, as it no longer matches the "include/linux/page[-_]*" pattern in MEMORY MANAGEMENT - CORE.Signed-off-by Tal Zussman <[email protected]>
Looks good. Feel free to add:
Honza
Quoted 541 lines
--- MAINTAINERS | 1 + drivers/gpu/drm/drm_gem.c | 2 +- drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +- drivers/gpu/drm/i915/gt/intel_gtt.h | 2 +- drivers/gpu/drm/i915/i915_gpu_error.c | 2 +- fs/btrfs/compression.c | 2 +- fs/btrfs/extent_io.c | 2 +- fs/btrfs/tests/extent-io-tests.c | 2 +- fs/buffer.c | 2 +- fs/ceph/addr.c | 2 +- fs/ext4/inode.c | 2 +- fs/f2fs/checkpoint.c | 2 +- fs/f2fs/compress.c | 2 +- fs/f2fs/data.c | 2 +- fs/f2fs/node.c | 2 +- fs/gfs2/aops.c | 2 +- fs/hugetlbfs/inode.c | 2 +- fs/nilfs2/btree.c | 2 +- fs/nilfs2/page.c | 2 +- fs/nilfs2/segment.c | 2 +- fs/ramfs/file-nommu.c | 2 +- include/linux/{pagevec.h => folio_batch.h} | 8 ++++---- include/linux/folio_queue.h | 2 +- include/linux/iomap.h | 2 +- include/linux/sunrpc/svc.h | 2 +- include/linux/writeback.h | 2 +- mm/filemap.c | 2 +- mm/gup.c | 2 +- mm/memcontrol.c | 2 +- mm/mlock.c | 2 +- mm/page-writeback.c | 2 +- mm/page_alloc.c | 2 +- mm/shmem.c | 2 +- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 2 +- mm/vmscan.c | 2 +- 37 files changed, 40 insertions(+), 39 deletions(-)MAINTAINERS +1
-0@@ -16664,6 +16664,7 @@ L: [email protected] S: Maintained W: http://www.linux-mm.org T: git git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm +F: include/linux/folio_batch.h F: include/linux/gfp.h F: include/linux/gfp_types.h F: include/linux/highmem.hdrivers/gpu/drm/drm_gem.c +1
-1@@ -38,7 +38,7 @@#include <linux/mman.h> #include <linux/module.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h> #include <linux/slab.h> drivers/gpu/drm/i915/gem/i915_gem_shmem.c +1
-1@@ -3,7 +3,7 @@* Copyright © 2014-2016 Intel Corporation */ -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/shmem_fs.h> #include <linux/swap.h> #include <linux/uio.h> drivers/gpu/drm/i915/gt/intel_gtt.h +1
-1@@ -19,7 +19,7 @@#include <linux/io-mapping.h> #include <linux/kref.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/workqueue.h> drivers/gpu/drm/i915/i915_gpu_error.c +1
-1@@ -31,7 +31,7 @@#include <linux/debugfs.h> #include <linux/highmem.h> #include <linux/nmi.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/string_helpers.h> #include <linux/utsname.h> fs/btrfs/compression.c +1
-1@@ -8,7 +8,7 @@#include <linux/file.h> #include <linux/fs.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/highmem.h> #include <linux/kthread.h> #include <linux/time.h> fs/btrfs/extent_io.c +1
-1@@ -11,7 +11,7 @@#include <linux/blkdev.h> #include <linux/swap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/fsverity.h> #include "extent_io.h" fs/btrfs/tests/extent-io-tests.c +1
-1@@ -4,7 +4,7 @@*/ #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched.h> #include <linux/slab.h> #include <linux/sizes.h> fs/buffer.c +1
-1@@ -45,7 +45,7 @@#include <linux/bitops.h> #include <linux/mpage.h> #include <linux/bit_spinlock.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <trace/events/block.h> #include <linux/fscrypt.h> fs/ceph/addr.c +1
-1@@ -7,7 +7,7 @@#include <linux/swap.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/signal.h> #include <linux/iversion.h> fs/ext4/inode.c +1
-1@@ -29,7 +29,7 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/rmap.h> #include <linux/namei.h> fs/f2fs/checkpoint.c +1
-1@@ -11,7 +11,7 @@#include <linux/writeback.h> #include <linux/blkdev.h> #include <linux/f2fs_fs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include <linux/kthread.h> #include <linux/delayacct.h> fs/f2fs/compress.c +1
-1@@ -13,7 +13,7 @@#include <linux/lzo.h> #include <linux/lz4.h> #include <linux/zstd.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "f2fs.h" #include "node.h" fs/f2fs/data.c +1
-1@@ -10,7 +10,7 @@#include <linux/sched/mm.h> #include <linux/mpage.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/blkdev.h> #include <linux/bio.h> #include <linux/blk-crypto.h> fs/f2fs/node.c +1
-1@@ -10,7 +10,7 @@#include <linux/mpage.h> #include <linux/sched/mm.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include "f2fs.h" fs/gfs2/aops.c +1
-1@@ -10,7 +10,7 @@#include <linux/completion.h> #include <linux/buffer_head.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/fs.h> #include <linux/writeback.h> fs/hugetlbfs/inode.c +1
-1@@ -25,7 +25,7 @@#include <linux/ctype.h> #include <linux/backing-dev.h> #include <linux/hugetlb.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/fs_parser.h> #include <linux/mman.h> #include <linux/slab.h> fs/nilfs2/btree.c +1
-1@@ -10,7 +10,7 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/errno.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "nilfs.h" #include "page.h" #include "btnode.h" fs/nilfs2/page.c +1
-1@@ -14,7 +14,7 @@#include <linux/page-flags.h> #include <linux/list.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/gfp.h> #include "nilfs.h" #include "page.h" fs/nilfs2/segment.c +1
-1@@ -19,7 +19,7 @@#include <linux/freezer.h> #include <linux/kthread.h> #include <linux/crc32.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/slab.h> #include <linux/sched/signal.h> fs/ramfs/file-nommu.c +1
-1@@ -14,7 +14,7 @@#include <linux/string.h> #include <linux/backing-dev.h> #include <linux/ramfs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mman.h> #include <linux/sched.h> #include <linux/slab.h> include/linux/folio_batch.h renamed from include/linux/pagevec.h +4
-4@@ -1,13 +1,13 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* include/linux/pagevec.h +* include/linux/folio_batch.h * * In many places it is efficient to batch an operation up against multiple * folios. A folio_batch is a container which is used for that. */ -#ifndef _LINUX_PAGEVEC_H -#define _LINUX_PAGEVEC_H +#ifndef _LINUX_FOLIO_BATCH_H +#define _LINUX_FOLIO_BATCH_H#include <linux/types.h> @@ -102,4 +102,4 @@ static inline void folio_batch_release(struct folio_batch *fbatch) }void folio_batch_remove_exceptionals (struct folio_batch *fbatch); -#endif /* _LINUX_PAGEVEC_H */ +#endif /* _LINUX_FOLIO_BATCH_H */ include/linux/folio_queue.h +1
-1@@ -14,7 +14,7 @@#ifndef _LINUX_FOLIO_QUEUE_H#define _LINUX_FOLIO_QUEUE_H -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mm.h> /* include/linux/iomap.h +1
-1@@ -9,7 +9,7 @@#include <linux/types.h> #include <linux/mm_types.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct address_space ;struct fiemap_extent_info ;include/linux/sunrpc/svc.h +1
-1@@ -20,7 +20,7 @@#include <linux/lwq.h> #include <linux/wait.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/kthread.h> /* include/linux/writeback.h +1
-1@@ -11,7 +11,7 @@#include <linux/flex_proportions.h> #include <linux/backing-dev-defs.h> #include <linux/blk_types.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct bio ;mm/filemap.c +1
-1@@ -31,7 +31,7 @@#include <linux/hash.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/security.h> #include <linux/cpuset.h> #include <linux/hugetlb.h> mm/gup.c +1
-1@@ -18,7 +18,7 @@#include <linux/hugetlb.h> #include <linux/migrate.h> #include <linux/mm_inline.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h> mm/memcontrol.c +1
-1@@ -34,7 +34,7 @@#include <linux/shmem_fs.h> #include <linux/hugetlb.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/vm_event_item.h> #include <linux/smp.h> #include <linux/page-flags.h> mm/mlock.c +1
-1@@ -13,7 +13,7 @@#include <linux/swap.h> #include <linux/swapops.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/pagewalk.h> #include <linux/mempolicy.h> #include <linux/syscalls.h> mm/page-writeback.c +1
-1@@ -33,7 +33,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/syscalls.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/timer.h> #include <linux/sched/rt.h> #include <linux/sched/signal.h> mm/page_alloc.c +1
-1@@ -31,7 +31,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/cpuset.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/memory_hotplug.h> #include <linux/nodemask.h> #include <linux/vmstat.h> mm/shmem.c +1
-1@@ -61,7 +61,7 @@ static struct vfsmount *shm_mnt __ro_after_init;#include <linux/slab.h> #include <linux/backing-dev.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/percpu_counter.h> #include <linux/falloc.h> #include <linux/splice.h> mm/swap.c +1
-1@@ -20,7 +20,7 @@#include <linux/swap.h> #include <linux/mman.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/init.h> #include <linux/export.h> #include <linux/mm_inline.h> mm/swap_state.c +1
-1@@ -15,7 +15,7 @@#include <linux/leafops.h> #include <linux/init.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/backing-dev.h> #include <linux/blkdev.h> #include <linux/migrate.h> mm/truncate.c +1
-1@@ -17,7 +17,7 @@#include <linux/export.h> #include <linux/pagemap.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/shmem_fs.h> #include <linux/rmap.h> mm/vmscan.c +1
-1@@ -44,7 +44,7 @@#include <linux/sysctl.h> #include <linux/memory-tiers.h> #include <linux/oom.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/printk.h> #include <linux/dax.h> Signature · 2 lines
-- 2.39.5
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Re: [PATCH v2 3/4] folio_batch: Rename pagevec.h to folio_batch.h
In reply to Tal ZussmanQuoted 8 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Renameinclude/linux/pagevec.hto reflect reality and update includes tree-wide. Add the new filename toMAINTAINERSexplicitly, as it no longer matches the "include/linux/page[-_]*" pattern in MEMORY MANAGEMENT - CORE.Signed-off-by Tal Zussman <[email protected]>---
Signature · 3 lines
Cheers, David
Re: [PATCH v2 3/4] folio_batch: Rename pagevec.h to folio_batch.h
In reply to Tal ZussmanQuoted 38 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Renameinclude/linux/pagevec.hto reflect reality and update includes tree-wide. Add the new filename toMAINTAINERSexplicitly, as it no longer matches the "include/linux/page[-_]*" pattern in MEMORY MANAGEMENT - CORE.Signed-off-by Tal Zussman <[email protected]>--- MAINTAINERS | 1 + drivers/gpu/drm/drm_gem.c | 2 +- drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +- drivers/gpu/drm/i915/gt/intel_gtt.h | 2 +- drivers/gpu/drm/i915/i915_gpu_error.c | 2 +- fs/btrfs/compression.c | 2 +- fs/btrfs/extent_io.c | 2 +- fs/btrfs/tests/extent-io-tests.c | 2 +- fs/buffer.c | 2 +- fs/ceph/addr.c | 2 +- fs/ext4/inode.c | 2 +- fs/f2fs/checkpoint.c | 2 +- fs/f2fs/compress.c | 2 +- fs/f2fs/data.c | 2 +- fs/f2fs/node.c | 2 +- fs/gfs2/aops.c | 2 +- fs/hugetlbfs/inode.c | 2 +- fs/nilfs2/btree.c | 2 +- fs/nilfs2/page.c | 2 +- fs/nilfs2/segment.c | 2 +- fs/ramfs/file-nommu.c | 2 +- include/linux/{pagevec.h => folio_batch.h} | 8 ++++---- include/linux/folio_queue.h | 2 +- include/linux/iomap.h | 2 +- include/linux/sunrpc/svc.h | 2 +- include/linux/writeback.h | 2 +- mm/filemap.c | 2 +- mm/gup.c | 2 +- mm/memcontrol.c | 2 +- mm/mlock.c | 2 +-
Quoted 9 lines
mm/page-writeback.c | 2 +- mm/page_alloc.c | 2 +- mm/shmem.c | 2 +- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 2 +- mm/vmscan.c | 2 +- 37 files changed, 40 insertions(+), 39 deletions(-)
Best Regards,
Yan, Zi
Re: [PATCH v2 3/4] folio_batch: Rename pagevec.h to folio_batch.h
In reply to Tal ZussmanQuoted 7 lines · Tal Zussman
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Renameinclude/linux/pagevec.hto reflect reality and update includes tree-wide. Add the new filename toMAINTAINERSexplicitly, as it no longer matches the "include/linux/page[-_]*" pattern in MEMORY MANAGEMENT - CORE.Signed-off-by Tal Zussman <[email protected]>
Nice, thanks for this! LGTM, so:
Quoted 541 lines
--- MAINTAINERS | 1 + drivers/gpu/drm/drm_gem.c | 2 +- drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 2 +- drivers/gpu/drm/i915/gt/intel_gtt.h | 2 +- drivers/gpu/drm/i915/i915_gpu_error.c | 2 +- fs/btrfs/compression.c | 2 +- fs/btrfs/extent_io.c | 2 +- fs/btrfs/tests/extent-io-tests.c | 2 +- fs/buffer.c | 2 +- fs/ceph/addr.c | 2 +- fs/ext4/inode.c | 2 +- fs/f2fs/checkpoint.c | 2 +- fs/f2fs/compress.c | 2 +- fs/f2fs/data.c | 2 +- fs/f2fs/node.c | 2 +- fs/gfs2/aops.c | 2 +- fs/hugetlbfs/inode.c | 2 +- fs/nilfs2/btree.c | 2 +- fs/nilfs2/page.c | 2 +- fs/nilfs2/segment.c | 2 +- fs/ramfs/file-nommu.c | 2 +- include/linux/{pagevec.h => folio_batch.h} | 8 ++++---- include/linux/folio_queue.h | 2 +- include/linux/iomap.h | 2 +- include/linux/sunrpc/svc.h | 2 +- include/linux/writeback.h | 2 +- mm/filemap.c | 2 +- mm/gup.c | 2 +- mm/memcontrol.c | 2 +- mm/mlock.c | 2 +- mm/page-writeback.c | 2 +- mm/page_alloc.c | 2 +- mm/shmem.c | 2 +- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 2 +- mm/vmscan.c | 2 +- 37 files changed, 40 insertions(+), 39 deletions(-)MAINTAINERS +1
-0@@ -16664,6 +16664,7 @@ L: [email protected] S: Maintained W: http://www.linux-mm.org T: git git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm +F: include/linux/folio_batch.h F: include/linux/gfp.h F: include/linux/gfp_types.h F: include/linux/highmem.hdrivers/gpu/drm/drm_gem.c +1
-1@@ -38,7 +38,7 @@#include <linux/mman.h> #include <linux/module.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h> #include <linux/slab.h> drivers/gpu/drm/i915/gem/i915_gem_shmem.c +1
-1@@ -3,7 +3,7 @@* Copyright © 2014-2016 Intel Corporation */ -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/shmem_fs.h> #include <linux/swap.h> #include <linux/uio.h> drivers/gpu/drm/i915/gt/intel_gtt.h +1
-1@@ -19,7 +19,7 @@#include <linux/io-mapping.h> #include <linux/kref.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/workqueue.h> drivers/gpu/drm/i915/i915_gpu_error.c +1
-1@@ -31,7 +31,7 @@#include <linux/debugfs.h> #include <linux/highmem.h> #include <linux/nmi.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/scatterlist.h> #include <linux/string_helpers.h> #include <linux/utsname.h> fs/btrfs/compression.c +1
-1@@ -8,7 +8,7 @@#include <linux/file.h> #include <linux/fs.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/highmem.h> #include <linux/kthread.h> #include <linux/time.h> fs/btrfs/extent_io.c +1
-1@@ -11,7 +11,7 @@#include <linux/blkdev.h> #include <linux/swap.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/fsverity.h> #include "extent_io.h" fs/btrfs/tests/extent-io-tests.c +1
-1@@ -4,7 +4,7 @@*/ #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched.h> #include <linux/slab.h> #include <linux/sizes.h> fs/buffer.c +1
-1@@ -45,7 +45,7 @@#include <linux/bitops.h> #include <linux/mpage.h> #include <linux/bit_spinlock.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <trace/events/block.h> #include <linux/fscrypt.h> fs/ceph/addr.c +1
-1@@ -7,7 +7,7 @@#include <linux/swap.h> #include <linux/pagemap.h> #include <linux/slab.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/signal.h> #include <linux/iversion.h> fs/ext4/inode.c +1
-1@@ -29,7 +29,7 @@#include <linux/string.h> #include <linux/buffer_head.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/rmap.h> #include <linux/namei.h> fs/f2fs/checkpoint.c +1
-1@@ -11,7 +11,7 @@#include <linux/writeback.h> #include <linux/blkdev.h> #include <linux/f2fs_fs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include <linux/kthread.h> #include <linux/delayacct.h> fs/f2fs/compress.c +1
-1@@ -13,7 +13,7 @@#include <linux/lzo.h> #include <linux/lz4.h> #include <linux/zstd.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "f2fs.h" #include "node.h" fs/f2fs/data.c +1
-1@@ -10,7 +10,7 @@#include <linux/sched/mm.h> #include <linux/mpage.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/blkdev.h> #include <linux/bio.h> #include <linux/blk-crypto.h> fs/f2fs/node.c +1
-1@@ -10,7 +10,7 @@#include <linux/mpage.h> #include <linux/sched/mm.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/swap.h> #include "f2fs.h" fs/gfs2/aops.c +1
-1@@ -10,7 +10,7 @@#include <linux/completion.h> #include <linux/buffer_head.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mpage.h> #include <linux/fs.h> #include <linux/writeback.h> fs/hugetlbfs/inode.c +1
-1@@ -25,7 +25,7 @@#include <linux/ctype.h> #include <linux/backing-dev.h> #include <linux/hugetlb.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/fs_parser.h> #include <linux/mman.h> #include <linux/slab.h> fs/nilfs2/btree.c +1
-1@@ -10,7 +10,7 @@#include <linux/slab.h> #include <linux/string.h> #include <linux/errno.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include "nilfs.h" #include "page.h" #include "btnode.h" fs/nilfs2/page.c +1
-1@@ -14,7 +14,7 @@#include <linux/page-flags.h> #include <linux/list.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/gfp.h> #include "nilfs.h" #include "page.h" fs/nilfs2/segment.c +1
-1@@ -19,7 +19,7 @@#include <linux/freezer.h> #include <linux/kthread.h> #include <linux/crc32.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/slab.h> #include <linux/sched/signal.h> fs/ramfs/file-nommu.c +1
-1@@ -14,7 +14,7 @@#include <linux/string.h> #include <linux/backing-dev.h> #include <linux/ramfs.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mman.h> #include <linux/sched.h> #include <linux/slab.h> include/linux/folio_batch.h renamed from include/linux/pagevec.h +4
-4@@ -1,13 +1,13 @@/* SPDX-License-Identifier: GPL-2.0 */ /* -* include/linux/pagevec.h +* include/linux/folio_batch.h * * In many places it is efficient to batch an operation up against multiple * folios. A folio_batch is a container which is used for that. */ -#ifndef _LINUX_PAGEVEC_H -#define _LINUX_PAGEVEC_H +#ifndef _LINUX_FOLIO_BATCH_H +#define _LINUX_FOLIO_BATCH_H#include <linux/types.h> @@ -102,4 +102,4 @@ static inline void folio_batch_release(struct folio_batch *fbatch) }void folio_batch_remove_exceptionals (struct folio_batch *fbatch); -#endif /* _LINUX_PAGEVEC_H */ +#endif /* _LINUX_FOLIO_BATCH_H */ include/linux/folio_queue.h +1
-1@@ -14,7 +14,7 @@#ifndef _LINUX_FOLIO_QUEUE_H#define _LINUX_FOLIO_QUEUE_H -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/mm.h> /* include/linux/iomap.h +1
-1@@ -9,7 +9,7 @@#include <linux/types.h> #include <linux/mm_types.h> #include <linux/blkdev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct address_space ;struct fiemap_extent_info ;include/linux/sunrpc/svc.h +1
-1@@ -20,7 +20,7 @@#include <linux/lwq.h> #include <linux/wait.h> #include <linux/mm.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/kthread.h> /* include/linux/writeback.h +1
-1@@ -11,7 +11,7 @@#include <linux/flex_proportions.h> #include <linux/backing-dev-defs.h> #include <linux/blk_types.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> struct bio ;mm/filemap.c +1
-1@@ -31,7 +31,7 @@#include <linux/hash.h> #include <linux/writeback.h> #include <linux/backing-dev.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/security.h> #include <linux/cpuset.h> #include <linux/hugetlb.h> mm/gup.c +1
-1@@ -18,7 +18,7 @@#include <linux/hugetlb.h> #include <linux/migrate.h> #include <linux/mm_inline.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/sched/mm.h> #include <linux/shmem_fs.h> mm/memcontrol.c +1
-1@@ -34,7 +34,7 @@#include <linux/shmem_fs.h> #include <linux/hugetlb.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/vm_event_item.h> #include <linux/smp.h> #include <linux/page-flags.h> mm/mlock.c +1
-1@@ -13,7 +13,7 @@#include <linux/swap.h> #include <linux/swapops.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/pagewalk.h> #include <linux/mempolicy.h> #include <linux/syscalls.h> mm/page-writeback.c +1
-1@@ -33,7 +33,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/syscalls.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/timer.h> #include <linux/sched/rt.h> #include <linux/sched/signal.h> mm/page_alloc.c +1
-1@@ -31,7 +31,7 @@#include <linux/sysctl.h> #include <linux/cpu.h> #include <linux/cpuset.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/memory_hotplug.h> #include <linux/nodemask.h> #include <linux/vmstat.h> mm/shmem.c +1
-1@@ -61,7 +61,7 @@ static struct vfsmount *shm_mnt __ro_after_init;#include <linux/slab.h> #include <linux/backing-dev.h> #include <linux/writeback.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/percpu_counter.h> #include <linux/falloc.h> #include <linux/splice.h> mm/swap.c +1
-1@@ -20,7 +20,7 @@#include <linux/swap.h> #include <linux/mman.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/init.h> #include <linux/export.h> #include <linux/mm_inline.h> mm/swap_state.c +1
-1@@ -15,7 +15,7 @@#include <linux/leafops.h> #include <linux/init.h> #include <linux/pagemap.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/backing-dev.h> #include <linux/blkdev.h> #include <linux/migrate.h> mm/truncate.c +1
-1@@ -17,7 +17,7 @@#include <linux/export.h> #include <linux/pagemap.h> #include <linux/highmem.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/task_io_accounting_ops.h> #include <linux/shmem_fs.h> #include <linux/rmap.h> mm/vmscan.c +1
-2@@ -44,7 +44,7 @@#include <linux/sysctl.h> #include <linux/memory-tiers.h> #include <linux/oom.h> -#include <linux/pagevec.h> +#include <linux/folio_batch.h> #include <linux/prefetch.h> #include <linux/printk.h> #include <linux/dax.h> --2.39.5
PATCH v2 4/4 folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
In reply to Tal Zussmanstruct pagevec no longer exists. Rename the macro appropriately.
--- fs/btrfs/extent_io.c | 4 ++-- include/linux/folio_batch.h | 6 +++--- include/linux/folio_queue.h | 6 +++--- mm/shmem.c | 4 ++-- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 6 +++--- 7 files changed, 15 insertions(+), 15 deletions(-)
fs/btrfs/extent_io.c +2 -2
@@ -2095,13 +2095,13 @@ static void buffer_tree_tag_for_writeback(struct btrfs_fs_info *fs_info,struct eb_batch {unsigned int nr;unsigned int cur; -struct extent_buffer *ebs[PAGEVEC_SIZE ]; +struct extent_buffer *ebs[FOLIO_BATCH_SIZE ]; };static inline bool eb_batch_add (struct eb_batch *batch,struct extent_buffer *eb) { batch->ebs[batch->nr++] = eb; -return (batch->nr <PAGEVEC_SIZE ); +return (batch->nr <FOLIO_BATCH_SIZE ); }static inline void eb_batch_init (struct eb_batch *batch)
include/linux/folio_batch.h +3 -3
@@ -12,7 +12,7 @@#include <linux/types.h> /* 31 pointers + header align the folio_batch structure to a power of two */ -#define PAGEVEC_SIZE 31 +#define FOLIO_BATCH_SIZE 31struct folio ;
@@ -29,7 +29,7 @@ struct folio_batch {unsigned char nr;unsigned char i;bool percpu_pvec_drained; -struct folio *folios[PAGEVEC_SIZE ]; +struct folio *folios[FOLIO_BATCH_SIZE ]; };/**
@@ -58,7 +58,7 @@ static inline unsigned int folio_batch_count(const struct folio_batch *fbatch)static inline unsigned int folio_batch_space (const struct folio_batch *fbatch) { -return PAGEVEC_SIZE - fbatch->nr; +return FOLIO_BATCH_SIZE - fbatch->nr; }/**
include/linux/folio_queue.h +3 -3
@@ -29,12 +29,12 @@*/ struct folio_queue {struct folio_batch vec;/* Folios in the queue segment */ -u8 orders[PAGEVEC_SIZE ];/* Order of each folio */ +u8 orders[FOLIO_BATCH_SIZE ];/* Order of each folio */ struct folio_queue *next;/* Next queue segment or NULL */ struct folio_queue *prev;/* Previous queue segment of NULL */ unsigned long marks;/* 1-bit mark per folio */ unsigned long marks2;/* Second 1-bit mark per folio */ -#if PAGEVEC_SIZE >BITS_PER_LONG +#if FOLIO_BATCH_SIZE >BITS_PER_LONG #error marks is not big enough#endif unsigned int rreq_id;
@@ -70,7 +70,7 @@ static inline void folioq_init(struct folio_queue *folioq, unsigned int rreq_id)*/ static inline unsigned int folioq_nr_slots (const struct folio_queue *folioq) { -return PAGEVEC_SIZE ; +return FOLIO_BATCH_SIZE ; }/**
mm/shmem.c +2 -2
@@ -1113,7 +1113,7 @@ static void shmem_undo_range(struct inode *inode, loff_t lstart, uoff_t lend,pgoff_t start = (lstart +PAGE_SIZE -1 ) >>PAGE_SHIFT ;pgoff_t end = (lend +1 ) >>PAGE_SHIFT ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio *folio;bool same_folio;long nr_swaps_freed =0 ;
@@ -1510,7 +1510,7 @@ static int shmem_unuse_inode(struct inode *inode, unsigned int type)struct address_space *mapping = inode->i_mapping;pgoff_t start =0 ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];int ret =0 ; do {
mm/swap.c +1 -1
@@ -1018,7 +1018,7 @@ EXPORT_SYMBOL(folios_put_refs);void release_pages (release_pages_arg arg,int nr) {struct folio_batch fbatch; -int refs[PAGEVEC_SIZE ]; +int refs[FOLIO_BATCH_SIZE ];struct encoded_page **encoded = arg.encoded_pages;int i;
mm/swap_state.c +1 -1
@@ -385,7 +385,7 @@ void free_folio_and_swap_cache(struct folio *folio)void free_pages_and_swap_cache (struct encoded_page **pages,int nr) {struct folio_batch folios; -unsigned int refs[PAGEVEC_SIZE ]; +unsigned int refs[FOLIO_BATCH_SIZE ];folio_batch_init (&folios);for (int i =0 ; i < nr; i++) {
mm/truncate.c +3 -3
@@ -369,7 +369,7 @@ void truncate_inode_pages_range(struct address_space *mapping,pgoff_t start;/* inclusive */ pgoff_t end;/* exclusive */ struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];pgoff_t index;int i;struct folio *folio;
@@ -534,7 +534,7 @@ EXPORT_SYMBOL(truncate_inode_pages_final);unsigned long mapping_try_invalidate (struct address_space *mapping,pgoff_t start,pgoff_t end,unsigned long *nr_failed) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index = start;unsigned long ret;
@@ -672,7 +672,7 @@ int folio_unmap_invalidate(struct address_space *mapping, struct folio *folio,int invalidate_inode_pages2_range (struct address_space *mapping,pgoff_t start,pgoff_t end) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index;int i;
Signature · 1 line
2.39.5
Re: [PATCH v2 4/4] folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
Quoted 3 lines · Tal Zussman
struct pagevec no longer exists. Rename the macro appropriately.
Signed-off-by Tal Zussman <[email protected]>
Looks good. Feel free to add:
Honza
Quoted 172 lines
--- fs/btrfs/extent_io.c | 4 ++-- include/linux/folio_batch.h | 6 +++--- include/linux/folio_queue.h | 6 +++--- mm/shmem.c | 4 ++-- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 6 +++--- 7 files changed, 15 insertions(+), 15 deletions(-)fs/btrfs/extent_io.c +2
-2@@ -2095,13 +2095,13 @@ static void buffer_tree_tag_for_writeback(struct btrfs_fs_info *fs_info,struct eb_batch {unsigned int nr;unsigned int cur; -struct extent_buffer *ebs[PAGEVEC_SIZE ]; +struct extent_buffer *ebs[FOLIO_BATCH_SIZE ]; };static inline bool eb_batch_add (struct eb_batch *batch,struct extent_buffer *eb) { batch->ebs[batch->nr++] = eb; -return (batch->nr <PAGEVEC_SIZE ); +return (batch->nr <FOLIO_BATCH_SIZE ); }static inline void eb_batch_init (struct eb_batch *batch)include/linux/folio_batch.h +3
-3@@ -12,7 +12,7 @@#include <linux/types.h> /* 31 pointers + header align the folio_batch structure to a power of two */ -#define PAGEVEC_SIZE 31 +#define FOLIO_BATCH_SIZE 31struct folio ;@@ -29,7 +29,7 @@ struct folio_batch {unsigned char nr;unsigned char i;bool percpu_pvec_drained; -struct folio *folios[PAGEVEC_SIZE ]; +struct folio *folios[FOLIO_BATCH_SIZE ]; };/** @@ -58,7 +58,7 @@ static inline unsigned int folio_batch_count(const struct folio_batch *fbatch)static inline unsigned int folio_batch_space (const struct folio_batch *fbatch) { -return PAGEVEC_SIZE - fbatch->nr; +return FOLIO_BATCH_SIZE - fbatch->nr; }/** include/linux/folio_queue.h +3
-3@@ -29,12 +29,12 @@*/ struct folio_queue {struct folio_batch vec;/* Folios in the queue segment */ -u8 orders[PAGEVEC_SIZE ];/* Order of each folio */ +u8 orders[FOLIO_BATCH_SIZE ];/* Order of each folio */ struct folio_queue *next;/* Next queue segment or NULL */ struct folio_queue *prev;/* Previous queue segment of NULL */ unsigned long marks;/* 1-bit mark per folio */ unsigned long marks2;/* Second 1-bit mark per folio */ -#if PAGEVEC_SIZE >BITS_PER_LONG +#if FOLIO_BATCH_SIZE >BITS_PER_LONG #error marks is not big enough#endif unsigned int rreq_id;@@ -70,7 +70,7 @@ static inline void folioq_init(struct folio_queue *folioq, unsigned int rreq_id)*/ static inline unsigned int folioq_nr_slots (const struct folio_queue *folioq) { -return PAGEVEC_SIZE ; +return FOLIO_BATCH_SIZE ; }/** mm/shmem.c +2
-2@@ -1113,7 +1113,7 @@ static void shmem_undo_range(struct inode *inode, loff_t lstart, uoff_t lend,pgoff_t start = (lstart +PAGE_SIZE -1 ) >>PAGE_SHIFT ;pgoff_t end = (lend +1 ) >>PAGE_SHIFT ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio *folio;bool same_folio;long nr_swaps_freed =0 ;@@ -1510,7 +1510,7 @@ static int shmem_unuse_inode(struct inode *inode, unsigned int type)struct address_space *mapping = inode->i_mapping;pgoff_t start =0 ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];int ret =0 ; do {mm/swap.c +1
-1@@ -1018,7 +1018,7 @@ EXPORT_SYMBOL(folios_put_refs);void release_pages (release_pages_arg arg,int nr) {struct folio_batch fbatch; -int refs[PAGEVEC_SIZE ]; +int refs[FOLIO_BATCH_SIZE ];struct encoded_page **encoded = arg.encoded_pages;int i;mm/swap_state.c +1
-1@@ -385,7 +385,7 @@ void free_folio_and_swap_cache(struct folio *folio)void free_pages_and_swap_cache (struct encoded_page **pages,int nr) {struct folio_batch folios; -unsigned int refs[PAGEVEC_SIZE ]; +unsigned int refs[FOLIO_BATCH_SIZE ];folio_batch_init (&folios);for (int i =0 ; i < nr; i++) {mm/truncate.c +3
-3@@ -369,7 +369,7 @@ void truncate_inode_pages_range(struct address_space *mapping,pgoff_t start;/* inclusive */ pgoff_t end;/* exclusive */ struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];pgoff_t index;int i;struct folio *folio;@@ -534,7 +534,7 @@ EXPORT_SYMBOL(truncate_inode_pages_final);unsigned long mapping_try_invalidate (struct address_space *mapping,pgoff_t start,pgoff_t end,unsigned long *nr_failed) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index = start;unsigned long ret;@@ -672,7 +672,7 @@ int folio_unmap_invalidate(struct address_space *mapping, struct folio *folio,int invalidate_inode_pages2_range (struct address_space *mapping,pgoff_t start,pgoff_t end) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index;int i;Signature · 2 lines
-- 2.39.5
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Re: [PATCH v2 4/4] folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
In reply to Tal ZussmanQuoted 4 lines · Tal Zussman
struct pagevec no longer exists. Rename the macro appropriately.
Signed-off-by Tal Zussman <[email protected]>---
Signature · 3 lines
Cheers, David
Re: [PATCH v2 4/4] folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
In reply to Tal ZussmanQuoted 13 lines · Tal Zussman
struct pagevec no longer exists. Rename the macro appropriately.
Signed-off-by Tal Zussman <[email protected]>--- fs/btrfs/extent_io.c | 4 ++-- include/linux/folio_batch.h | 6 +++--- include/linux/folio_queue.h | 6 +++--- mm/shmem.c | 4 ++-- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 6 +++--- 7 files changed, 15 insertions(+), 15 deletions(-)
Best Regards,
Yan, Zi
Re: [PATCH v2 4/4] folio_batch: Rename PAGEVEC_SIZE to FOLIO_BATCH_SIZE
In reply to Tal ZussmanQuoted 3 lines · Tal Zussman
struct pagevec no longer exists. Rename the macro appropriately.
Signed-off-by Tal Zussman <[email protected]>
Nice thanks for this! LGTM, so:
Quoted 172 lines
--- fs/btrfs/extent_io.c | 4 ++-- include/linux/folio_batch.h | 6 +++--- include/linux/folio_queue.h | 6 +++--- mm/shmem.c | 4 ++-- mm/swap.c | 2 +- mm/swap_state.c | 2 +- mm/truncate.c | 6 +++--- 7 files changed, 15 insertions(+), 15 deletions(-)fs/btrfs/extent_io.c +2
-2@@ -2095,13 +2095,13 @@ static void buffer_tree_tag_for_writeback(struct btrfs_fs_info *fs_info,struct eb_batch {unsigned int nr;unsigned int cur; -struct extent_buffer *ebs[PAGEVEC_SIZE ]; +struct extent_buffer *ebs[FOLIO_BATCH_SIZE ]; };static inline bool eb_batch_add (struct eb_batch *batch,struct extent_buffer *eb) { batch->ebs[batch->nr++] = eb; -return (batch->nr <PAGEVEC_SIZE ); +return (batch->nr <FOLIO_BATCH_SIZE ); }static inline void eb_batch_init (struct eb_batch *batch)include/linux/folio_batch.h +3
-3@@ -12,7 +12,7 @@#include <linux/types.h> /* 31 pointers + header align the folio_batch structure to a power of two */ -#define PAGEVEC_SIZE 31 +#define FOLIO_BATCH_SIZE 31struct folio ;@@ -29,7 +29,7 @@ struct folio_batch {unsigned char nr;unsigned char i;bool percpu_pvec_drained; -struct folio *folios[PAGEVEC_SIZE ]; +struct folio *folios[FOLIO_BATCH_SIZE ]; };/** @@ -58,7 +58,7 @@ static inline unsigned int folio_batch_count(const struct folio_batch *fbatch)static inline unsigned int folio_batch_space (const struct folio_batch *fbatch) { -return PAGEVEC_SIZE - fbatch->nr; +return FOLIO_BATCH_SIZE - fbatch->nr; }/** include/linux/folio_queue.h +3
-3@@ -29,12 +29,12 @@*/ struct folio_queue {struct folio_batch vec;/* Folios in the queue segment */ -u8 orders[PAGEVEC_SIZE ];/* Order of each folio */ +u8 orders[FOLIO_BATCH_SIZE ];/* Order of each folio */ struct folio_queue *next;/* Next queue segment or NULL */ struct folio_queue *prev;/* Previous queue segment of NULL */ unsigned long marks;/* 1-bit mark per folio */ unsigned long marks2;/* Second 1-bit mark per folio */ -#if PAGEVEC_SIZE >BITS_PER_LONG +#if FOLIO_BATCH_SIZE >BITS_PER_LONG #error marks is not big enough#endif unsigned int rreq_id;@@ -70,7 +70,7 @@ static inline void folioq_init(struct folio_queue *folioq, unsigned int rreq_id)*/ static inline unsigned int folioq_nr_slots (const struct folio_queue *folioq) { -return PAGEVEC_SIZE ; +return FOLIO_BATCH_SIZE ; }/** mm/shmem.c +2
-2@@ -1113,7 +1113,7 @@ static void shmem_undo_range(struct inode *inode, loff_t lstart, uoff_t lend,pgoff_t start = (lstart +PAGE_SIZE -1 ) >>PAGE_SHIFT ;pgoff_t end = (lend +1 ) >>PAGE_SHIFT ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio *folio;bool same_folio;long nr_swaps_freed =0 ;@@ -1510,7 +1510,7 @@ static int shmem_unuse_inode(struct inode *inode, unsigned int type)struct address_space *mapping = inode->i_mapping;pgoff_t start =0 ;struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];int ret =0 ; do {mm/swap.c +1
-1@@ -1018,7 +1018,7 @@ EXPORT_SYMBOL(folios_put_refs);void release_pages (release_pages_arg arg,int nr) {struct folio_batch fbatch; -int refs[PAGEVEC_SIZE ]; +int refs[FOLIO_BATCH_SIZE ];struct encoded_page **encoded = arg.encoded_pages;int i;mm/swap_state.c +1
-1@@ -385,7 +385,7 @@ void free_folio_and_swap_cache(struct folio *folio)void free_pages_and_swap_cache (struct encoded_page **pages,int nr) {struct folio_batch folios; -unsigned int refs[PAGEVEC_SIZE ]; +unsigned int refs[FOLIO_BATCH_SIZE ];folio_batch_init (&folios);for (int i =0 ; i < nr; i++) {mm/truncate.c +3
-4@@ -369,7 +369,7 @@ void truncate_inode_pages_range(struct address_space *mapping,pgoff_t start;/* inclusive */ pgoff_t end;/* exclusive */ struct folio_batch fbatch; -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];pgoff_t index;int i;struct folio *folio;@@ -534,7 +534,7 @@ EXPORT_SYMBOL(truncate_inode_pages_final);unsigned long mapping_try_invalidate (struct address_space *mapping,pgoff_t start,pgoff_t end,unsigned long *nr_failed) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index = start;unsigned long ret;@@ -672,7 +672,7 @@ int folio_unmap_invalidate(struct address_space *mapping, struct folio *folio,int invalidate_inode_pages2_range (struct address_space *mapping,pgoff_t start,pgoff_t end) { -pgoff_t indices[PAGEVEC_SIZE ]; +pgoff_t indices[FOLIO_BATCH_SIZE ];struct folio_batch fbatch;pgoff_t index;int i; --2.39.5
Andrew Morton
maintainerQuoted 7 lines · On Wed, 25 Feb 2026 18:44:24 -0500 Tal Zussman <[email protected]> wrote:
struct pagevec was removed in commit
1e0877d58b1e("mm: remove struct pagevec"). Remove any stray references to it and rename relevant files and macros accordingly.While at it, remove unnecessary #includes of
pagevec.h(nowfolio_batch.h) in .c files. There are probably more of these that could be removed in .h files, but those are more complex to verify.
Dang that's a lot of cc's ;)
Thanks, I'll add this series to mm.git's mm-new branch.
Patchwork
CI✗ LGCI.VerificationFailed: failure for mm: Remove stray references to pagevec
In reply to Tal Zussman== Series Details ==
== Series Details ==
Series: mm: Remove stray references to pagevec
URL : https://patchwork.freedesktop.org/series/162317/
State : failure
== Summary ==
Address '[email protected]' is not on the allowlist, which prevents CI from being triggered for this patch. If you want Intel GFX CI to accept this address, please contact the script maintainers at [email protected]. Exception occurred during validation, bailing out!