Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit accd4f36 authored by Eric Dumazet's avatar Eric Dumazet Committed by Tejun Heo
Browse files

percpu: add a schedule point in pcpu_balance_workfn()



When a large BPF percpu map is destroyed, I have seen
pcpu_balance_workfn() holding cpu for hundreds of milliseconds.

On KASAN config and 112 hyperthreads, average time to destroy a chunk
is ~4 ms.

[ 2489.841376] destroy chunk 1 in 4148689 ns
...
[ 2490.093428] destroy chunk 32 in 4072718 ns

Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent 554fef1c
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1610,6 +1610,7 @@ static void pcpu_balance_workfn(struct work_struct *work)
			spin_unlock_irq(&pcpu_lock);
		}
		pcpu_destroy_chunk(chunk);
		cond_resched();
	}

	/*