net: pktgen: Use kthread_create_on_cpu()
Subsystems (2)
PATCH 1/1 net: pktgen: Use kthread_create_on_cpu()
Use the proper API instead of open coding it.
Signed-off-by Frederic Weisbecker <[email protected]>
Reviewed-by Eric Dumazet <[email protected]>
--- net/core/pktgen.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
net/core/pktgen.c +2 -5
@@ -3883,17 +3883,14 @@ static int __net_init pktgen_create_thread(int cpu, struct pktgen_net *pn)list_add_tail (&t->th_list, &pn->pktgen_threads);init_completion (&t->start_done); - p =kthread_create_on_node (pktgen_thread_worker, - t, -cpu_to_node (cpu), -"kpktgend_%d" , cpu); + p =kthread_create_on_cpu (pktgen_thread_worker, t, cpu,"kpktgend_%d" );if (IS_ERR (p)) {pr_err ("kthread_create_on_node() failed for cpu %d\n" , t->cpu);list_del (&t->th_list);kfree (t);return PTR_ERR (p); } -kthread_bind (p, cpu); + t->tsk = p; pe = proc_create_data(t->tsk->comm, 0600, pn->proc_dir,
Signature · 1 line
2.46.0
Quoted 4 lines · Frederic Weisbecker
Use the proper API instead of open coding it.
Signed-off-by Frederic Weisbecker <[email protected]>Reviewed-by Eric Dumazet <[email protected]>
Reviewed-by Toke Høiland-Jørgensen <[email protected]>
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Quoted 7 lines · On Mon, 9 Dec 2024 00:49:55 +0100 you wrote:
Use the proper API instead of open coding it.
Signed-off-by Frederic Weisbecker <[email protected]>Reviewed-by Eric Dumazet <[email protected]>--- net/core/pktgen.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
Here is the summary with links:
- net: pktgen: Use kthread_create_on_cpu()
https://git.kernel.org/netdev/net-next/c/33035977b464
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html