From: Ralf Baechle Date: Sat, 19 Apr 2014 12:20:54 +0000 (+0200) Subject: MIPS: math-emu: Cleanup ieee754si_indef() / ieee754di_indef(). X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e812a73932dc0b294c30858ba215305b81391c3c;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git MIPS: math-emu: Cleanup ieee754si_indef() / ieee754di_indef(). LONG_LONG_MAX is a symbol defined in which may not be available so better rely on something provided by a kernel header. While at it, turn these function-like macros into inline functions. Signed-off-by: Ralf Baechle --- diff --git a/arch/mips/math-emu/ieee754.h b/arch/mips/math-emu/ieee754.h index 049f63fa635e..952c1808b568 100644 --- a/arch/mips/math-emu/ieee754.h +++ b/arch/mips/math-emu/ieee754.h @@ -26,6 +26,7 @@ #include #include +#include #include #include #include @@ -394,12 +395,15 @@ extern const struct ieee754sp_const __ieee754sp_spcvals[]; /* * Indefinite integer value */ -#define ieee754si_indef() INT_MAX -#ifdef LONG_LONG_MAX -#define ieee754di_indef() LONG_LONG_MAX -#else -#define ieee754di_indef() ((s64)(~0ULL>>1)) -#endif +static inline int ieee754si_indef(void) +{ + return INT_MAX; +} + +static inline s64 ieee754di_indef(void) +{ + return S64_MAX; +} /* IEEE exception context, passed to handler */ struct ieee754xctx {