From patchwork Wed May 4 12:09:34 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Graf X-Patchwork-Id: 94014 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 154B31007EA for ; Wed, 4 May 2011 22:10:26 +1000 (EST) Received: from localhost ([::1]:33606 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHauL-0005Sa-JO for incoming@patchwork.ozlabs.org; Wed, 04 May 2011 08:10:21 -0400 Received: from eggs.gnu.org ([140.186.70.92]:41749) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHato-0005Nb-7Y for qemu-devel@nongnu.org; Wed, 04 May 2011 08:09:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QHatl-000864-Lt for qemu-devel@nongnu.org; Wed, 04 May 2011 08:09:48 -0400 Received: from cantor2.suse.de ([195.135.220.15]:46103 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QHatl-000856-FS for qemu-devel@nongnu.org; Wed, 04 May 2011 08:09:45 -0400 Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.221.2]) by mx2.suse.de (Postfix) with ESMTP id D082288B6C; Wed, 4 May 2011 14:09:42 +0200 (CEST) From: Alexander Graf To: QEMU-devel Developers Date: Wed, 4 May 2011 14:09:34 +0200 Message-Id: <1304510982-30810-6-git-send-email-agraf@suse.de> X-Mailer: git-send-email 1.7.3.4 In-Reply-To: <1304510982-30810-1-git-send-email-agraf@suse.de> References: <1304510982-30810-1-git-send-email-agraf@suse.de> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4-2.6 X-Received-From: 195.135.220.15 Cc: peter.maydell@linaro.org, jan.kiszka@siemens.com, Aurelien Jarno , Richard Henderson Subject: [Qemu-devel] [PATCH 05/13] s390x: Shift variables in CPUState for memset(0) 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 The default reset handler does a memset(0) until right in between CPU_COMMON. I incorrectly changed that behavior on the s390x port, so let's move the fields in CPUState around to reflect the correct split up to which point memset(0) zeros out everything. Signed-off-by: Alexander Graf --- target-s390x/cpu.h | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/target-s390x/cpu.h b/target-s390x/cpu.h index 00939a3..125b939 100644 --- a/target-s390x/cpu.h +++ b/target-s390x/cpu.h @@ -87,9 +87,12 @@ typedef struct CPUS390XState { int pending_int; ExtQueue ext_queue[MAX_EXT_QUEUE]; + int ext_index; + + CPU_COMMON + /* reset does memset(0) up to here */ - int ext_index; int cpu_num; uint8_t *storage_keys; @@ -98,8 +101,6 @@ typedef struct CPUS390XState { QEMUTimer *tod_timer; QEMUTimer *cpu_timer; - - CPU_COMMON } CPUS390XState; #if defined(CONFIG_USER_ONLY)