#define delay(...)

Joel Sherrill joel.sherrill at OARcorp.com
Fri Nov 10 14:35:25 UTC 2000


Sergei Organov wrote:
> 
> Hello,
> 
> I've found that most of RTEMS 'bsp.h' files define macro 'delay', like this:
> 
> #define delay( _microseconds )\
> ...
> 
> I believe 'delay' is too general to be a name of exported macro because it
> likely to create conflicts with usage of the name in user code. In fact it did
> create conflict in my case. Don't you think it's better to rename the macro
> (e.g., to 'rtems_delay')?

Even better would be rtems_bsp_delay() to indicate that it is a BSP
provided
routine.   FWIW.. this routine is supposed to be a microsecond level
spin
delay.

This name is a relic from the very EARLIEST days of RTEMS.

> BR,
> Sergei Organov.

-- 
Joel Sherrill, Ph.D.             Director of Research & Development
joel at OARcorp.com                 On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
   Support Available             (256) 722-9985



More information about the users mailing list