mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-14 06:59:57 -05:00
mem: add mmap helper
Add function and structure to help with mmap and mlock
This commit is contained in:
parent
3a9070ee10
commit
ccd19f1e49
2 changed files with 21 additions and 1 deletions
|
|
@ -118,7 +118,8 @@ struct spa_fraction {
|
|||
#define SPA_DEPRECATED
|
||||
#endif
|
||||
|
||||
#define SPA_ROUND_UP_N(num,align) ((((num) + ((align) - 1)) & ~((align) - 1)))
|
||||
#define SPA_ROUND_DOWN_N(num,align) ((num) & ~((align) - 1))
|
||||
#define SPA_ROUND_UP_N(num,align) SPA_ROUND_DOWN_N((num) + ((align) - 1),align)
|
||||
|
||||
#ifndef SPA_LIKELY
|
||||
#ifdef __GNUC__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue