aboutsummaryrefslogtreecommitdiff
path: root/fs/btrfs/tree-mod-log.c
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@kernel.org>2024-08-01 17:43:05 -0700
committerNeeraj Upadhyay <neeraj.upadhyay@kernel.org>2024-08-15 00:14:48 +0530
commit3e3c4f0e2753e92aa2a248d34c6866c0a264ac96 (patch)
tree2a68876c95887d8db67712631a35f2ea3af31c72 /fs/btrfs/tree-mod-log.c
parentabaf1322adbfd4faa28072fd5412e54b9722e477 (diff)
rcuscale: Make rcu_scale_writer() tolerate repeated GFP_KERNEL failure
Under some conditions, kmalloc(GFP_KERNEL) allocations have been observed to repeatedly fail. This situation has been observed to cause one of the rcu_scale_writer() instances to loop indefinitely retrying memory allocation for an asynchronous grace-period primitive. The problem is that if memory is short, all the other instances will allocate all available memory before the looping task is awakened from its rcu_barrier*() call. This in turn results in hangs, so that rcuscale fails to complete. This commit therefore removes the tight retry loop, so that when this condition occurs, the affected task is still passing through the full loop with its full set of termination checks. This spreads the risk of indefinite memory-allocation retry failures across all instances of rcu_scale_writer() tasks, which in turn prevents the hangs. Signed-off-by: "Paul E. McKenney" <paulmck@kernel.org> Signed-off-by: Neeraj Upadhyay <neeraj.upadhyay@kernel.org>
Diffstat (limited to 'fs/btrfs/tree-mod-log.c')
0 files changed, 0 insertions, 0 deletions