From patchwork Tue Sep 23 16:29:29 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Stabellini X-Patchwork-Id: 37747 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f200.google.com (mail-we0-f200.google.com [74.125.82.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C5C0320792 for ; Tue, 23 Sep 2014 16:33:58 +0000 (UTC) Received: by mail-we0-f200.google.com with SMTP id w62sf2048279wes.3 for ; Tue, 23 Sep 2014 09:33:57 -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:date:from:to:in-reply-to:message-id :references:user-agent: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=otBUPTFxVOIyoJxTGMherIBNnP3gx5L3dZt9S6Yo+iY=; b=KKdlZ7g5tWYjWiai+UL/VBirQVYJPEg+jF1RX3pUReOxqlIYVVINSr789E3age1qQa kbtu7uywZ/63p66O2RUvM0/LCL2mT5vjaSydM29XwnqvTul/xE2oz3Dbagez38WiUvlQ d2KNauOJPTRj0bdbN3tg8pGt51YduyLG080J0oftJZTLMuQxktsfZ2Mtv0y6kFAbmsy7 cmxGhwFCmYJkyx/SR5+7WKZyp96S8/fU+jpz92NPP05pLu0jMweIHzfMPti4NGSBEs6+ Z9nxbZS0iw2B7xsMh9F3W709QSndPn9C/uYb2urB3Al12F/oD9hEXvMWw7GLzHt19P3g pJcA== X-Gm-Message-State: ALoCoQk4HRqgpHo4rBMJlcDRQlpjwbZrsX+zJnwVlZwnnTzgkcI5LXEA4a69VOrgDj0iAi5DazxA X-Received: by 10.112.137.230 with SMTP id ql6mr122200lbb.13.1411490037656; Tue, 23 Sep 2014 09:33:57 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.206.72 with SMTP id lm8ls70958lac.9.gmail; Tue, 23 Sep 2014 09:33:57 -0700 (PDT) X-Received: by 10.112.89.68 with SMTP id bm4mr708102lbb.90.1411490037483; Tue, 23 Sep 2014 09:33:57 -0700 (PDT) Received: from mail-lb0-f177.google.com (mail-lb0-f177.google.com [209.85.217.177]) by mx.google.com with ESMTPS id g1si19381007lam.75.2014.09.23.09.33.57 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 23 Sep 2014 09:33:57 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.177 as permitted sender) client-ip=209.85.217.177; Received: by mail-lb0-f177.google.com with SMTP id z12so9097716lbi.36 for ; Tue, 23 Sep 2014 09:33:57 -0700 (PDT) X-Received: by 10.152.179.226 with SMTP id dj2mr838503lac.40.1411490037391; Tue, 23 Sep 2014 09:33:57 -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.112.130.169 with SMTP id of9csp446591lbb; Tue, 23 Sep 2014 09:33:56 -0700 (PDT) X-Received: by 10.220.105.148 with SMTP id t20mr514829vco.11.1411490036225; Tue, 23 Sep 2014 09:33:56 -0700 (PDT) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id p9si2655753vda.64.2014.09.23.09.33.55 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 23 Sep 2014 09:33:56 -0700 (PDT) Received-SPF: none (google.com: xen-devel-bounces@lists.xen.org does not designate permitted sender hosts) 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 1XWT02-00031s-5q; Tue, 23 Sep 2014 16:31:34 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XWT00-00031Q-EX for xen-devel@lists.xensource.com; Tue, 23 Sep 2014 16:31:32 +0000 Received: from [85.158.137.68:33586] by server-10.bemta-3.messagelabs.com id 42/00-01456-360A1245; Tue, 23 Sep 2014 16:31:31 +0000 X-Env-Sender: Stefano.Stabellini@citrix.com X-Msg-Ref: server-9.tower-31.messagelabs.com!1411489889!7847671!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.12.2; banners=-,-,- X-VirusChecked: Checked Received: (qmail 14021 invoked from network); 23 Sep 2014 16:31:30 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-9.tower-31.messagelabs.com with RC4-SHA encrypted SMTP; 23 Sep 2014 16:31:30 -0000 X-IronPort-AV: E=Sophos;i="5.04,581,1406592000"; d="scan'208";a="175373849" Received: from ukmail1.uk.xensource.com (10.80.16.128) by smtprelay.citrix.com (10.13.107.78) with Microsoft SMTP Server id 14.3.181.6; Tue, 23 Sep 2014 12:31:28 -0400 Received: from kaball.uk.xensource.com ([10.80.2.59]) by ukmail1.uk.xensource.com with esmtp (Exim 4.69) (envelope-from ) id 1XWSzv-0002UM-Um; Tue, 23 Sep 2014 17:31:27 +0100 Date: Tue, 23 Sep 2014 17:29:29 +0100 From: Stefano Stabellini X-X-Sender: sstabellini@kaball.uk.xensource.com To: Ian Campbell In-Reply-To: <1411485706.1781.61.camel@kazak.uk.xensource.com> Message-ID: References: <1406907139-16800-3-git-send-email-stefano.stabellini@eu.citrix.com> <1411479334.1781.44.camel@kazak.uk.xensource.com> <1411485706.1781.61.camel@kazak.uk.xensource.com> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 X-DLP: MIA2 Cc: xen-devel@lists.xensource.com, Ian.Jackson@eu.citrix.com, Stefano Stabellini Subject: Re: [Xen-devel] [PATCH v4 3/3] enable QEMU for ARM builds 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: stefano.stabellini@eu.citrix.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.177 as permitted sender) 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 Tue, 23 Sep 2014, Ian Campbell wrote: > On Tue, 2014-09-23 at 15:56 +0100, Stefano Stabellini wrote: > > Does the following fix the issue for you? > > I needed some new build-deps (pixman) but then it appeared to, yes. > > I'm in favour of moving the --cpu out from under the > IOEMU_CONFIGURE_CROSS and into the normal configure rune. It should be > harmless for native builds and will ensure that cross builds don't > regress again. Maybe that is more complex with the qemu-trad side of > things? I don't think so: qemu-trad is not used on arm or arm64. I think that the x86_32 tools build on x86_64 still has some other issues but this should be an improvement. Acked-by: Ian Campbell --- Fix QEMU cross-compile build Introduce the per-arch IOEMU_CPU_ARCH variable. Always pass --configure=IOEMU_CPU_ARCH to QEMU's configure script. Signed-off-by: Stefano Stabellini diff --git a/config/arm32.mk b/config/arm32.mk index aa79d22..5f056bd 100644 --- a/config/arm32.mk +++ b/config/arm32.mk @@ -18,3 +18,6 @@ HAS_NS16550 := y LDFLAGS_DIRECT += -EL CONFIG_LOAD_ADDRESS ?= 0x80000000 + +#QEMU CPU arch +IOEMU_CPU_ARCH ?= arm diff --git a/config/arm64.mk b/config/arm64.mk index 15b57a4..f42ffe0 100644 --- a/config/arm64.mk +++ b/config/arm64.mk @@ -13,3 +13,6 @@ HAS_NS16550 := y LDFLAGS_DIRECT += -EL CONFIG_LOAD_ADDRESS ?= 0x80000000 + +#QEMU CPU arch +IOEMU_CPU_ARCH ?= aarch64 diff --git a/config/x86_32.mk b/config/x86_32.mk index 7f76b25..0da63ed 100644 --- a/config/x86_32.mk +++ b/config/x86_32.mk @@ -12,3 +12,6 @@ CFLAGS += -m32 -march=i686 LDFLAGS_DIRECT_OpenBSD = _obsd LDFLAGS_DIRECT_FreeBSD = _fbsd LDFLAGS_DIRECT += -melf_i386$(LDFLAGS_DIRECT_$(XEN_OS)) + +#QEMU CPU arch +IOEMU_CPU_ARCH ?= i386 diff --git a/config/x86_64.mk b/config/x86_64.mk index 11104bd..f5c32a2 100644 --- a/config/x86_64.mk +++ b/config/x86_64.mk @@ -25,3 +25,6 @@ else LDFLAGS_DIRECT += -melf_x86_64 endif endif + +#QEMU CPU arch +IOEMU_CPU_ARCH ?= x86_64 diff --git a/tools/Makefile b/tools/Makefile index 1130369..7b00a70 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -106,8 +106,7 @@ distclean: subdirs-distclean config.cache autom4te.cache ifneq ($(XEN_COMPILE_ARCH),$(XEN_TARGET_ARCH)) -IOEMU_CONFIGURE_CROSS ?= --cpu=$(XEN_TARGET_ARCH) \ - --cross-prefix=$(CROSS_COMPILE) \ +IOEMU_CONFIGURE_CROSS ?= --cross-prefix=$(CROSS_COMPILE) \ --interp-prefix=$(CROSS_SYS_ROOT) endif @@ -146,7 +145,7 @@ subdir-all-qemu-xen-traditional-dir: qemu-xen-traditional-dir-find set -e; \ $(buildmakevars2shellvars); \ cd qemu-xen-traditional-dir; \ - $(QEMU_ROOT)/xen-setup $(IOEMU_CONFIGURE_CROSS); \ + $(QEMU_ROOT)/xen-setup --cpu=$(IOEMU_CPU_ARCH) $(IOEMU_CONFIGURE_CROSS); \ $(MAKE) all subdir-install-qemu-xen-traditional-dir: qemu-xen-traditional-dir-find @@ -155,6 +154,7 @@ subdir-install-qemu-xen-traditional-dir: qemu-xen-traditional-dir-find cd qemu-xen-traditional-dir; \ $(QEMU_ROOT)/xen-setup \ --extra-cflags="$(EXTRA_CFLAGS_QEMU_TRADITIONAL)" \ + --cpu=$(IOEMU_CPU_ARCH) \ $(IOEMU_CONFIGURE_CROSS); \ $(MAKE) install @@ -207,6 +207,7 @@ subdir-all-qemu-xen-dir: qemu-xen-dir-find --disable-guest-agent \ --python=$(PYTHON) \ $(CONFIG_QEMUU_EXTRA_ARGS) \ + --cpu=$(IOEMU_CPU_ARCH) \ $(IOEMU_CONFIGURE_CROSS); \ $(MAKE) all