summaryrefslogtreecommitdiff
path: root/include/linux/memory_hotplug.h
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2025-10-17 19:07:22 +0300
committerDavid Sterba <dsterba@suse.com>2025-11-25 00:09:46 +0300
commit4ddb077378aa84d0872fdfce85e7a82fd805ee86 (patch)
tree7c8b9df591c9729699b0b85035d35852b76b2991 /include/linux/memory_hotplug.h
parent8ab2b8bdbecaaf1b01adc5cfc13534a04917515d (diff)
downloadlinux-4ddb077378aa84d0872fdfce85e7a82fd805ee86.tar.xz
btrfs: shorten critical section in btrfs_preempt_reclaim_metadata_space()
We are doing a lot of small calculations and assignments while holding the space_info's spinlock, which is a heavily used lock for space reservation and flushing. There's no point in holding the lock for so long when all we want is to call need_preemptive_reclaim() and get a consistent value for a couple of counters from the space_info. Instead, grab the counters into local variables, release the lock and then use the local variables. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'include/linux/memory_hotplug.h')
0 files changed, 0 insertions, 0 deletions