mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-16 16:48:38 -04:00
ext4: add prefetch_block_bitmaps mount option
For file systems where we can afford to keep the buddy bitmaps cached, we can speed up initial writes to large file systems by starting to load the block allocation bitmaps as soon as the file system is mounted. This won't work well for _super_ large file systems, or memory constrained systems, so we only enable this when it is requested via a mount option. Addresses-Google-Bug: 159488342 Signed-off-by: Theodore Ts'o <tytso@mit.edu> Reviewed-by: Andreas Dilger <adilger@dilger.ca>
This commit is contained in:
@@ -2742,6 +2742,50 @@ TRACE_EVENT(ext4_error,
|
||||
__entry->function, __entry->line)
|
||||
);
|
||||
|
||||
TRACE_EVENT(ext4_prefetch_bitmaps,
|
||||
TP_PROTO(struct super_block *sb, ext4_group_t group,
|
||||
ext4_group_t next, unsigned int prefetch_ios),
|
||||
|
||||
TP_ARGS(sb, group, next, prefetch_ios),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field( dev_t, dev )
|
||||
__field( __u32, group )
|
||||
__field( __u32, next )
|
||||
__field( __u32, ios )
|
||||
),
|
||||
|
||||
TP_fast_assign(
|
||||
__entry->dev = sb->s_dev;
|
||||
__entry->group = group;
|
||||
__entry->next = next;
|
||||
__entry->ios = prefetch_ios;
|
||||
),
|
||||
|
||||
TP_printk("dev %d,%d group %u next %u ios %u",
|
||||
MAJOR(__entry->dev), MINOR(__entry->dev),
|
||||
__entry->group, __entry->next, __entry->ios)
|
||||
);
|
||||
|
||||
TRACE_EVENT(ext4_lazy_itable_init,
|
||||
TP_PROTO(struct super_block *sb, ext4_group_t group),
|
||||
|
||||
TP_ARGS(sb, group),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field( dev_t, dev )
|
||||
__field( __u32, group )
|
||||
),
|
||||
|
||||
TP_fast_assign(
|
||||
__entry->dev = sb->s_dev;
|
||||
__entry->group = group;
|
||||
),
|
||||
|
||||
TP_printk("dev %d,%d group %u",
|
||||
MAJOR(__entry->dev), MINOR(__entry->dev), __entry->group)
|
||||
);
|
||||
|
||||
#endif /* _TRACE_EXT4_H */
|
||||
|
||||
/* This part must be outside protection */
|
||||
|
||||
Reference in New Issue
Block a user