Message ID | 20200107012820.158721-2-alainm@chromium.org |
---|---|
State | New |
Headers | show |
Series | None | expand |
diff --git a/src/shared/util.h b/src/shared/util.h index 604dc3be4..9193068d1 100644 --- a/src/shared/util.h +++ b/src/shared/util.h @@ -27,6 +27,8 @@ #include <byteswap.h> #include <string.h> +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) + #if __BYTE_ORDER == __LITTLE_ENDIAN #define le16_to_cpu(val) (val) #define le32_to_cpu(val) (val)