From patchwork Fri Apr 8 20:29:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 8786121 Return-Path: X-Original-To: patchwork-qemu-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 4E030C0553 for ; Fri, 8 Apr 2016 20:57:19 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id AA9F520222 for ; Fri, 8 Apr 2016 20:57:18 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0E86320218 for ; Fri, 8 Apr 2016 20:57:18 +0000 (UTC) Received: from localhost ([::1]:58283 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aodSv-0008Hj-Gb for patchwork-qemu-devel@patchwork.kernel.org; Fri, 08 Apr 2016 16:57:17 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40114) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aod2V-0004rU-Ss for qemu-devel@nongnu.org; Fri, 08 Apr 2016 16:30:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aod2U-0002CR-Uk for qemu-devel@nongnu.org; Fri, 08 Apr 2016 16:29:59 -0400 Received: from mail-wm0-x241.google.com ([2a00:1450:400c:c09::241]:36510) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aod2U-0002CL-MR for qemu-devel@nongnu.org; Fri, 08 Apr 2016 16:29:58 -0400 Received: by mail-wm0-x241.google.com with SMTP id l6so6826113wml.3 for ; Fri, 08 Apr 2016 13:29:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:subject:date:message-id:in-reply-to:references; bh=QiJuC6pEdZlv3KkKokFbODTsmH3HK8wHoI94EGXSmlU=; b=dKMeXBiZpvFJ0WOfi1LRfR8YPnYaMZjE/qBbU/Nps/Lc0S+QREQClOgayLeeiYwQcT O+YKrDscNvRnXI2FgKHY0ulJRGfaWVy0gSSZW39rYd2SQTt+CwPQAKwhyZgEvywp0zyl xGQuOTOKO5I8+qu9ce+J6aHYJtkLXxsuK2TBLOLl3eFmYHlUWDb7aUdYJpWln57Dhwpc 8oYgUDAUAOQnwLSlDH6Wi8282tuK0WKgR8N+sH3NRJYgP7xncypoLoeHLMPOkCSM9vN6 bEuozhfyHVgXxKYRtqWM8rUh/lzbfslsEQctIeklMQgfY/510OtN8c38fGZG5DAUVj0c sRFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references; bh=QiJuC6pEdZlv3KkKokFbODTsmH3HK8wHoI94EGXSmlU=; b=V2B/pbxE3oQXjoOQNU/FXka1iZvFGH0RYL/rtx2KIGer8ySNYeh4GV0+tN7XsIdMKG iYKJMTpO4EOGqhbAmvS77MnPguJEl14BdrE91jvEXisas+rhzfhlHBgF4wWwZ2QxQiGf 2+jpMsJOpRLQAyHBxApMgGE/SDZXhiR3l+lQ94NLjTF1PtLGoOBcfZbDrQI4SlUkrHR7 m/cu2/v9PU/f1LDimbL4Op2+/gsxcPAWlnBkh459+Hu3XSJUsXEYUnwIdRk3qgykR5r3 d9o5pGstuRJs/goTM08csCRtvr7SegDy0IahCMtqGphf8Q8mQHrujbEPqDwS+jXTul6j QjSQ== X-Gm-Message-State: AD7BkJLg3p3Vl2M0PL8RDekunAfudJfRhjyz3ZjRJuXQ5HMus4ZytCcAk6e/qQhA4+Wbig== X-Received: by 10.28.50.138 with SMTP id y132mr6091559wmy.52.1460147398176; Fri, 08 Apr 2016 13:29:58 -0700 (PDT) Received: from 640k.lan (94-39-141-76.adsl-ull.clienti.tiscali.it. [94.39.141.76]) by smtp.gmail.com with ESMTPSA id w10sm3849168wjz.9.2016.04.08.13.29.57 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 08 Apr 2016 13:29:57 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Fri, 8 Apr 2016 22:29:04 +0200 Message-Id: <1460147350-7601-45-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1460147350-7601-1-git-send-email-pbonzini@redhat.com> References: <1460147350-7601-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::241 Subject: [Qemu-devel] [PATCH 44/50] arm: move arm_log_exception into .c file X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Avoid need for qemu/log.h inclusion, and make the function static too. Signed-off-by: Paolo Bonzini Reviewed-by: Alex Bennée --- target-arm/helper.c | 15 +++++++++++++++ target-arm/internals.h | 15 --------------- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/target-arm/helper.c b/target-arm/helper.c index 09638b2..41abdff 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -5815,6 +5815,21 @@ static void do_v7m_exception_exit(CPUARMState *env) pointer. */ } +static void arm_log_exception(int idx) +{ + if (qemu_loglevel_mask(CPU_LOG_INT)) { + const char *exc = NULL; + + if (idx >= 0 && idx < ARRAY_SIZE(excnames)) { + exc = excnames[idx]; + } + if (!exc) { + exc = "unknown"; + } + qemu_log_mask(CPU_LOG_INT, "Taking exception %d [%s]\n", idx, exc); + } +} + void arm_v7m_cpu_do_interrupt(CPUState *cs) { ARMCPU *cpu = ARM_CPU(cs); diff --git a/target-arm/internals.h b/target-arm/internals.h index 2e70272..c484700 100644 --- a/target-arm/internals.h +++ b/target-arm/internals.h @@ -72,21 +72,6 @@ static const char * const excnames[] = { [EXCP_SEMIHOST] = "Semihosting call", }; -static inline void arm_log_exception(int idx) -{ - if (qemu_loglevel_mask(CPU_LOG_INT)) { - const char *exc = NULL; - - if (idx >= 0 && idx < ARRAY_SIZE(excnames)) { - exc = excnames[idx]; - } - if (!exc) { - exc = "unknown"; - } - qemu_log_mask(CPU_LOG_INT, "Taking exception %d [%s]\n", idx, exc); - } -} - /* Scale factor for generic timers, ie number of ns per tick. * This gives a 62.5MHz timer. */