mlx_utils_priv.h File Reference
#include "../../include/public/mlx_utils.h"

Go to the source code of this file.


mlx_status mlx_utils_delay_in_ms_priv (IN mlx_uint32 msecs)
mlx_status mlx_utils_delay_in_us_priv (IN mlx_uint32 usecs)
mlx_status mlx_utils_ilog2_priv (IN mlx_uint32 i, OUT mlx_uint32 *log)
mlx_status mlx_utils_init_lock_priv (OUT void **lock)
mlx_status mlx_utils_free_lock_priv (IN void *lock)
mlx_status mlx_utils_acquire_lock_priv (IN void *lock)
mlx_status mlx_utils_release_lock_priv (IN void *lock)
mlx_status mlx_utils_rand_priv (IN mlx_utils *utils, OUT mlx_uint32 *rand_num)

Function Documentation



◆ mlx_utils_delay_in_ms_priv()

mlx_status mlx_utils_delay_in_ms_priv ( IN mlx_uint32  msecs)

Definition at line 14 of file mlx_utils_priv.c.

17 {
18  mdelay(msecs);
19  return MLX_SUCCESS;
20 }
void mdelay(unsigned long msecs)
Delay for a fixed number of milliseconds.
Definition: timer.c:78

References mdelay(), and MLX_SUCCESS.

Referenced by mlx_utils_delay_in_ms().

◆ mlx_utils_delay_in_us_priv()

mlx_status mlx_utils_delay_in_us_priv ( IN mlx_uint32  usecs)

Definition at line 23 of file mlx_utils_priv.c.

26 {
27  udelay(usecs);
28  return MLX_SUCCESS;
29 }
void udelay(unsigned long usecs)
Delay for a fixed number of microseconds.
Definition: timer.c:60

References MLX_SUCCESS, and udelay().

Referenced by mlx_utils_delay_in_us().

◆ mlx_utils_ilog2_priv()

mlx_status mlx_utils_ilog2_priv ( IN mlx_uint32  i,
OUT mlx_uint32 log 

Definition at line 32 of file mlx_utils_priv.c.

36 {
37  *log = ( fls ( i ) - 1 );
38  return MLX_SUCCESS;
39 }
#define fls(x)
Find last (i.e.
Definition: strings.h:166

References fls, and MLX_SUCCESS.

Referenced by mlx_utils_ilog2().

◆ mlx_utils_init_lock_priv()

mlx_status mlx_utils_init_lock_priv ( OUT void **  lock)

Referenced by mlx_utils_init_lock().

◆ mlx_utils_free_lock_priv()

mlx_status mlx_utils_free_lock_priv ( IN void *  lock)

Referenced by mlx_utils_free_lock().

◆ mlx_utils_acquire_lock_priv()

mlx_status mlx_utils_acquire_lock_priv ( IN void *  lock)

Referenced by mlx_utils_acquire_lock().

◆ mlx_utils_release_lock_priv()

mlx_status mlx_utils_release_lock_priv ( IN void *  lock)

Referenced by mlx_utils_release_lock().

◆ mlx_utils_rand_priv()

mlx_status mlx_utils_rand_priv ( IN mlx_utils utils,
OUT mlx_uint32 rand_num 

Referenced by mlx_utils_rand().