qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC v3 PATCH 02/45] multi-process: util: Add qemu_thre


From: Jag Raman
Subject: Re: [Qemu-devel] [RFC v3 PATCH 02/45] multi-process: util: Add qemu_thread_cancel() to cancel running thread
Date: Thu, 5 Sep 2019 11:10:06 -0400
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.1



On 9/4/2019 5:11 AM, Daniel P. Berrangé wrote:
On Tue, Sep 03, 2019 at 04:37:28PM -0400, Jagannathan Raman wrote:
qemu_thread_cancel() added to destroy a given running thread.
This will be needed in the following patches.

I don't see anything in the following patches that actually uses
this new function.

That is good though, because it is incredibly difficult to
correctly use pthread_cancel() in such a way that you correctly
release all memory and other resources (file descriptors) owned
by the thread being cancelled.

So this looks like it can thankfully be dropped.

Thanks Daniel. Will drop this in the next revision.
--
Jag



Signed-off-by: John G Johnson <address@hidden>
Signed-off-by: Jagannathan Raman <address@hidden>
Signed-off-by: Elena Ufimtseva <address@hidden>
---
  include/qemu/thread.h    |  1 +
  util/qemu-thread-posix.c | 10 ++++++++++
  2 files changed, 11 insertions(+)

Regards,
Daniel




reply via email to

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