All of lore.kernel.org
 help / color / mirror / Atom feed
From: nicolas.pitre@linaro.org (Nicolas Pitre)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/3] ARM: early_printk: use printascii() rather than printch()
Date: Thu, 2 Nov 2017 11:04:35 -0400 (EDT)	[thread overview]
Message-ID: <nycvar.YSQ.7.76.1711021044380.21665@knanqh.ubzr> (raw)
In-Reply-To: <SG2PR06MB11653D39086B1F58497C9FE08A5C0@SG2PR06MB1165.apcprd06.prod.outlook.com>

On Thu, 2 Nov 2017, Chris Brandt wrote:

> Oops, I meant to show this:
> 
> $ arm-linux-gnueabihf-as -version
> GNU assembler (Linaro_Binutils-2017.01) 2.25.2 Linaro 2016_02
> Copyright (C) 2014 Free Software Foundation, Inc.
> This program is free software; you may redistribute it under the terms of
> the GNU General Public License version 3 or later.
> This program has absolutely no warranty.
> This assembler was configured for a target of `arm-linux-gnueabihf'.

This is very strange. Here's a quick test with all the binutils versions 
I have lying around on my system:

$ echo -e "mov r0, #'\\\r'\nmov r1, '\\\r'"
mov r0, #'\r'
mov r1, '\r'
$ echo -e "mov r0, #'\\\r'\nmov r1, '\\\r'" > /tmp/t.s
$ for as in $(find /opt -name arm-linux-\*-as); do \
> $as --version | head -1; \
> $as /tmp/t.s -o /tmp/t.o; done
GNU assembler (Linaro_Binutils-2017.05) 2.27.0.20161019
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'
GNU assembler (crosstool-NG linaro-1.13.1-4.7-2013.02-01-20130221 - Linaro GCC 2013.02) 2.23.1
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'
GNU assembler (Linaro_Binutils-2017.05) 2.25.2 Linaro 2016_02
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'
GNU assembler (crosstool-NG linaro-1.13.1-4.9-2014.09 - Linaro GCC 4.9-2014.09) 2.24.0.20140829 Linaro 2014.09
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'
GNU assembler (GNU Binutils) Linaro 2014.11-3-git 2.24.0.20141017
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'
GNU assembler (Linaro_Binutils-2017.08) 2.28.2.20170706
/tmp/t.s: Assembler messages:
/tmp/t.s:2: Error: immediate expression requires a # prefix -- `mov r1,13'

They all fail, including the version that looks like the one you have.

Could you try that little test above on your side?

> > So, as far as ARM assembly in the Linux kernel goes, all constants must
> > be preceded by # whether or not binutils requires it - no exceptions.
> > Please always test assembly changes with a binutils version that is not
> > gratuitously broken!
> 
> Somewhat ironic since Nicolas works for Linaro.

I'm not involved with the toolchain people though, other than using 
their output.


Nicolas

  parent reply	other threads:[~2017-11-02 15:04 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-02  2:06 [PATCH 0/3] a few debug_ll fixes and improvements Nicolas Pitre
2017-10-02  2:06 ` [PATCH 1/3] ARM: debug.S: move hexbuf to a writable section Nicolas Pitre
2017-10-02  2:06 ` [PATCH 2/3] ARM: semihosting: use proper instruction on v7m processors Nicolas Pitre
2017-10-02  2:06 ` [PATCH 3/3] ARM: early_printk: use printascii() rather than printch() Nicolas Pitre
2017-10-02  5:20   ` Uwe Kleine-König
2017-10-02 14:09     ` Nicolas Pitre
2017-10-31 11:28   ` Chris Brandt
2017-10-31 16:22     ` Nicolas Pitre
2017-10-31 16:38       ` Robin Murphy
2017-10-31 17:06         ` Nicolas Pitre
2017-10-31 17:16           ` Russell King - ARM Linux
2017-10-31 17:48             ` Nicolas Pitre
2017-10-31 17:53               ` Russell King - ARM Linux
2017-10-31 18:15                 ` Nicolas Pitre
2017-10-31 18:20                   ` Russell King - ARM Linux
2017-10-31 18:35                     ` Nicolas Pitre
2017-10-31 19:12                       ` Chris Brandt
2017-10-31 19:28                         ` Nicolas Pitre
2017-10-31 21:50                           ` Russell King - ARM Linux
2017-10-31 23:35                             ` Nicolas Pitre
2017-10-31 23:50                               ` Russell King - ARM Linux
2017-11-02  0:09                         ` Russell King - ARM Linux
2017-11-02  3:59                           ` Nicolas Pitre
2017-11-02  4:16                             ` Nicolas Pitre
2017-11-02 11:09                               ` Russell King - ARM Linux
2017-11-02 15:12                                 ` Nicolas Pitre
2017-11-02 11:06                             ` Chris Brandt
2017-11-02 11:20                               ` Russell King - ARM Linux
2017-11-02 11:28                                 ` Chris Brandt
2017-11-02 13:04                                   ` Russell King - ARM Linux
2017-11-02 15:04                                   ` Nicolas Pitre [this message]
2017-11-02 15:18                                     ` Robin Murphy
2017-11-02 15:22                                       ` Russell King - ARM Linux
2017-11-02 15:25                                       ` Chris Brandt
2017-11-02 15:23                                     ` Chris Brandt
2017-11-02 15:35                                       ` Nicolas Pitre
2017-11-02 16:06                                         ` Nicolas Pitre
2017-11-02 16:38                                           ` Chris Brandt
2017-11-02 17:10                                             ` Russell King - ARM Linux
2017-11-02 17:20                                               ` Nicolas Pitre
2017-11-02 17:28                                               ` Chris Brandt
2017-11-02 18:29                                               ` Robin Murphy
2017-11-02 21:46                                                 ` syntax unified, was " Nicolas Pitre
2017-11-02 15:48                                       ` Russell King - ARM Linux
2017-11-02 16:30                                         ` Chris Brandt

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=nycvar.YSQ.7.76.1711021044380.21665@knanqh.ubzr \
    --to=nicolas.pitre@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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.