From f200dd71c5c0909a1b0a89e55082b4b9935a06d6 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Wed, 22 Aug 2012 16:36:18 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4616 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/kernel/src/chregistry.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'os') diff --git a/os/kernel/src/chregistry.c b/os/kernel/src/chregistry.c index 2e63a13f6..971133457 100644 --- a/os/kernel/src/chregistry.c +++ b/os/kernel/src/chregistry.c @@ -50,7 +50,7 @@ #if CH_USE_REGISTRY || defined(__DOXYGEN__) -#define offsetof(st, m) \ +#define _offsetof(st, m) \ ((size_t)((char *)&((st *)0)->m - (char *)0)) /* @@ -66,29 +66,29 @@ ROMCONST chroot_t ch_root = { (uint8_t)sizeof (void *), (uint8_t)sizeof (systime_t), (uint8_t)sizeof (Thread), - (uint8_t)offsetof(Thread, p_prio), - (uint8_t)offsetof(Thread, p_ctx), - (uint8_t)offsetof(Thread, p_newer), - (uint8_t)offsetof(Thread, p_older), - (uint8_t)offsetof(Thread, p_name), + (uint8_t)_offsetof(Thread, p_prio), + (uint8_t)_offsetof(Thread, p_ctx), + (uint8_t)_offsetof(Thread, p_newer), + (uint8_t)_offsetof(Thread, p_older), + (uint8_t)_offsetof(Thread, p_name), #if CH_DBG_ENABLE_STACK_CHECK - (uint8_t)offsetof(Thread, p_stklimit), + (uint8_t)_offsetof(Thread, p_stklimit), #else (uint8_t)0, #endif - (uint8_t)offsetof(Thread, p_state), - (uint8_t)offsetof(Thread, p_flags), + (uint8_t)_offsetof(Thread, p_state), + (uint8_t)_offsetof(Thread, p_flags), #if CH_USE_DYNAMIC - (uint8_t)offsetof(Thread, p_refs), + (uint8_t)_offsetof(Thread, p_refs), #else (uint8_t)0, #endif #if CH_TIME_QUANTUM > 0 - (uint8_t)offsetof(Thread, p_preempt), + (uint8_t)_offsetof(Thread, p_preempt), #else (uint8_t)0, #endif - (uint8_t)offsetof(Thread, p_time) + (uint8_t)_offsetof(Thread, p_time) }; /** -- cgit v1.2.3