1PMEM2_CONFIG_SET_LENGTH(3) PMDK Programmer's Manual PMEM2_CONFIG_SET_LENGTH(3)
2
3
4

NAME

6       pmem2_config_set_length() - set length in the pmem2_config structure
7

SYNOPSIS

9              #include <libpmem2.h>
10
11              struct pmem2_config;
12              int pmem2_config_set_length(struct pmem2_config *config, size_t length);
13

DESCRIPTION

15       The pmem2_config_set_length() function configures the length which will
16       be used for mapping.  *config should be already initialized, please see
17       pmem2_config_new(3)  for details.  The must be a multiple of the align‐
18       ment required for the data source which will be used for mapping along‐
19       side  the  config.  To retrieve the alignment required for specific in‐
20       stance of pmem2_source** use  pmem2_source_alignment(3).   By  default,
21       the length is equal to the size of the file that is being mapped.
22

RETURN VALUE

24       The pmem2_config_set_length() function always returns 0.
25

SEE ALSO

27       libpmem2(7),  pmem2_map_new(3),  pmem2_source_alignment(3),  pmem2_con‐
28       fig_new(3), sysconf(3) and <https://pmem.io>
29
30
31
32PMDK - pmem2 API version 1.0      2021-07-22        PMEM2_CONFIG_SET_LENGTH(3)
Impressum