From patchwork Wed Jun 24 06:30:19 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Gibson X-Patchwork-Id: 487972 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 763B914031C for ; Wed, 24 Jun 2015 16:46:03 +1000 (AEST) Received: from localhost ([::1]:48899 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7eRd-0004sz-Hy for incoming@patchwork.ozlabs.org; Wed, 24 Jun 2015 02:46:01 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39255) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7eHW-0004Er-0k for qemu-devel@nongnu.org; Wed, 24 Jun 2015 02:35:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z7eHS-0000kD-0T for qemu-devel@nongnu.org; Wed, 24 Jun 2015 02:35:33 -0400 Received: from ozlabs.org ([103.22.144.67]:42701) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7eHR-0000f3-Bw; Wed, 24 Jun 2015 02:35:29 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 103AC14031E; Wed, 24 Jun 2015 16:30:15 +1000 (AEST) From: David Gibson To: agraf@suse.de, afaerber@suse.de Date: Wed, 24 Jun 2015 16:30:19 +1000 Message-Id: <1435127436-28560-6-git-send-email-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1435127436-28560-1-git-send-email-david@gibson.dropbear.id.au> References: <1435127436-28560-1-git-send-email-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 103.22.144.67 Cc: qemu-ppc@nongnu.org, qemu-devel@nongnu.org, David Gibson Subject: [Qemu-devel] [PATCH 05/22] spapr: Remove obsolete entry_point field from sPAPRMachineState 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 sPAPRMachineState structure includes an entry_point field containing the initial PC value for starting the machine, even though this always has the value 0x100. I think this is a hangover from very early versions which bypassed the firmware when using -kernel. In any case it has no function now, so remove it. Signed-off-by: David Gibson --- hw/ppc/spapr.c | 4 +--- include/hw/ppc/spapr.h | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 6adfb68..3aeb2ea 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -932,7 +932,7 @@ static void ppc_spapr_reset(void) first_ppc_cpu->env.gpr[3] = spapr->fdt_addr; first_ppc_cpu->env.gpr[5] = 0; first_cpu->halted = 0; - first_ppc_cpu->env.nip = spapr->entry_point; + first_ppc_cpu->env.nip = SPAPR_ENTRY_POINT; } @@ -1645,8 +1645,6 @@ static void ppc_spapr_init(MachineState *machine) } g_free(filename); - spapr->entry_point = 0x100; - /* FIXME: Should register things through the MachineState's qdev * interface, this is a legacy from the sPAPREnvironment structure * which predated MachineState but had a similar function */ diff --git a/include/hw/ppc/spapr.h b/include/hw/ppc/spapr.h index 9e7cf0f..785b094 100644 --- a/include/hw/ppc/spapr.h +++ b/include/hw/ppc/spapr.h @@ -13,6 +13,7 @@ typedef struct sPAPRConfigureConnectorState sPAPRConfigureConnectorState; typedef struct sPAPREventLogEntry sPAPREventLogEntry; #define HPTE64_V_HPTE_DIRTY 0x0000000000000040ULL +#define SPAPR_ENTRY_POINT 0x100 typedef struct sPAPRMachineState sPAPRMachineState; @@ -41,7 +42,6 @@ struct sPAPRMachineState { ssize_t rtas_size; void *rtas_blob; void *fdt_skel; - target_ulong entry_point; uint64_t rtc_offset; /* Now used only during incoming migration */ struct PPCTimebase tb; bool has_graphics;