From nobody Tue Nov 11 05:47:59 2025 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org ARC-Seal: i=1; a=rsa-sha256; t=1569869168; cv=none; d=zoho.com; s=zohoarc; b=XgG4PvqI7nOrPBnd+V9lLBitlsjzVUP4yIfYfdVgeTah2U0rk82WfIK4u1YvP8VSDF17NH/pPm4g15ua+y2zB6OZKvGbb79UJQs7CHM84RbtaT2bFKkbKzf5pcylzspPWbWJzrmHnogNliqQXoxuQf0Y5njuSF1aQ3WJNyu3OtI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1569869168; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To:ARC-Authentication-Results; bh=bLwU3ZAAEev4ZrKRbwZb7wBirDFwcWryWS3PGqZX5Bk=; b=RdRZtpJIgBLLRshnUcC5Y5rvtKVRcZ1OiptVJPT8mYBPTi88vrEkI8BA5KHsMeHnRimbNyGquFjzqtfS6CRJgFQWqX8hINqPFafZJrfc9ER76xjXrxbtbj0e4099BNSzlTqEL9b27EnmoVztH3Q9JF7myocDPaSHcd95+DoIXlE= ARC-Authentication-Results: i=1; mx.zoho.com; spf=none (zoho.com: 192.237.175.120 is neither permitted nor denied by domain of lists.xenproject.org) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1569869168098741.9111792249885; Mon, 30 Sep 2019 11:46:08 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iF0ew-0002Qa-Vi; Mon, 30 Sep 2019 18:44:34 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1iF0ev-0002QV-Ke for xen-devel@lists.xenproject.org; Mon, 30 Sep 2019 18:44:33 +0000 Received: from foss.arm.com (unknown [217.140.110.172]) by localhost (Halon) with ESMTP id 568c7f6c-e3b2-11e9-97fb-bc764e2007e4; Mon, 30 Sep 2019 18:44:30 +0000 (UTC) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 733971597; Mon, 30 Sep 2019 11:44:30 -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 6B7EF3F534; Mon, 30 Sep 2019 11:44:29 -0700 (PDT) X-Inumbo-ID: 568c7f6c-e3b2-11e9-97fb-bc764e2007e4 From: Julien Grall To: xen-devel@lists.xenproject.org Date: Mon, 30 Sep 2019 19:44:25 +0100 Message-Id: <20190930184425.13756-1-julien.grall@arm.com> X-Mailer: git-send-email 2.11.0 Subject: [Xen-devel] [PATCH for-4.13] xen/arm32: head: Fix build when using GAS 2.25.0 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: jgross@suse.com, Stefano Stabellini , Julien Grall , Andrew Cooper , Julien Grall , Volodymyr Babchuk MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" GAS 2.25.0 throws multiple errors when building arm32/head.S: arm32/head.S: Assembler messages: arm32/head.S:452: Error: invalid constant (f7f) after fixup arm32/head.S:453: Error: invalid constant (f7f) after fixup arm32/head.S:495: Error: invalid constant (f7f) after fixup arm32/head.S:510: Error: invalid constant (f7f) after fixup arm32/head.S:514: Error: invalid constant (f7f) after fixup arm32/head.S:516: Error: invalid constant (f7f) after fixup arm32/head.S:633: Error: invalid constant (f7f) after fixup This makes sense because the instruction mov is only able to deal with a specific set of immediate (see "modified immediate constants in ARM instructions"). For any 16-bit immediate, the instruction movw should be used. It looks like newer version of GAS will seemly switch to movw if the immediate does not fit in the immediate encoding for mov. But we should not rely on this. So switch to movw. Fixes: 23dfe48d10 ("xen/arm32: head: Introduce macros to create table and m= apping entry") Reported-by: Andrew Cooper Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini --- xen/arch/arm/arm32/head.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen/arch/arm/arm32/head.S b/xen/arch/arm/arm32/head.S index 2fc312f9e0..e9d356f05c 100644 --- a/xen/arch/arm/arm32/head.S +++ b/xen/arch/arm/arm32/head.S @@ -383,7 +383,7 @@ ENDPROC(cpu_init) ldr r4, =3D\tbl add r4, r4, r10 /* r4 :=3D paddr(\tlb) */ =20 - mov r2, #PT_PT /* r2:r3 :=3D right for linear PT */ + movw r2, #PT_PT /* r2:r3 :=3D right for linear PT */ orr r2, r2, r4 /* + \tlb paddr */ mov r3, #0 =20 @@ -419,7 +419,7 @@ ENDPROC(cpu_init) lsr r4, \phys, #THIRD_SHIFT lsl r4, r4, #THIRD_SHIFT /* r4 :=3D PAGE_ALIGNED(phys) */ =20 - mov r2, #\type /* r2:r3 :=3D right for section PT */ + movw r2, #\type /* r2:r3 :=3D right for section PT */ orr r2, r2, r4 /* + PAGE_ALIGNED(phys) */ mov r3, #0 =20 --=20 2.11.0 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel