X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=sigrok-internal.h;h=4aeae18e4cdd904b0edb97517b6dcb24c79b3f96;hb=f7d2982d42e876d8814cba203570a45284c79658;hp=85004aa13f14b8c0d27586bd6efd654825a2495b;hpb=8233ff53ae7c6e120af4784bc61a036882d5c234;p=libsigrok.git diff --git a/sigrok-internal.h b/sigrok-internal.h index 85004aa1..4aeae18e 100644 --- a/sigrok-internal.h +++ b/sigrok-internal.h @@ -20,6 +20,19 @@ #ifndef SIGROK_SIGROK_INTERNAL_H #define SIGROK_SIGROK_INTERNAL_H +/*--- Macros ----------------------------------------------------------------*/ + +#ifndef ARRAY_SIZE +#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0])) +#endif + +#ifndef ARRAY_AND_SIZE +#define ARRAY_AND_SIZE(a) (a), ARRAY_SIZE(a) +#endif + +/* Size of a datastore chunk in units */ +#define DATASTORE_CHUNKSIZE 512000 + /*--- hwplugin.c ------------------------------------------------------------*/ int load_hwplugins(void);