qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 3/3] plugins: avoid failing plugin when CPU is inited several


From: Nikolay Igotti
Subject: Re: [PATCH 3/3] plugins: avoid failing plugin when CPU is inited several times
Date: Mon, 20 Apr 2020 19:14:24 +0300

Sure, attached plugin and testcase where it fails.


On Mon, Apr 20, 2020 at 6:08 PM Alex Bennée <address@hidden> wrote:

Peter Maydell <address@hidden> writes:

> On Mon, 20 Apr 2020 at 10:16, Nikolay Igotti <address@hidden> wrote:
>>
>> In linux-user multithreaded scenarious CPU could be inited many times with the same id,
>>
>> so avoid assertions on already present hashtable entry.
>>
>>
>> Signed-off-by: Nikolay Igotti <address@hidden>
>
> Wouldn't it be better to make sure we remove the entry from
> the hashtable when the old thread that was using that CPU
> ID exits, or is that not feasible ?

I'm fairly sure that is exactly what should be happening via
qemu_plugin_vcpu_exit_hook(cpu) which should be a result of the
object_unref(OBJECT(cpu)) in thread exit.

Is there a test vase?

>
> thanks
> -- PMM


--
Alex Bennée

Attachment: counter.c
Description: Binary data

Attachment: test.c
Description: Binary data


reply via email to

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