Commit c2e42dd
bpf, cpumask: Clean up bpf_cpu_map_entry directly in cpu_map_free
After synchronous_rcu(), both the dettached XDP program and
xdp_do_flush() are completed, and the only user of bpf_cpu_map_entry
will be cpu_map_kthread_run(), so instead of calling
__cpu_map_entry_replace() to stop kthread and cleanup entry after a RCU
grace period, do these things directly.
Signed-off-by: Hou Tao <houtao1@huawei.com>
Reviewed-by: Toke Høiland-Jørgensen <toke@redhat.com>
Link: https://lore.kernel.org/r/20230816045959.358059-3-houtao@huaweicloud.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>1 parent 8f8500a commit c2e42dd
1 file changed
Lines changed: 8 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
566 | 566 | | |
567 | 567 | | |
568 | 568 | | |
569 | | - | |
570 | | - | |
571 | | - | |
572 | | - | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
573 | 573 | | |
574 | | - | |
575 | 574 | | |
576 | 575 | | |
577 | | - | |
578 | | - | |
| 576 | + | |
| 577 | + | |
579 | 578 | | |
580 | 579 | | |
581 | 580 | | |
| |||
584 | 583 | | |
585 | 584 | | |
586 | 585 | | |
587 | | - | |
588 | | - | |
| 586 | + | |
| 587 | + | |
589 | 588 | | |
590 | 589 | | |
591 | 590 | | |
| |||
0 commit comments