From patchwork Mon Jan 28 00:13:08 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_F=C3=A4rber?= X-Patchwork-Id: 216083 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 17F8E2C0092 for ; Mon, 28 Jan 2013 11:14:29 +1100 (EST) Received: from localhost ([::1]:41428 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TzcMl-0007V0-4D for incoming@patchwork.ozlabs.org; Sun, 27 Jan 2013 19:14:27 -0500 Received: from eggs.gnu.org ([208.118.235.92]:46470) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TzcLu-0005ME-Uf for qemu-devel@nongnu.org; Sun, 27 Jan 2013 19:13:36 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TzcLt-0003KM-M3 for qemu-devel@nongnu.org; Sun, 27 Jan 2013 19:13:34 -0500 Received: from cantor2.suse.de ([195.135.220.15]:36176 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TzcLt-0003KE-Ci for qemu-devel@nongnu.org; Sun, 27 Jan 2013 19:13:33 -0500 Received: from relay1.suse.de (unknown [195.135.220.254]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id C8333A50E4; Mon, 28 Jan 2013 01:13:32 +0100 (CET) From: =?UTF-8?q?Andreas=20F=C3=A4rber?= To: qemu-devel@nongnu.org Date: Mon, 28 Jan 2013 01:13:08 +0100 Message-Id: <1359331989-12528-6-git-send-email-afaerber@suse.de> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1359331989-12528-1-git-send-email-afaerber@suse.de> References: <1359331989-12528-1-git-send-email-afaerber@suse.de> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-Received-From: 195.135.220.15 Cc: Alexander Graf , =?UTF-8?q?Andreas=20F=C3=A4rber?= , Richard Henderson Subject: [Qemu-devel] [PATCH qom-cpu for-1.4 5/6] target-s390x: Mark as unmigratable 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 CPU_SAVE_VERSION was undefined, so "cpu_common" VMState and cpu_{save,load}() were not registered. They were no-ops. Therefore there is no backwards compatibility to keep, so we can mark S390CPU as unmigratable at device level. Signed-off-by: Andreas Färber --- target-s390x/Makefile.objs | 1 - target-s390x/cpu.c | 10 +++++++++- target-s390x/machine.c | 30 ------------------------------ 3 Dateien geändert, 9 Zeilen hinzugefügt(+), 32 Zeilen entfernt(-) delete mode 100644 target-s390x/machine.c diff --git a/target-s390x/Makefile.objs b/target-s390x/Makefile.objs index e728abf..a4a4c1a 100644 --- a/target-s390x/Makefile.objs +++ b/target-s390x/Makefile.objs @@ -1,4 +1,3 @@ obj-y += translate.o helper.o cpu.o interrupt.o obj-y += int_helper.o fpu_helper.o cc_helper.o mem_helper.o misc_helper.o -obj-$(CONFIG_SOFTMMU) += machine.o obj-$(CONFIG_KVM) += kvm.o diff --git a/target-s390x/cpu.c b/target-s390x/cpu.c index 0b68db8..a0c4479 100644 --- a/target-s390x/cpu.c +++ b/target-s390x/cpu.c @@ -26,8 +26,8 @@ #include "cpu.h" #include "qemu-common.h" #include "qemu/timer.h" -#ifndef CONFIG_USER_ONLY #include "hw/hw.h" +#ifndef CONFIG_USER_ONLY #include "sysemu/arch_init.h" #endif @@ -135,13 +135,21 @@ static void s390_cpu_finalize(Object *obj) #endif } +static const VMStateDescription vmstate_s390_cpu = { + .name = "cpu", + .unmigratable = 1, +}; + static void s390_cpu_class_init(ObjectClass *oc, void *data) { S390CPUClass *scc = S390_CPU_CLASS(oc); CPUClass *cc = CPU_CLASS(scc); + DeviceClass *dc = DEVICE_CLASS(oc); scc->parent_reset = cc->reset; cc->reset = s390_cpu_reset; + + dc->vmsd = &vmstate_s390_cpu; } static const TypeInfo s390_cpu_type_info = { diff --git a/target-s390x/machine.c b/target-s390x/machine.c deleted file mode 100644 index 3e79be6..0000000 --- a/target-s390x/machine.c +++ /dev/null @@ -1,30 +0,0 @@ -/* - * QEMU S390x machine definitions - * - * Copyright (c) 2009 Alexander Graf - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, see . - */ - -#include "hw/hw.h" -#include "hw/boards.h" - -void cpu_save(QEMUFile *f, void *opaque) -{ -} - -int cpu_load(QEMUFile *f, void *opaque, int version_id) -{ - return 0; -}