x86, asm: Refactor atomic64_386_32.S to support old binutils and be cleaner
authorLuca Barbieri <luca@luca-barbieri.com>
Fri, 6 Aug 2010 02:04:38 +0000 (04:04 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 26 Aug 2010 23:45:49 +0000 (16:45 -0700)
commitedda4cb2d00bfb83759f475ff9b228953ea82cf2
treee697d4b284c74aa4501e844699cdd2a204b7b7e0
parent57001f2240b0cba6ec95f460da34c0e81f52b4c2
x86, asm: Refactor atomic64_386_32.S to support old binutils and be cleaner

commit 30246557a06bb20618bed906a06d1e1e0faa8bb4 upstream.

The old code didn't work on binutils 2.12 because setting a symbol to
a register apparently requires a fairly recent version.

This commit refactors the code to use the C preprocessor instead, and
in the process makes the whole code a bit easier to understand.

The object code produced is unchanged as expected.

This fixes kernel bugzilla 16506.

Reported-by: Dieter Stussy <kd6lvw+software@kd6lvw.ampr.org>
Signed-off-by: Luca Barbieri <luca@luca-barbieri.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
LKML-Reference: <tip-*@git.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
arch/x86/lib/atomic64_386_32.S