178f17e25d
The ro_anonymous_file is an abstraction around anonymous read-only files.
os_ro_anonymous_file_create creates such a file with the contents passed
in data. Subsequent calls to os_ro_anonymous_file_get_fd return a fd
that's ready to be send over the socket.
When mapmode is RO_ANONYMOUS_FILE_MAPMODE_PRIVATE the fd is only
guaranteed to be mmap-able readonly with MAP_PRIVATE but does not
require duplicating the file for each resource when memfd_create is
available. RO_ANONYMOUS_FILE_MAPMODE_SHARED may be used when the client
must be able to map the file with MAP_SHARED but it also means that the
file has to be duplicated even when memfd_create is available.
See also:
weston commit
|
||
---|---|---|
.. | ||
cairo-util.c | ||
cairo-util.h | ||
config-parser.c | ||
fd-util.h | ||
file-util.c | ||
file-util.h | ||
frame.c | ||
helpers.h | ||
image-loader.c | ||
image-loader.h | ||
matrix.c | ||
meson.build | ||
option-parser.c | ||
os-compatibility.c | ||
os-compatibility.h | ||
platform.h | ||
string-helpers.h | ||
timespec-util.h | ||
weston-egl-ext.h | ||
xalloc.c | ||
xalloc.h |