summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2025-02-25 02:48:54 +0300
committerCarlos Maiolino <cem@kernel.org>2025-02-25 15:05:59 +0300
commit0d1120b9bbe48a2d119afe0dc64f9c0666745bc8 (patch)
tree9aacd018c8475ddf5a93be7ee18f4cf1c627bb5e /tools/perf/scripts/python/task-analyzer.py
parentefc5f7a9f3d887ce44b7610bc39388094b6f97d5 (diff)
downloadlinux-0d1120b9bbe48a2d119afe0dc64f9c0666745bc8.tar.xz
xfs: remove most in-flight buffer accounting
The buffer cache keeps a bt_io_count per-CPU counter to track all in-flight I/O, which is used to ensure no I/O is in flight when unmounting the file system. For most I/O we already keep track of inflight I/O at higher levels: - for synchronous I/O (xfs_buf_read/xfs_bwrite/xfs_buf_delwri_submit), the caller has a reference and waits for I/O completions using xfs_buf_iowait - for xfs_buf_delwri_submit_nowait the only caller (AIL writeback) tracks the log items that the buffer attached to This only leaves only xfs_buf_readahead_map as a submitter of asynchronous I/O that is not tracked by anything else. Replace the bt_io_count per-cpu counter with a more specific bt_readahead_count counter only tracking readahead I/O. This allows to simply increment it when submitting readahead I/O and decrementing it when it completed, and thus simplify xfs_buf_rele and remove the needed for the XBF_NO_IOACCT flags and the XFS_BSTATE_IN_FLIGHT buffer state. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Carlos Maiolino <cem@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions