Skip to content

Commit

Permalink
MIPS: Fix GCC-4.6 'set but not used' warning in ieee754int.h
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
David Daney authored and Ralf Baechle committed Mar 14, 2011
1 parent 7a6e4ca commit 91b51f3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arch/mips/math-emu/ieee754int.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@


#define COMPXSP \
unsigned xm; int xe; int xs; int xc
unsigned xm; int xe; int xs __maybe_unused; int xc

#define COMPYSP \
unsigned ym; int ye; int ys; int yc
Expand Down Expand Up @@ -104,7 +104,7 @@


#define COMPXDP \
u64 xm; int xe; int xs; int xc
u64 xm; int xe; int xs __maybe_unused; int xc

#define COMPYDP \
u64 ym; int ye; int ys; int yc
Expand Down

0 comments on commit 91b51f3

Please sign in to comment.