From patchwork Mon Sep 1 12:54:15 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Borntraeger X-Patchwork-Id: 384811 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 480421401DD for ; Mon, 1 Sep 2014 22:59:24 +1000 (EST) Received: from localhost ([::1]:60124 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XORCc-0001CS-50 for incoming@patchwork.ozlabs.org; Mon, 01 Sep 2014 08:59:22 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58856) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XOR7u-0001cx-FG for qemu-devel@nongnu.org; Mon, 01 Sep 2014 08:54:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XOR7f-000553-NK for qemu-devel@nongnu.org; Mon, 01 Sep 2014 08:54:30 -0400 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:40953) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XOR7f-00054m-DM for qemu-devel@nongnu.org; Mon, 01 Sep 2014 08:54:15 -0400 Received: from /spool/local by e06smtp16.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 1 Sep 2014 13:54:13 +0100 Received: from d06dlp02.portsmouth.uk.ibm.com (9.149.20.14) by e06smtp16.uk.ibm.com (192.168.101.146) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 1 Sep 2014 13:54:11 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (d06relay12.portsmouth.uk.ibm.com [9.149.109.197]) by d06dlp02.portsmouth.uk.ibm.com (Postfix) with ESMTP id 6EC102190046 for ; Mon, 1 Sep 2014 13:53:52 +0100 (BST) Received: from d06av03.portsmouth.uk.ibm.com (d06av03.portsmouth.uk.ibm.com [9.149.37.213]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id s81CsB3U23396480 for ; Mon, 1 Sep 2014 12:54:11 GMT Received: from d06av03.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av03.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s81Cs93f024158 for ; Mon, 1 Sep 2014 06:54:10 -0600 Received: from tuxmaker.boeblingen.de.ibm.com (tuxmaker.boeblingen.de.ibm.com [9.152.85.9]) by d06av03.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id s81Cs9vk024153; Mon, 1 Sep 2014 06:54:09 -0600 Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 275EE122443E; Mon, 1 Sep 2014 14:54:09 +0200 (CEST) From: Christian Borntraeger To: Peter Maydell Date: Mon, 1 Sep 2014 14:54:15 +0200 Message-Id: <1409576070-55803-5-git-send-email-borntraeger@de.ibm.com> X-Mailer: git-send-email 1.8.4.2 In-Reply-To: <1409576070-55803-1-git-send-email-borntraeger@de.ibm.com> References: <1409576070-55803-1-git-send-email-borntraeger@de.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 14090112-3548-0000-0000-0000013698C2 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 195.75.94.112 Cc: Christian Borntraeger , qemu-devel , Alexander Graf , David Hildenbrand , Jens Freimann , Anthony Liguori , Cornelia Huck , Richard Henderson Subject: [Qemu-devel] [PULL 04/19] s390x/kvm: execute the first cpu reset on the vcpu thread X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: David Hildenbrand As all full cpu resets currently call into the kernel to do initial cpu reset, let's run this reset (triggered by cpu_s390x_init()) on the proper vcpu thread. Reviewed-by: Cornelia Huck Acked-by: Christian Borntraeger Signed-off-by: David Hildenbrand Signed-off-by: Jens Freimann Signed-off-by: Christian Borntraeger --- target-s390x/cpu.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/target-s390x/cpu.c b/target-s390x/cpu.c index 4633282..505a2fa 100644 --- a/target-s390x/cpu.c +++ b/target-s390x/cpu.c @@ -175,7 +175,11 @@ static void s390_cpu_realizefn(DeviceState *dev, Error **errp) S390CPUClass *scc = S390_CPU_GET_CLASS(dev); qemu_init_vcpu(cs); +#if !defined(CONFIG_USER_ONLY) + run_on_cpu(cs, s390_do_cpu_full_reset, cs); +#else cpu_reset(cs); +#endif scc->parent_realize(dev, errp); }