lkml.org 
[lkml]   [2021]   [Jul]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] m68k: Fix asm register constraints for atomic ops
Date
On Jul 25 2021, Geert Uytterhoeven wrote:

> Depending on register assignment by the compiler:
>
> {standard input}:3084: Error: operands mismatch -- statement `andl %a1,%d1' ignored
> {standard input}:3145: Error: operands mismatch -- statement `orl %a1,%d1' ignored
> {standard input}:3195: Error: operands mismatch -- statement `eorl %a1,%d1' ignored
>
> Indeed, the first operand must not be an address register. Fix this by
> adjusting the register constraint from "g" (general purpose register) to
> "d" (data register).

You should also allow immediate ("i").

There is the ASM_DI macro for that, but since CONFIG_RMW_INSNS is never
defined for CONFIG_COLDFIRE, it probably doesn't matter.

Andreas.

--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1
"And now for something completely different."

\
 
 \ /
  Last update: 2021-07-25 16:25    [W:0.079 / U:0.076 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site