diff options
| author | Damien Le Moal <dlemoal@kernel.org> | 2026-03-16 20:40:17 +0900 |
|---|---|---|
| committer | Carlos Maiolino <cem@kernel.org> | 2026-03-18 10:08:07 +0100 |
| commit | 770323d418ed5848cc21af172f77377b2cc0542d (patch) | |
| tree | 71e67a27ffce6fa66ea9a693555cf6b26d6d8082 /tools/perf/scripts/python/stackcollapse.py | |
| parent | 01478f356ff794c7676803c7af04eaeaebfbb455 (diff) | |
xfs: avoid unnecessary open zone check in xfs_select_zone_nowait()
When xfs_select_zone_nowait() is called with pack_tight equal to true,
the function xfs_select_open_zone_mru() is called if no open zone is
returned by xfs_select_open_zone_lru(), that is, when oz is NULL. The
open zone pointer return of xfs_select_zone_nowait() is then checked,
but this check is outside of the "if (pack_tight)" that trigered the
call to xfs_select_open_zone_mru(). In other word, this check is
unnecessarily done even when pack_tight is false.
Move the check for the return value of the call to
xfs_select_open_zone_mru() inside the if that controls the call to this
function, so that we do not uselessly test again the value of oz when
pack_tight is false.
No functional changes.
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Hans Holmberg <hans.holmberg@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
