From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37293) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3LzO-0004gO-CX for qemu-devel@nongnu.org; Thu, 19 May 2016 07:19:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b3LzM-0004JC-8y for qemu-devel@nongnu.org; Thu, 19 May 2016 07:19:37 -0400 Received: from mail-wm0-x242.google.com ([2a00:1450:400c:c09::242]:35378) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b3LzM-0004Ix-1c for qemu-devel@nongnu.org; Thu, 19 May 2016 07:19:36 -0400 Received: by mail-wm0-x242.google.com with SMTP id s63so5554148wme.2 for ; Thu, 19 May 2016 04:19:35 -0700 (PDT) Received: from 640k.lan (dynamic-adsl-78-12-252-58.clienti.tiscali.it. [78.12.252.58]) by smtp.gmail.com with ESMTPSA id c7sm8374317wji.38.2016.05.19.04.19.34 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 May 2016 04:19:34 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Thu, 19 May 2016 13:18:40 +0200 Message-Id: <1463656726-35952-47-git-send-email-pbonzini@redhat.com> In-Reply-To: <1463656726-35952-1-git-send-email-pbonzini@redhat.com> References: <1463656726-35952-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PULL 46/52] arm: move arm_log_exception into .c file List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Avoid need for qemu/log.h inclusion, and make the function static too. Reviewed-by: Alex Bennée Signed-off-by: Paolo Bonzini --- 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 a2ab701..d721c0c 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -5819,6 +5819,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 54a0fb1..a125873 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. */ -- 1.8.3.1