[PATCH] MTD: Fix Orion NAND driver compilation with ARM OABI
jamie at shareable.org
Sun Mar 21 13:16:34 EDT 2010
David Woodhouse wrote:
> Strictly speaking, I think your version is wrong -- although you force
> the variable 'x' to be stored in r2/r3, you don't actually force GCC to
> use r2/r3 as the output registers for the asm statement -- it could
> happily use other registers, then move their contents into r2/r3
We used to do that a lot in the syscall macros in <asm/unistd.h>, on a
lot of architectures. Were they all broken?
> Obviously it _won't_ do that most of the time, but it _could_. GCC PR
> #15089 was filed for the fact that sometimes it does, but I think Nico
> was missing the point -- GCC is _allowed_ to do that, and if it makes
> you sad then you should be asking for better assembly constraints which
> would allow you to tell it not to.
More information about the linux-mtd