From patchwork Wed Oct 31 18:13:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 149858 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp7127088ljp; Wed, 31 Oct 2018 11:16:03 -0700 (PDT) X-Google-Smtp-Source: AJdET5cVKTTMXFhkQeij+Gff8+u+8lLsjrl99bIWEf3kh+aKm3pGAUC1rsPf6Cw1rsNA5dJOogNa X-Received: by 2002:a81:9301:: with SMTP id k1-v6mr4192992ywg.507.1541009763633; Wed, 31 Oct 2018 11:16:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1541009763; cv=none; d=google.com; s=arc-20160816; b=qCIqAkaIAppA2kgMe4ugRiR7BSB/z/LKxiJfZJXvf4pP89H3bVWwZ7l2hap5qtWj1V E3JCOC2IFVlX7Doa8vBkunyL5C08b0P585LTACc5HOiuek3BpgMZOVUuada5itXwp6+P zVLCPxmWZfDKwY6eBM/rDeJTsvpd6qVyRKN5V+VffNXEarWPn1rIH5og2LK6uST94EIa snVOC6icqDUHOfI/jN0aVQ1BvCV3AYWIXQANunFkJSUK4We5z/8Ho6a3/shrowPrF+2W kIn79fxZACyfdy2HoPTOXmpCkFkCIM+8E7eNHcZ7IhLa7+EkPZybu7IOzkE93Pqf4O4l Oe7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc :list-subscribe:list-help:list-post:list-unsubscribe:list-id :precedence:subject:references:in-reply-to:message-id:date:to:from; bh=YZwE6okKBbUdwGJPcdn393QdYQcJYZfxS/voaZapgH4=; b=bc91wEz3JBb+rHKk7e0EPcEyN4ErexHAyotUsZNcRfgXa0gA8YpxrSqZpFKcgLM96n 3edLseGakXMtHx+z3KqQH1293/d0ig8xCj0YaTPb4PegHTsBkmBK80SndNc5m40j2Qij XLO97xmgylvmlEpD/57fdsULiSHhKZZqVO9xK6V0WxuwwJDtELY+bsAvH67qenIa1hv8 H6aNQjLOFXoXtpEVqR51vYBXP08w6DB7RVY6nZ13qZO/BkpO1rRs0kr7r5Sn8A0UtTF5 JMFBQweXrLOBR9N7sISCtrKPKWqXCqqjkRgyL1MCHXOnH39gEMlpKNU0SlGRojjjAFcM FptA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id m68-v6si11126179yba.320.2018.10.31.11.16.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 31 Oct 2018 11:16:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1gHuzn-0004SJ-Ud; Wed, 31 Oct 2018 18:13:35 +0000 Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1gHuzm-0004QV-2X for xen-devel@lists.xen.org; Wed, 31 Oct 2018 18:13:34 +0000 X-Inumbo-ID: ad84f474-dd38-11e8-b347-12d6303a7972 Received: from foss.arm.com (unknown [217.140.101.70]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTP id ad84f474-dd38-11e8-b347-12d6303a7972; Wed, 31 Oct 2018 18:13:33 +0000 (UTC) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 20BCF80D; Wed, 31 Oct 2018 11:13:33 -0700 (PDT) Received: from e108454-lin.cambridge.arm.com (e108454-lin.cambridge.arm.com [10.1.196.50]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 358643F6A8; Wed, 31 Oct 2018 11:13:32 -0700 (PDT) From: Julien Grall To: xen-devel@lists.xen.org Date: Wed, 31 Oct 2018 18:13:03 +0000 Message-Id: <20181031181313.8028-12-julien.grall@arm.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20181031181313.8028-1-julien.grall@arm.com> References: <20181031181313.8028-1-julien.grall@arm.com> Subject: [Xen-devel] [PATCH v2 11/21] xen/arm: Move out of processor.h traps related variable/function X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Julien Grall , sstabellini@kernel.org, andrii_anisov@epam.com MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" do_unexpected_traps() is moved to traps.h while init_traps() and hyp_traps_vectors() are moved to setup.h. Signed-off-by: Julien Grall Reviewed-by: Andrii Anisov --- Changes in v2: - Rebase - Add Andrii's reviewed-by --- xen/include/asm-arm/processor.h | 7 ------- xen/include/asm-arm/setup.h | 3 +++ xen/include/asm-arm/traps.h | 3 +++ 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/xen/include/asm-arm/processor.h b/xen/include/asm-arm/processor.h index b64ea4e8e4..72ddc42778 100644 --- a/xen/include/asm-arm/processor.h +++ b/xen/include/asm-arm/processor.h @@ -453,10 +453,6 @@ extern register_t __cpu_logical_map[]; #endif #ifndef __ASSEMBLY__ -extern uint32_t hyp_traps_vector[]; - -void init_traps(void); - void panic_PAR(uint64_t par); void show_execution_state(const struct cpu_user_regs *regs); @@ -470,9 +466,6 @@ void show_registers(const struct cpu_user_regs *regs); #define cpu_to_core(_cpu) (0) #define cpu_to_socket(_cpu) (0) -void noreturn do_unexpected_trap(const char *msg, - const struct cpu_user_regs *regs); - struct vcpu; void vcpu_regs_hyp_to_user(const struct vcpu *vcpu, struct vcpu_guest_core_regs *regs); diff --git a/xen/include/asm-arm/setup.h b/xen/include/asm-arm/setup.h index 5f41ba0cba..11e1b2aacf 100644 --- a/xen/include/asm-arm/setup.h +++ b/xen/include/asm-arm/setup.h @@ -83,6 +83,9 @@ struct bootmodule *add_boot_module(bootmodule_kind kind, struct bootmodule *boot_module_find_by_kind(bootmodule_kind kind); const char *boot_module_kind_as_string(bootmodule_kind kind); +extern uint32_t hyp_traps_vector[]; +void init_traps(void); + #endif /* * Local variables: diff --git a/xen/include/asm-arm/traps.h b/xen/include/asm-arm/traps.h index 589fba9cd0..6d8a43a691 100644 --- a/xen/include/asm-arm/traps.h +++ b/xen/include/asm-arm/traps.h @@ -46,6 +46,9 @@ void do_trap_hvc_smccc(struct cpu_user_regs *regs); int do_bug_frame(const struct cpu_user_regs *regs, vaddr_t pc); +void noreturn do_unexpected_trap(const char *msg, + const struct cpu_user_regs *regs); + /* Functions for pending virtual abort checking window. */ void abort_guest_exit_start(void); void abort_guest_exit_end(void);