On 12/10/20 22:23, Claudio Fontana wrote: > On 10/12/20 10:07 PM, Jason Andryuk wrote: >> Move and rename accel/qtest/qtest-cpu.* files to accel/dummy/ so they >> can be re-used by Xen. >> >> Signed-off-by: Jason Andryuk <jandr...@gmail.com> >> --- >> .../qtest-cpus.c => dummy/dummy-cpus.c} | 22 +++++-------------- >> .../qtest-cpus.h => dummy/dummy-cpus.h} | 10 ++++----- >> accel/dummy/meson.build | 6 +++++ >> accel/meson.build | 1 + >> accel/qtest/meson.build | 1 - >> accel/qtest/qtest.c | 7 +++++- >> 6 files changed, 23 insertions(+), 24 deletions(-) >> rename accel/{qtest/qtest-cpus.c => dummy/dummy-cpus.c} (76%) >> rename accel/{qtest/qtest-cpus.h => dummy/dummy-cpus.h} (59%) >> create mode 100644 accel/dummy/meson.build
Maybe accel/dummy-cpus.c, no need to add a new directory. >> diff --git a/accel/qtest/qtest.c b/accel/qtest/qtest.c >> index 537e8b449c..ac54bc8f52 100644 >> --- a/accel/qtest/qtest.c >> +++ b/accel/qtest/qtest.c >> @@ -25,7 +25,12 @@ >> #include "qemu/main-loop.h" >> #include "hw/core/cpu.h" >> >> -#include "qtest-cpus.h" >> +#include "accel/dummy/dummy-cpus.h" > > this is a bit strange from my perspective, does not look right. > > Maybe this dummy cpu prototype should be somewhere in include/ , > like include/sysemu/cpus.h or even better include/sysemu/accel.h Yes, it should be in include/sysemu/cpus.h. Paolo >> + >> +const CpusAccel qtest_cpus = { >> + .create_vcpu_thread = dummy_start_vcpu_thread, >> + .get_virtual_clock = qtest_get_virtual_clock, >> +}; >> >> static int qtest_init_accel(MachineState *ms) >> { >> >