From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40799) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VEEZS-0006c1-GS for qemu-devel@nongnu.org; Tue, 27 Aug 2013 04:24:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VEEZM-0004QI-Dt for qemu-devel@nongnu.org; Tue, 27 Aug 2013 04:24:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50211) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VEEZM-0004Q0-5q for qemu-devel@nongnu.org; Tue, 27 Aug 2013 04:24:08 -0400 From: Stefan Hajnoczi Date: Tue, 27 Aug 2013 10:23:57 +0200 Message-Id: <1377591839-2743-1-git-send-email-stefanha@redhat.com> Subject: [Qemu-devel] [PATCH v2 0/2] qemu-timer: make qemu_timer_mod_ns() and qemu_timer_del() thread-safe List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Ping Fan Liu , Stefan Hajnoczi , Alex Bligh v2: * Rebased onto qemu.git/master following the merge of Alex's AioContext timers The purpose of these patches is to eventually allow device models to set and cancel timers without holding the global mutex. When the device model runs in a vcpu thread and the iothread processes timers, the QEMUTimerList->active_timers must be protected from concurrent access. Patch 1 is a clean-up. Patch 2 is the entire change needed to protect ->active_timers. Stefan Hajnoczi (2): qemu-timer: drop outdated signal safety comments qemu-timer: make qemu_timer_mod_ns() and qemu_timer_del() thread-safe include/qemu/timer.h | 17 +++++++++++++ qemu-timer.c | 70 ++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 69 insertions(+), 18 deletions(-) -- 1.8.3.1