From patchwork Thu Apr 3 16:24:12 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ian Campbell X-Patchwork-Id: 27693 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pb0-f72.google.com (mail-pb0-f72.google.com [209.85.160.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 54EE420490 for ; Thu, 3 Apr 2014 16:26:37 +0000 (UTC) Received: by mail-pb0-f72.google.com with SMTP id jt11sf7406964pbb.3 for ; Thu, 03 Apr 2014 09:26:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:message-id:from:to:date:in-reply-to :references:organization:mime-version:cc:subject:precedence:list-id :list-unsubscribe:list-post:list-help:list-subscribe:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:list-archive:content-type:content-transfer-encoding; bh=nwws6F3MDbFIZ78xnwM9HPAmv3aCCIyOPzlvSt1Xix4=; b=iN0cKZWE4ASFmPs6ZIHEzsHdorDG0TzwpI7By0QVlAhbj6p4ycCiLnuwrmH7ujFz9C frnFmEUFWaj8HWjxt2wPnqcdh2OtVlVwDtFgPp+lLj+tApHwVsdEdiWNeMofgRDBDPOz xkE4QOZn0Smoguel6l5TdkiV68FojFhPS0yWFsgvuW75N92SvSJNHy8Wn+3IBSSpYhWa jrNZh3OhsH5qfgJX5bZ6Ju2cBRysn7yFKChi6QV48z1XfI4A1nqKXMkkApS4TkyHltx6 AOuua/8zesKagbmo6sZw9BcYYQrwB0ChLD4tZWlRKkxsC8Y7YGwGV+ExJutW083WKRc2 AOHg== X-Gm-Message-State: ALoCoQkQK/lUdJtn2zrlFUgPeiwrmG6/gxjhYPY3nxnW54UwwTcKBUXTCFDInN1iXdEJQKqWUsCQ X-Received: by 10.68.134.233 with SMTP id pn9mr4453439pbb.5.1396542396547; Thu, 03 Apr 2014 09:26:36 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.47.197 with SMTP id m63ls746590qga.58.gmail; Thu, 03 Apr 2014 09:26:36 -0700 (PDT) X-Received: by 10.58.1.5 with SMTP id 5mr350883vei.8.1396542395991; Thu, 03 Apr 2014 09:26:35 -0700 (PDT) Received: from mail-vc0-f182.google.com (mail-vc0-f182.google.com [209.85.220.182]) by mx.google.com with ESMTPS id r7si1309499vcn.187.2014.04.03.09.26.35 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 03 Apr 2014 09:26:35 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.182; Received: by mail-vc0-f182.google.com with SMTP id ks9so2124632vcb.41 for ; Thu, 03 Apr 2014 09:26:35 -0700 (PDT) X-Received: by 10.221.22.71 with SMTP id qv7mr3467316vcb.34.1396542395855; Thu, 03 Apr 2014 09:26:35 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.12.8 with SMTP id v8csp42165vcv; Thu, 3 Apr 2014 09:26:34 -0700 (PDT) X-Received: by 10.58.34.67 with SMTP id x3mr340845vei.37.1396542391931; Thu, 03 Apr 2014 09:26:31 -0700 (PDT) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id sy7si1321242vdc.46.2014.04.03.09.26.31 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 03 Apr 2014 09:26:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of xen-devel-bounces@lists.xen.org designates 50.57.142.19 as permitted sender) client-ip=50.57.142.19; Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WVkRG-0006xA-9y; Thu, 03 Apr 2014 16:24:26 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WVkRE-0006wv-Ss for xen-devel@lists.xen.org; Thu, 03 Apr 2014 16:24:25 +0000 Received: from [193.109.254.147:51081] by server-10.bemta-14.messagelabs.com id FF/AD-04546-83B8D335; Thu, 03 Apr 2014 16:24:24 +0000 X-Env-Sender: Ian.Campbell@citrix.com X-Msg-Ref: server-4.tower-27.messagelabs.com!1396542259!6134320!1 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n X-StarScan-Received: X-StarScan-Version: 6.11.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 32660 invoked from network); 3 Apr 2014 16:24:21 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-4.tower-27.messagelabs.com with RC4-SHA encrypted SMTP; 3 Apr 2014 16:24:21 -0000 X-IronPort-AV: E=Sophos;i="4.97,788,1389744000"; d="scan'208";a="116503725" Received: from accessns.citrite.net (HELO FTLPEX01CL03.citrite.net) ([10.9.154.239]) by FTLPIPO02.CITRIX.COM with ESMTP; 03 Apr 2014 16:24:14 +0000 Received: from [10.80.2.80] (10.80.2.80) by FTLPEX01CL03.citrite.net (10.13.107.80) with Microsoft SMTP Server id 14.2.342.4; Thu, 3 Apr 2014 12:24:13 -0400 Message-ID: <1396542252.4211.135.camel@kazak.uk.xensource.com> From: Ian Campbell To: Don Slutz Date: Thu, 3 Apr 2014 17:24:12 +0100 In-Reply-To: <1396454623-17104-1-git-send-email-dslutz@verizon.com> References: <1396454623-17104-1-git-send-email-dslutz@verizon.com> Organization: Citrix Systems, Inc. X-Mailer: Evolution 3.8.5-2+b3 MIME-Version: 1.0 X-Originating-IP: [10.80.2.80] X-DLP: MIA1 Cc: George Dunlap , Stefano Stabellini , Ian Jackson , Jan Beulich , xen-devel@lists.xen.org Subject: Re: [Xen-devel] [PATCH v9 00/18] xenctx: Many changes. X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Post: , List-Help: , List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ian.campbell@citrix.com X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Archive: On Wed, 2014-04-02 at 12:03 -0400, Don Slutz wrote: > Add more functionality to xenctx. I had acked and was just about to apply but unfortunately this doesn't build on ARM: xenctx.c: In function ‘print_stack_word’: xenctx.c:762:16: error: ‘FMT_16B_WORD’ undeclared (first use in this function) xenctx.c:762:16: note: each undeclared identifier is reported only once for each function it appears in ARM doesn't have any 16-bit modes so I suppose you could use #ifdef FMT_16B_WORD or just define it for ARM and arm64, %04llx would be correct for both I think. xenctx.c: At top level: xenctx.c:759:13: error: ‘print_stack_word’ defined but not used [-Werror=unused-function] There is an #endif from a NO_TRANSLATION right before print_stack_word and an #ifndef NO_TRANSLATION right after, so I think you can just remove them and incorporate print_stack_word into one big NO_TRANSLATION region. On arm64 there is an additional one compared with arm32: xenctx.c: In function 'usage': xenctx.c:1074:9: error: format '%lx' expects argument of type 'long unsigned int', but argument 2 has type 'long long unsigned int' [-Werror=format=] kernel_start); ^ kernel_addr is an unsigned long long but FMT_64B_WORD is a %#lx on aarch64. I think this is wrong on aarch64 and the patch below makes it right, I think, so if you insert that at the start of your series this one should go away. Unfortunately that last one was from the first patch in the series or I'd have committed at least some of it. Building arm stuff is more faff than I would ask a non-ARM developer to go through, if you want to then [0] is the place to look, otherwise feel free to make a best effort by inspection and I'll try building v10 for you. [0] http://wiki.xen.org/wiki/Xen_ARM_with_Virtualization_Extensions/CrossCompiling Ian. 8<---------------------------------------- >From 1f6bd5e1157d99a1b075d9386410d5a59eb85d69 Mon Sep 17 00:00:00 2001 From: Ian Campbell Date: Thu, 3 Apr 2014 17:13:00 +0100 Subject: [PATCH] xenctx: Correct FMT_??B_WORD for arm64. These should all be unsigned long long to match various variables used in the code, same as x86_64. Signed-off-by: Ian Campbell --- tools/xentrace/xenctx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/xentrace/xenctx.c b/tools/xentrace/xenctx.c index 7275a00..47712ab 100644 --- a/tools/xentrace/xenctx.c +++ b/tools/xentrace/xenctx.c @@ -57,8 +57,8 @@ typedef uint64_t guest_word_t; #elif defined(__aarch64__) #define NO_TRANSLATION typedef uint64_t guest_word_t; -#define FMT_32B_WORD "%08lx" -#define FMT_64B_WORD "%016lx" +#define FMT_32B_WORD "%08llx" +#define FMT_64B_WORD "%016llx" #endif struct symbol {