qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 11/18] accel/tcg: Unify user implementations of qemu_cpu_kick()


From: Ilya Leoshkevich
Subject: [PATCH 11/18] accel/tcg: Unify user implementations of qemu_cpu_kick()
Date: Mon, 23 Sep 2024 18:13:06 +0200

linux-user and bsd-user have the same implementation.
Move it to user-exec.c.

Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com>
---
 accel/tcg/user-exec.c | 5 +++++
 bsd-user/main.c       | 5 -----
 linux-user/main.c     | 5 -----
 3 files changed, 5 insertions(+), 10 deletions(-)

diff --git a/accel/tcg/user-exec.c b/accel/tcg/user-exec.c
index d56882c87f3..7bd6e94b8e8 100644
--- a/accel/tcg/user-exec.c
+++ b/accel/tcg/user-exec.c
@@ -1302,3 +1302,8 @@ int cpu_exec_user(CPUState *cs)
 
     return trapnr;
 }
+
+void qemu_cpu_kick(CPUState *cpu)
+{
+    cpu_exit(cpu);
+}
diff --git a/bsd-user/main.c b/bsd-user/main.c
index ba5b54c228d..b424a21f643 100644
--- a/bsd-user/main.c
+++ b/bsd-user/main.c
@@ -208,11 +208,6 @@ bool qemu_cpu_is_self(CPUState *cpu)
     return thread_cpu == cpu;
 }
 
-void qemu_cpu_kick(CPUState *cpu)
-{
-    cpu_exit(cpu);
-}
-
 /* Assumes contents are already zeroed.  */
 static void init_task_state(TaskState *ts)
 {
diff --git a/linux-user/main.c b/linux-user/main.c
index 016f60bf3dc..60091cf3053 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -186,11 +186,6 @@ bool qemu_cpu_is_self(CPUState *cpu)
     return thread_cpu == cpu;
 }
 
-void qemu_cpu_kick(CPUState *cpu)
-{
-    cpu_exit(cpu);
-}
-
 void task_settid(TaskState *ts)
 {
     if (ts->ts_tid == 0) {
-- 
2.46.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]