summaryrefslogtreecommitdiff
path: root/src/common/tusb_common.h
diff options
context:
space:
mode:
authorhathach <[email protected]>2025-09-19 16:00:36 +0700
committerhathach <[email protected]>2025-09-19 16:05:37 +0700
commite76d09bb4213921c8957af22033c9451fe0ed123 (patch)
tree0bc9f3697d7b0ebb53b70ff6bc54d7a36179bc7f /src/common/tusb_common.h
parentf99f203c28b79f00c5eb82e34c869efb3c5034a0 (diff)
rework get storageIDs and get storage info
Diffstat (limited to 'src/common/tusb_common.h')
-rw-r--r--src/common/tusb_common.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/common/tusb_common.h b/src/common/tusb_common.h
index e35d3e6fe..76764bbba 100644
--- a/src/common/tusb_common.h
+++ b/src/common/tusb_common.h
@@ -35,6 +35,7 @@
// Macros Helper
//--------------------------------------------------------------------+
#define TU_ARRAY_SIZE(_arr) ( sizeof(_arr) / sizeof(_arr[0]) )
+#define TU_FIELD_SZIE(_type, _field) (sizeof(((_type *)0)->_field))
#define TU_MIN(_x, _y) ( ( (_x) < (_y) ) ? (_x) : (_y) )
#define TU_MAX(_x, _y) ( ( (_x) > (_y) ) ? (_x) : (_y) )
#define TU_DIV_CEIL(n, d) (((n) + (d) - 1) / (d))