From: Russell King - ARM Linux admin <linux@armlinux.org.uk>
To: Stefan Agner <stefan@agner.ch>
Cc: clang-built-linux@googlegroups.com, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] ARM: kexec: drop invalid assembly argument
Date: Wed, 5 Feb 2020 23:54:40 +0000 [thread overview]
Message-ID: <20200205235440.GW25745@shell.armlinux.org.uk> (raw)
In-Reply-To: <ab67c7c5a1f96af6d22240e57fc27ba766d4193d.1580943526.git.stefan@agner.ch>
On Wed, Feb 05, 2020 at 11:59:26PM +0100, Stefan Agner wrote:
> The tst menomic has only a single #<const> argument in Thumb mode. There
> is an ARM variant which allows to write #<const> as #<byte>, #<rot>
> which probably is where the current syntax comes from.
>
> It seems that binutils does not care about the additional parameter.
> Clang however complains in Thumb2 mode:
> arch/arm/kernel/relocate_kernel.S:28:12: error: too many operands for
> instruction
> tst r3,#1,0
> ^
>
> Drop the unnecessary parameter. This fixes building this file in Thumb2
> mode with the Clang integrated assembler.
>
> Link: https://github.com/ClangBuiltLinux/linux/issues/770
> Signed-off-by: Stefan Agner <stefan@agner.ch>
Please drop it in the patch system, thanks.
> ---
> arch/arm/kernel/relocate_kernel.S | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/kernel/relocate_kernel.S b/arch/arm/kernel/relocate_kernel.S
> index 7eaa2ae7aff5..72a08786e16e 100644
> --- a/arch/arm/kernel/relocate_kernel.S
> +++ b/arch/arm/kernel/relocate_kernel.S
> @@ -25,26 +25,26 @@ ENTRY(relocate_new_kernel)
> ldr r3, [r0],#4
>
> /* Is it a destination page. Put destination address to r4 */
> - tst r3,#1,0
> + tst r3,#1
> beq 1f
> bic r4,r3,#1
> b 0b
> 1:
> /* Is it an indirection page */
> - tst r3,#2,0
> + tst r3,#2
> beq 1f
> bic r0,r3,#2
> b 0b
> 1:
>
> /* are we done ? */
> - tst r3,#4,0
> + tst r3,#4
> beq 1f
> b 2f
>
> 1:
> /* is it source ? */
> - tst r3,#8,0
> + tst r3,#8
> beq 0b
> bic r3,r3,#8
> mov r6,#1024
> --
> 2.25.0
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
>
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to speedtest.net: 11.9Mbps down 500kbps up
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Russell King - ARM Linux admin <linux@armlinux.org.uk>
To: Stefan Agner <stefan@agner.ch>
Cc: clang-built-linux@googlegroups.com, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] ARM: kexec: drop invalid assembly argument
Date: Wed, 5 Feb 2020 23:54:40 +0000 [thread overview]
Message-ID: <20200205235440.GW25745@shell.armlinux.org.uk> (raw)
In-Reply-To: <ab67c7c5a1f96af6d22240e57fc27ba766d4193d.1580943526.git.stefan@agner.ch>
On Wed, Feb 05, 2020 at 11:59:26PM +0100, Stefan Agner wrote:
> The tst menomic has only a single #<const> argument in Thumb mode. There
> is an ARM variant which allows to write #<const> as #<byte>, #<rot>
> which probably is where the current syntax comes from.
>
> It seems that binutils does not care about the additional parameter.
> Clang however complains in Thumb2 mode:
> arch/arm/kernel/relocate_kernel.S:28:12: error: too many operands for
> instruction
> tst r3,#1,0
> ^
>
> Drop the unnecessary parameter. This fixes building this file in Thumb2
> mode with the Clang integrated assembler.
>
> Link: https://github.com/ClangBuiltLinux/linux/issues/770
> Signed-off-by: Stefan Agner <stefan@agner.ch>
Please drop it in the patch system, thanks.
> ---
> arch/arm/kernel/relocate_kernel.S | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/kernel/relocate_kernel.S b/arch/arm/kernel/relocate_kernel.S
> index 7eaa2ae7aff5..72a08786e16e 100644
> --- a/arch/arm/kernel/relocate_kernel.S
> +++ b/arch/arm/kernel/relocate_kernel.S
> @@ -25,26 +25,26 @@ ENTRY(relocate_new_kernel)
> ldr r3, [r0],#4
>
> /* Is it a destination page. Put destination address to r4 */
> - tst r3,#1,0
> + tst r3,#1
> beq 1f
> bic r4,r3,#1
> b 0b
> 1:
> /* Is it an indirection page */
> - tst r3,#2,0
> + tst r3,#2
> beq 1f
> bic r0,r3,#2
> b 0b
> 1:
>
> /* are we done ? */
> - tst r3,#4,0
> + tst r3,#4
> beq 1f
> b 2f
>
> 1:
> /* is it source ? */
> - tst r3,#8,0
> + tst r3,#8
> beq 0b
> bic r3,r3,#8
> mov r6,#1024
> --
> 2.25.0
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
>
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to speedtest.net: 11.9Mbps down 500kbps up
next prev parent reply other threads:[~2020-02-05 23:56 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-05 22:59 [PATCH] ARM: kexec: drop invalid assembly argument Stefan Agner
2020-02-05 22:59 ` Stefan Agner
2020-02-05 23:54 ` Russell King - ARM Linux admin [this message]
2020-02-05 23:54 ` Russell King - ARM Linux admin
2020-02-21 21:09 ` Nick Desaulniers
2020-02-21 21:09 ` Nick Desaulniers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200205235440.GW25745@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=clang-built-linux@googlegroups.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=stefan@agner.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.