Revision acc97cbf core/inc/aos_system.h

View differences:

core/inc/aos_system.h
206 206
/**
207 207
 * @brief   Retrieves the system uptime.
208 208
 *
209
 * @param[out] ut   The system uptime.
209
 * @param[out] ut   Pointer to the system uptime.
210 210
 */
211
static inline void aosSysGetUptime(aos_timestamp_t* ut)
212
{
213
  aosDbgCheck(ut != NULL);
214

  
215
  chSysLock();
216
  aosSysGetUptimeX(ut);
217
  chSysUnlock();
218

  
219
  return;
211
#define aosSysGetUptime(ut) {         \
212
  chSysLock();                        \
213
  aosSysGetUptimeX(ut);               \
214
  chSysUnlock();                      \
220 215
}
221 216

  
222 217
#endif /* _AMIROOS_SYSTEM_H_ */

Also available in: Unified diff