From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E37DBC433EF for ; Wed, 27 Oct 2021 18:57:57 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5EE3D6023E for ; Wed, 27 Oct 2021 18:57:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 5EE3D6023E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 105A483538; Wed, 27 Oct 2021 20:57:54 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.b="NJdgG0XO"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DAAFC82EEC; Wed, 27 Oct 2021 20:57:21 +0200 (CEST) Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id A116A83556 for ; Wed, 27 Oct 2021 20:57:12 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=kabel@kernel.org Received: by mail.kernel.org (Postfix) with ESMTPSA id 355F860E74; Wed, 27 Oct 2021 18:57:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1635361031; bh=VUqSd/FbieUsDRmZV2k3t0ypNA0vN0A7gd3Yk6Prk8c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=NJdgG0XOYW0V4lL5/ojOiCbqoJXiNSr3y6JY3d0OvawqA/4j483yszrqfrjO9557K g7HFBo0XhdeQ3lEsIXGtD/Q6qVVIz7SJ6ZJJYEb4z71W4/0HrGMq5VBNukNvFstDSM BWOxEbso/uozA0E3RWbUf8v89EeoeIcf3cUXXuDzEVUwQD/v/CSp9g3wrhllSuNUo9 yBcjfWKXFl/lSyn48S11Mbuk1FjumucNvT5cWyiQS/W3z4Wul32/IROGZ1ivAg+gtq VXSXYQoUHhsY/J/8aMGp89HJ8N4gvr06XbpUHSYxEBHwIZwsoJwfeBZ4H3MQ88aZ/K SGTXdxsSfXl8g== From: =?UTF-8?q?Marek=20Beh=C3=BAn?= To: Stefan Roese Cc: u-boot@lists.denx.de, =?UTF-8?q?Pali=20Roh=C3=A1r?= , =?UTF-8?q?Marek=20Beh=C3=BAn?= Subject: [PATCH u-boot-marvell 4/5] tools: kwboot: Replace ARM mov + movt instruction pair by mov + orr Date: Wed, 27 Oct 2021 20:57:01 +0200 Message-Id: <20211027185702.8186-5-kabel@kernel.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211027185702.8186-1-kabel@kernel.org> References: <20211027185702.8186-1-kabel@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean From: Pali Rohár Older Armada SoCs have custom ARMv5te compatible core which does not support movt instruction. So replace mov + movt instruction pair used for immediate move construction by mov + orr instructions which are supported also by ARMv5te. After this change kwboot ARM code should be compatible with any 32-bit ARM core compatible by ARMv2 or new. At least GNU AS does not throw any error or warning. Signed-off-by: Pali Rohár Reviewed-by: Marek Behún --- tools/kwboot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/kwboot.c b/tools/kwboot.c index 84294cadfe..62c218ef64 100644 --- a/tools/kwboot.c +++ b/tools/kwboot.c @@ -126,8 +126,8 @@ static unsigned char kwboot_baud_code[] = { 0xfe, 0x5f, 0x2d, 0xe9, /* push { r1 - r12, lr } */ /* ; r0 = UART_BASE */ - 0x02, 0x0a, 0xa0, 0xe3, /* mov r0, #0x2000 */ - 0x01, 0x00, 0x4d, 0xe3, /* movt r0, #0xd001 */ + 0x0d, 0x02, 0xa0, 0xe3, /* mov r0, #0xd0000000 */ + 0x12, 0x0a, 0x80, 0xe3, /* orr r0, r0, #0x12000 */ /* ; r2 = address of preamble string */ 0xcc, 0x20, 0x8f, 0xe2, /* adr r2, preamble */ -- 2.32.0