mem.c File Reference
Include dependency graph for mem.c:

## Data Structures

struct | memblock

## Macros

#define | _GNU_SOURCE
#define | MFD_CLOEXEC 0x0001U
#define | MFD_ALLOW_SEALING 0x0002U
#define | F_LINUX_SPECIFIC_BASE 1024
#define | F_ADD_SEALS (F_LINUX_SPECIFIC_BASE + 9)
#define | F_GET_SEALS (F_LINUX_SPECIFIC_BASE + 10)
#define | F_SEAL_SEAL 0x0001 /* prevent further seals from being set */
#define | F_SEAL_SHRINK 0x0002 /* prevent file from shrinking */
#define | F_SEAL_GROW 0x0004 /* prevent file from growing */
#define | F_SEAL_WRITE 0x0008 /* prevent writes */
#define | USE_MEMFD

## Functions

SPA_EXPORT int | pw_memblock_import (enum pw_memblock_flags flags, int fd, off_t offset, size_t size, struct pw_memblock **mem)
SPA_EXPORT struct pw_memblock * | pw_memblock_find (const void *ptr)
| Find memblock for given ptr. More...

## Macro Definition Documentation

## _GNU_SOURCE

#define _GNU_SOURCE

## F_ADD_SEALS

#define F_ADD_SEALS (F_LINUX_SPECIFIC_BASE + 9)

Referenced by pw_memblock::pw_memblock_alloc().

## F_GET_SEALS

#define F_GET_SEALS (F_LINUX_SPECIFIC_BASE + 10)

## F_LINUX_SPECIFIC_BASE

#define F_LINUX_SPECIFIC_BASE 1024

## F_SEAL_GROW

#define F_SEAL_GROW 0x0004 /* prevent file from growing */

Referenced by pw_memblock::pw_memblock_alloc().

## F_SEAL_SEAL

#define F_SEAL_SEAL 0x0001 /* prevent further seals from being set */

Referenced by pw_memblock::pw_memblock_alloc().

## F_SEAL_SHRINK

#define F_SEAL_SHRINK 0x0002 /* prevent file from shrinking */

Referenced by pw_memblock::pw_memblock_alloc().

## F_SEAL_WRITE

#define F_SEAL_WRITE 0x0008 /* prevent writes */

## MFD_ALLOW_SEALING

#define MFD_ALLOW_SEALING 0x0002U

Referenced by pw_memblock::pw_memblock_alloc().

## MFD_CLOEXEC

#define MFD_CLOEXEC 0x0001U

Referenced by pw_memblock::pw_memblock_alloc().

## USE_MEMFD

#define USE_MEMFD

## Function Documentation

## pw_memblock_find()

SPA_EXPORT struct pw_memblock* pw_memblock_find | ( | const void * | ptr | ) |

Find memblock for given ptr.

## pw_memblock_import()

SPA_EXPORT int pw_memblock_import | ( | enum pw_memblock_flags | flags,
|  | int | fd,
|  | off_t | offset,
|  | size_t | size,
|  | struct pw_memblock ** | mem
| ) |  |

References pw_memblock::fd, pw_memblock::flags, pw_memblock::offset, pw_memblock_alloc(), pw_memblock_map(), and pw_memblock::size.