Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

MIPS: Fix GCC-4.6 'set but not used' warning in ieee754int.h

GCC-4.6 can find more unused code than previous versions could.

In the case of arch/mips/math-emu/ieee754int.h, the COMPXSP and
COMPXDP macros are used in several places, but a couple of them leave
xs unused. The easiest thing to do is mark it as __maybe_unused to
quiet the warning.

Signed-off-by: David Daney <ddaney@caviumnetworks.com>
To: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/2032/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>

authored by

David Daney and committed by
Ralf Baechle
91b51f30 7a6e4ca1

+2 -2
+2 -2
arch/mips/math-emu/ieee754int.h
··· 70 70 71 71 72 72 #define COMPXSP \ 73 - unsigned xm; int xe; int xs; int xc 73 + unsigned xm; int xe; int xs __maybe_unused; int xc 74 74 75 75 #define COMPYSP \ 76 76 unsigned ym; int ye; int ys; int yc ··· 104 104 105 105 106 106 #define COMPXDP \ 107 - u64 xm; int xe; int xs; int xc 107 + u64 xm; int xe; int xs __maybe_unused; int xc 108 108 109 109 #define COMPYDP \ 110 110 u64 ym; int ye; int ys; int yc