clean duplicated macro
and add a new new one for range checks.
Change-Id: I077fc9d21f1b209c539561d9ebe42df4bf3125a5
CRs-fixed: 2750060
diff --git a/utils/gps_extended_c.h b/utils/gps_extended_c.h
index f89e55b..fc2df66 100644
--- a/utils/gps_extended_c.h
+++ b/utils/gps_extended_c.h
@@ -486,12 +486,7 @@
#define setSvMask(mask, svIdOneBase) \
if (svFitsMask(mask, svIdOneBase)) mask |= (1ULL << ((svIdOneBase) - 1))
-/* Checking svIdOneBase can be set to the corresponding bit in mask */
-#define svFitsMask(mask, svIdOneBase) \
- ((svIdOneBase) >= 1 && (svIdOneBase) <= (sizeof(mask) << 3))
-/* Setting svIdOneBase specific bit in the mask if the bit offset fits */
-#define setSvMask(mask, svIdOneBase) \
- if (svFitsMask(mask, svIdOneBase)) mask |= (1ULL << ((svIdOneBase) - 1))
+#define isValInRangeInclusive(val, min, max) ((val) >= (min) && (val) <= (max))
typedef enum {
LOC_RELIABILITY_NOT_SET = 0,