Skip to content

Commit

Permalink
[MIPS] Change names of local variables to silence sparse
Browse files Browse the repository at this point in the history
This patch is an workaround for these sparse warnings:

linux/include/linux/calc64.h:25:17: warning: symbol '__quot' shadows an earlier one
linux/include/linux/calc64.h:25:17: originally declared here
linux/include/linux/calc64.h:25:17: warning: symbol '__mod' shadows an earlier one
linux/include/linux/calc64.h:25:17: originally declared here

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
  • Loading branch information
Atsushi Nemoto authored and Ralf Baechle committed Jul 10, 2007
1 parent 62b3963 commit 7e95a01
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions include/asm-mips/div64.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
*/

#define do_div64_32(res, high, low, base) ({ \
unsigned long __quot, __mod; \
unsigned long __quot32, __mod32; \
unsigned long __cf, __tmp, __tmp2, __i; \
\
__asm__(".set push\n\t" \
Expand Down Expand Up @@ -48,12 +48,13 @@
"bnez %4, 0b\n\t" \
" srl %5, %1, 0x1f\n\t" \
".set pop" \
: "=&r" (__mod), "=&r" (__tmp), "=&r" (__quot), "=&r" (__cf), \
: "=&r" (__mod32), "=&r" (__tmp), \
"=&r" (__quot32), "=&r" (__cf), \
"=&r" (__i), "=&r" (__tmp2) \
: "Jr" (base), "0" (high), "1" (low)); \
\
(res) = __quot; \
__mod; })
(res) = __quot32; \
__mod32; })

#define do_div(n, base) ({ \
unsigned long long __quot; \
Expand Down

0 comments on commit 7e95a01

Please sign in to comment.