diff --git a/tools/iio/iio_utils.c b/tools/iio/iio_utils.c index 1dcdf03955cb81b26b4fd156472fa9380a4803bb..a95270f3335376ca46f494ba8190a9343e8bffea 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)) {