summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/iio/iio_utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/iio/iio_utils.c b/tools/iio/iio_utils.c
index 1dcdf03955cb..a95270f33353 100644
--- a/tools/iio/iio_utils.c
+++ b/tools/iio/iio_utils.c
@@ -168,7 +168,7 @@ int iioutils_get_type(unsigned *is_signed, unsigned *bytes, unsigned *bits_used,
if (*bits_used == 64)
*mask = ~0;
else
- *mask = (1 << *bits_used) - 1;
+ *mask = (1ULL << *bits_used) - 1;
*is_signed = (signchar == 's');
if (fclose(sysfsfp)) {