diff options
author | Arend Van Spriel <arend.vanspriel@broadcom.com> | 2017-02-22 22:18:45 +0000 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2017-02-23 08:48:13 +0100 |
commit | d10740aeef2b3670430bb877bd8b365e227b9c7f (patch) | |
tree | cb59769e0cd5ce780c0a05ac512a221c1051a01e /backport | |
parent | 475a1d0d7d7bff6dee99712d7c8124fb54d08ac8 (diff) |
backports: add definitions S32_MAX and S32_MIN
Since commit 20e32810bcf4 ("cfg80211: Accept multiple RSSI thresholds
for CQM") the backports need to have S32_MAX and S32_MIN which were
introduced in kernel.h since v3.14.
Signed-off-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'backport')
-rw-r--r-- | backport/backport-include/linux/kernel.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/backport/backport-include/linux/kernel.h b/backport/backport-include/linux/kernel.h index 4ad000c2..ea55d7d3 100644 --- a/backport/backport-include/linux/kernel.h +++ b/backport/backport-include/linux/kernel.h @@ -73,6 +73,14 @@ #define U32_MAX ((u32)~0U) #endif +#ifndef S32_MAX +#define S32_MAX ((s32)(U32_MAX>>1)) +#endif + +#ifndef S32_MIN +#define S32_MIN ((s32)(-S32_MAX - 1)) +#endif + #ifndef __round_mask #define __round_mask(x, y) ((__typeof__(x))((y)-1)) #define round_up(x, y) ((((x)-1) | __round_mask(x, y))+1) |