]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
firmware: stratix10-svc: Use kthread_run_on_cpu()
authorFrederic Weisbecker <frederic@kernel.org>
Wed, 11 Dec 2024 15:40:15 +0000 (16:40 +0100)
committerDinh Nguyen <dinguyen@kernel.org>
Tue, 17 Dec 2024 00:30:11 +0000 (18:30 -0600)
Use the proper API instead of open coding it.

Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
Signed-off-by: Dinh Nguyen <dinguyen@kernel.org>
drivers/firmware/stratix10-svc.c

index c5c78b869561b0c1e9602823ad1f501e98e3ce51..3c52cb73237a43aac6984e497d75bab389e3eb9d 100644 (file)
@@ -967,18 +967,15 @@ int stratix10_svc_send(struct stratix10_svc_chan *chan, void *msg)
        /* first client will create kernel thread */
        if (!chan->ctrl->task) {
                chan->ctrl->task =
-                       kthread_create_on_node(svc_normal_to_secure_thread,
-                                             (void *)chan->ctrl,
-                                             cpu_to_node(cpu),
-                                             "svc_smc_hvc_thread");
+                       kthread_run_on_cpu(svc_normal_to_secure_thread,
+                                          (void *)chan->ctrl,
+                                          cpu, "svc_smc_hvc_thread");
                        if (IS_ERR(chan->ctrl->task)) {
                                dev_err(chan->ctrl->dev,
                                        "failed to create svc_smc_hvc_thread\n");
                                kfree(p_data);
                                return -EINVAL;
                        }
-               kthread_bind(chan->ctrl->task, cpu);
-               wake_up_process(chan->ctrl->task);
        }
 
        pr_debug("%s: sent P-va=%p, P-com=%x, P-size=%u\n", __func__,