summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2017-01-03 16:28:05 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2017-01-03 16:28:05 (GMT)
commite73a32b85288319298c1e39b9cf92fb42a838924 (patch)
treef79fab89632a0d0b1ec460ab20eefc328b20b99c /src
parentedd3ff309894decb3eaabce5c91b24f89286d177 (diff)
downloadhdf5-e73a32b85288319298c1e39b9cf92fb42a838924.zip
hdf5-e73a32b85288319298c1e39b9cf92fb42a838924.tar.gz
hdf5-e73a32b85288319298c1e39b9cf92fb42a838924.tar.bz2
Remove 'const' from cache client pre_serialize callback, to reduce warnings,
and correspondingly remove 'const' from some internal routines. Also rename some H5MF* routines to reflect their static/package usage.
Diffstat (limited to 'src')
-rw-r--r--src/H5C.c6
-rw-r--r--src/H5Cepoch.c4
-rw-r--r--src/H5Cpkg.h2
-rw-r--r--src/H5Cprivate.h4
-rw-r--r--src/H5FS.c14
-rw-r--r--src/H5FScache.c8
-rw-r--r--src/H5Fsuper_cache.c4
-rw-r--r--src/H5HFcache.c12
-rw-r--r--src/H5MF.c38
-rw-r--r--src/H5MFdbg.c2
-rw-r--r--src/H5MFpkg.h4
-rw-r--r--src/H5MFprivate.h2
12 files changed, 53 insertions, 47 deletions
diff --git a/src/H5C.c b/src/H5C.c
index 03d7b7a..010b043 100644
--- a/src/H5C.c
+++ b/src/H5C.c
@@ -169,7 +169,7 @@ static herr_t H5C__mark_flush_dep_clean(H5C_cache_entry_t * entry);
static herr_t H5C__verify_len_eoa(H5F_t *f, const H5C_class_t * type,
haddr_t addr, size_t *len, hbool_t actual);
-static herr_t H5C__generate_image(const H5F_t *f, H5C_t * cache_ptr, H5C_cache_entry_t *entry_ptr,
+static herr_t H5C__generate_image(H5F_t *f, H5C_t * cache_ptr, H5C_cache_entry_t *entry_ptr,
hid_t dxpl_id);
#if H5C_DO_SLIST_SANITY_CHECKS
@@ -5887,7 +5887,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5C__flush_single_entry(const H5F_t *f, hid_t dxpl_id, H5C_cache_entry_t *entry_ptr,
+H5C__flush_single_entry(H5F_t *f, hid_t dxpl_id, H5C_cache_entry_t *entry_ptr,
unsigned flags)
{
H5C_t * cache_ptr; /* Cache for file */
@@ -7766,7 +7766,7 @@ H5C__assert_flush_dep_nocycle(const H5C_cache_entry_t * entry,
*-------------------------------------------------------------------------
*/
static herr_t
-H5C__generate_image(const H5F_t *f, H5C_t *cache_ptr, H5C_cache_entry_t *entry_ptr,
+H5C__generate_image(H5F_t *f, H5C_t *cache_ptr, H5C_cache_entry_t *entry_ptr,
hid_t dxpl_id)
{
haddr_t new_addr = HADDR_UNDEF;
diff --git a/src/H5Cepoch.c b/src/H5Cepoch.c
index f9c809b..e576028 100644
--- a/src/H5Cepoch.c
+++ b/src/H5Cepoch.c
@@ -66,7 +66,7 @@ static void * H5C__epoch_marker_deserialize(const void * image_ptr,
size_t len, void * udata, hbool_t * dirty_ptr);
static herr_t H5C__epoch_marker_image_len(const void * thing,
size_t *image_len_ptr);
-static herr_t H5C__epoch_marker_pre_serialize(const H5F_t *f,
+static herr_t H5C__epoch_marker_pre_serialize(H5F_t *f,
hid_t dxpl_id, void * thing, haddr_t addr, size_t len,
haddr_t * new_addr_ptr, size_t * new_len_ptr, unsigned * flags_ptr);
static herr_t H5C__epoch_marker_serialize(const H5F_t *f,
@@ -183,7 +183,7 @@ H5C__epoch_marker_image_len(const void H5_ATTR_UNUSED *thing,
static herr_t
-H5C__epoch_marker_pre_serialize(const H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED dxpl_id,
+H5C__epoch_marker_pre_serialize(H5F_t H5_ATTR_UNUSED *f, hid_t H5_ATTR_UNUSED dxpl_id,
void H5_ATTR_UNUSED *thing, haddr_t H5_ATTR_UNUSED addr, size_t H5_ATTR_UNUSED len,
haddr_t H5_ATTR_UNUSED *new_addr_ptr, size_t H5_ATTR_UNUSED *new_len_ptr,
unsigned H5_ATTR_UNUSED *flags_ptr)
diff --git a/src/H5Cpkg.h b/src/H5Cpkg.h
index 3a486df..392553a 100644
--- a/src/H5Cpkg.h
+++ b/src/H5Cpkg.h
@@ -4547,7 +4547,7 @@ H5_DLLVAR const H5C_class_t H5C__epoch_marker_class;
/******************************/
/* General routines */
-H5_DLL herr_t H5C__flush_single_entry(const H5F_t *f, hid_t dxpl_id,
+H5_DLL herr_t H5C__flush_single_entry(H5F_t *f, hid_t dxpl_id,
H5C_cache_entry_t *entry_ptr, unsigned flags);
H5_DLL herr_t H5C__flush_marked_entries(H5F_t * f, hid_t dxpl_id);
H5_DLL herr_t H5C__iter_tagged_entries(H5C_t *cache, haddr_t tag, hbool_t match_global,
diff --git a/src/H5Cprivate.h b/src/H5Cprivate.h
index 365fd6c..74d0826 100644
--- a/src/H5Cprivate.h
+++ b/src/H5Cprivate.h
@@ -559,7 +559,7 @@ typedef struct H5C_t H5C_t;
*
* The typedef for the pre-serialize callback is as follows:
*
- * typedef herr_t (*H5C_pre_serialize_func_t)(const H5F_t *f,
+ * typedef herr_t (*H5C_pre_serialize_func_t)(H5F_t *f,
* hid_t dxpl_id,
* void * thing,
* haddr_t addr,
@@ -878,7 +878,7 @@ typedef htri_t (*H5C_verify_chksum_func_t)(const void *image_ptr, size_t len, vo
typedef void *(*H5C_deserialize_func_t)(const void *image_ptr,
size_t len, void *udata_ptr, hbool_t *dirty_ptr);
typedef herr_t (*H5C_image_len_func_t)(const void *thing, size_t *image_len_ptr);
-typedef herr_t (*H5C_pre_serialize_func_t)(const H5F_t *f, hid_t dxpl_id,
+typedef herr_t (*H5C_pre_serialize_func_t)(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr_ptr,
size_t *new_len_ptr, unsigned *flags_ptr);
typedef herr_t (*H5C_serialize_func_t)(const H5F_t *f, void *image_ptr,
diff --git a/src/H5FS.c b/src/H5FS.c
index af02e0f..c7a8930 100644
--- a/src/H5FS.c
+++ b/src/H5FS.c
@@ -193,7 +193,7 @@ H5FS_open(H5F_t *f, hid_t dxpl_id, haddr_t fs_addr, uint16_t nclasses,
H5FS_hdr_cache_ud_t cache_udata; /* User-data for metadata cache callback */
H5FS_t *ret_value = NULL; /* Return value */
- FUNC_ENTER_NOAPI(NULL)
+ FUNC_ENTER_NOAPI_NOINIT_TAG(dxpl_id, H5AC__FREESPACE_TAG, NULL)
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Opening free space manager, fs_addr = %a, nclasses = %Zu\n", FUNC, fs_addr, nclasses);
#endif /* H5FS_DEBUG */
@@ -237,7 +237,7 @@ HDfprintf(stderr, "%s: fspace->rc = %u\n", FUNC, fspace->rc);
ret_value = fspace;
done:
- FUNC_LEAVE_NOAPI(ret_value)
+ FUNC_LEAVE_NOAPI_TAG(ret_value, NULL)
} /* H5FS_open() */
@@ -409,7 +409,7 @@ H5FS_close(H5F_t *f, hid_t dxpl_id, H5FS_t *fspace)
{
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI(FAIL)
+ FUNC_ENTER_NOAPI_NOINIT_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
/* Check arguments. */
HDassert(f);
@@ -570,7 +570,7 @@ done:
#ifdef H5FS_DEBUG
HDfprintf(stderr, "%s: Leaving, ret_value = %d, fspace->rc = %u\n", FUNC, ret_value, fspace->rc);
#endif /* H5FS_DEBUG */
- FUNC_LEAVE_NOAPI(ret_value)
+ FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
} /* H5FS_close() */
@@ -888,6 +888,10 @@ H5FS_alloc_sect(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
if(H5AC_insert_entry(f, dxpl_id, H5AC_FSPACE_SINFO, fspace->sect_addr, fspace->sinfo, H5AC__NO_FLAGS_SET) < 0)
HGOTO_ERROR(H5E_FSPACE, H5E_CANTINIT, FAIL, "can't add free space sections to cache")
+ /* Since space has been allocated for the section info and the sinfo
+ * has been inserted into the cache, relinquish owership (i.e. float)
+ * the section info.
+ */
fspace->sinfo = NULL;
} /* end if */
@@ -923,6 +927,7 @@ H5FS_free(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
cache_flags = H5AC__DELETED_FLAG | H5AC__TAKE_OWNERSHIP_FLAG;;
+ /* Free space for section info */
if(H5F_addr_defined(fspace->sect_addr)) {
hsize_t saved_size; /* Size of previous section info */
unsigned sinfo_status = 0; /* Section info cache status */
@@ -964,6 +969,7 @@ H5FS_free(H5F_t *f, H5FS_t *fspace, hid_t dxpl_id)
HGOTO_ERROR(H5E_FSPACE, H5E_CANTMARKDIRTY, FAIL, "unable to mark free space header as dirty")
} /* end if */
+ /* Free space for header */
if(H5F_addr_defined(fspace->addr)) {
unsigned hdr_status = 0; /* Header entry status */
diff --git a/src/H5FScache.c b/src/H5FScache.c
index 400f07c..84707ca 100644
--- a/src/H5FScache.c
+++ b/src/H5FScache.c
@@ -83,7 +83,7 @@ static htri_t H5FS__cache_hdr_verify_chksum(const void *image_ptr, size_t len, v
static void *H5FS__cache_hdr_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5FS__cache_hdr_image_len(const void *thing, size_t *image_len);
-static herr_t H5FS__cache_hdr_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+static herr_t H5FS__cache_hdr_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len,
unsigned *flags);
static herr_t H5FS__cache_hdr_serialize(const H5F_t *f, void *image,
@@ -95,7 +95,7 @@ static htri_t H5FS__cache_sinfo_verify_chksum(const void *image_ptr, size_t len,
static void *H5FS__cache_sinfo_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5FS__cache_sinfo_image_len(const void *thing, size_t *image_len);
-static herr_t H5FS__cache_sinfo_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+static herr_t H5FS__cache_sinfo_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len,
unsigned *flags);
static herr_t H5FS__cache_sinfo_serialize(const H5F_t *f, void *image,
@@ -404,7 +404,7 @@ H5FS__cache_hdr_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5FS__cache_hdr_pre_serialize(const H5F_t *f, hid_t dxpl_id, void *_thing,
+H5FS__cache_hdr_pre_serialize(H5F_t *f, hid_t dxpl_id, void *_thing,
haddr_t addr, size_t H5_ATTR_UNUSED len, haddr_t *new_addr, size_t *new_len,
unsigned *flags)
{
@@ -1091,7 +1091,7 @@ H5FS__cache_sinfo_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5FS__cache_sinfo_pre_serialize(const H5F_t *f, hid_t dxpl_id, void *_thing,
+H5FS__cache_sinfo_pre_serialize(H5F_t *f, hid_t dxpl_id, void *_thing,
haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len, unsigned *flags)
{
H5FS_sinfo_t *sinfo = (H5FS_sinfo_t *)_thing; /* Pointer to the object */
diff --git a/src/H5Fsuper_cache.c b/src/H5Fsuper_cache.c
index 8e832d7..236136a 100644
--- a/src/H5Fsuper_cache.c
+++ b/src/H5Fsuper_cache.c
@@ -74,7 +74,7 @@ static htri_t H5F__cache_superblock_verify_chksum(const void *image_ptr, size_t
static void *H5F__cache_superblock_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5F__cache_superblock_image_len(const void *thing, size_t *image_len);
-static herr_t H5F__cache_superblock_pre_serialize(const H5F_t *f,
+static herr_t H5F__cache_superblock_pre_serialize(H5F_t *f,
hid_t dxpl_id, void *thing, haddr_t addr, size_t len,
haddr_t *new_addr, size_t *new_len, unsigned *flags);
static herr_t H5F__cache_superblock_serialize(const H5F_t *f, void *image, size_t len,
@@ -685,7 +685,7 @@ H5F__cache_superblock_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5F__cache_superblock_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+H5F__cache_superblock_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *_thing, haddr_t H5_ATTR_UNUSED addr, size_t H5_ATTR_UNUSED len,
haddr_t H5_ATTR_UNUSED *new_addr, size_t H5_ATTR_UNUSED *new_len,
unsigned H5_ATTR_UNUSED *flags)
diff --git a/src/H5HFcache.c b/src/H5HFcache.c
index 1e2eb8f..e72cc6c 100644
--- a/src/H5HFcache.c
+++ b/src/H5HFcache.c
@@ -81,7 +81,7 @@ static htri_t H5HF__cache_hdr_verify_chksum(const void *image_ptr, size_t len, v
static void *H5HF__cache_hdr_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5HF__cache_hdr_image_len(const void *thing, size_t *image_len);
-static herr_t H5HF__cache_hdr_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+static herr_t H5HF__cache_hdr_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len,
unsigned *flags);
static herr_t H5HF__cache_hdr_serialize(const H5F_t *f, void *image,
@@ -93,7 +93,7 @@ static htri_t H5HF__cache_iblock_verify_chksum(const void *image_ptr, size_t len
static void *H5HF__cache_iblock_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5HF__cache_iblock_image_len(const void *thing, size_t *image_len);
-static herr_t H5HF__cache_iblock_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+static herr_t H5HF__cache_iblock_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len,
unsigned *flags);
static herr_t H5HF__cache_iblock_serialize(const H5F_t *f, void *image,
@@ -106,7 +106,7 @@ static htri_t H5HF__cache_dblock_verify_chksum(const void *image_ptr, size_t len
static void *H5HF__cache_dblock_deserialize(const void *image, size_t len,
void *udata, hbool_t *dirty);
static herr_t H5HF__cache_dblock_image_len(const void *thing, size_t *image_len);
-static herr_t H5HF__cache_dblock_pre_serialize(const H5F_t *f, hid_t dxpl_id,
+static herr_t H5HF__cache_dblock_pre_serialize(H5F_t *f, hid_t dxpl_id,
void *thing, haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len,
unsigned *flags);
static herr_t H5HF__cache_dblock_serialize(const H5F_t *f, void *image,
@@ -664,7 +664,7 @@ H5HF__cache_hdr_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5HF__cache_hdr_pre_serialize(const H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id,
+H5HF__cache_hdr_pre_serialize(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id,
void *_thing, haddr_t addr, size_t len, haddr_t H5_ATTR_UNUSED *new_addr,
size_t H5_ATTR_UNUSED *new_len, unsigned *flags)
{
@@ -1188,7 +1188,7 @@ H5HF__cache_iblock_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5HF__cache_iblock_pre_serialize(const H5F_t *f, hid_t dxpl_id, void *_thing,
+H5HF__cache_iblock_pre_serialize(H5F_t *f, hid_t dxpl_id, void *_thing,
haddr_t addr, size_t H5_ATTR_UNUSED len, haddr_t *new_addr,
size_t H5_ATTR_UNUSED *new_len, unsigned *flags)
{
@@ -2053,7 +2053,7 @@ H5HF__cache_dblock_image_len(const void *_thing, size_t *image_len)
*-------------------------------------------------------------------------
*/
static herr_t
-H5HF__cache_dblock_pre_serialize(const H5F_t *f, hid_t dxpl_id, void *_thing,
+H5HF__cache_dblock_pre_serialize(H5F_t *f, hid_t dxpl_id, void *_thing,
haddr_t addr, size_t len, haddr_t *new_addr, size_t *new_len, unsigned *flags)
{
hbool_t at_tmp_addr; /* Flag to indicate direct block is */
diff --git a/src/H5MF.c b/src/H5MF.c
index 09341e6..f0e2244 100644
--- a/src/H5MF.c
+++ b/src/H5MF.c
@@ -222,7 +222,7 @@ done:
/*-------------------------------------------------------------------------
- * Function: H5MF_alloc_open
+ * Function: H5MF__alloc_open
*
* Purpose: Open an existing free space manager of TYPE for file by
* creating a free-space structure
@@ -237,7 +237,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5MF_alloc_open(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
+H5MF__alloc_open(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
{
const H5FS_section_class_t *classes[] = { /* Free space section classes implemented for file */
H5MF_FSPACE_SECT_CLS_SIMPLE};
@@ -275,7 +275,7 @@ done:
HDONE_ERROR(H5E_RESOURCE, H5E_CANTSET, FAIL, "unable to set property value")
FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
-} /* end H5MF_alloc_open() */
+} /* end H5MF__alloc_open() */
/*-------------------------------------------------------------------------
@@ -334,7 +334,7 @@ done:
/*-------------------------------------------------------------------------
- * Function: H5MF_alloc_start
+ * Function: H5MF__alloc_start
*
* Purpose: Open or create a free space manager of a given type
*
@@ -348,7 +348,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5MF_alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
+H5MF__alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
{
herr_t ret_value = SUCCEED; /* Return value */
@@ -364,7 +364,7 @@ H5MF_alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
/* Check if the free space manager exists already */
if(H5F_addr_defined(f->shared->fs_addr[type])) {
/* Open existing free space manager */
- if(H5MF_alloc_open(f, dxpl_id, type) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTOPENOBJ, FAIL, "can't initialize file free space")
} /* end if */
else {
@@ -375,7 +375,7 @@ H5MF_alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type)
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5MF_alloc_start() */
+} /* end H5MF__alloc_start() */
/*-------------------------------------------------------------------------
@@ -464,7 +464,7 @@ HDfprintf(stderr, "%s: alloc_type = %u, size = %Hu\n", FUNC, (unsigned)alloc_typ
if(H5F_HAVE_FREE_SPACE_MANAGER(f)) {
/* Check if the free space manager for the file has been initialized */
if(!f->shared->fs_man[fs_type] && H5F_addr_defined(f->shared->fs_addr[fs_type]))
- if(H5MF_alloc_open(f, dxpl_id, fs_type) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, fs_type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTOPENOBJ, HADDR_UNDEF, "can't initialize file free space")
/* Search for large enough space in the free space manager */
@@ -622,7 +622,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5MF_xfree(const H5F_t *f, H5FD_mem_t alloc_type, hid_t dxpl_id, haddr_t addr,
+H5MF_xfree(H5F_t *f, H5FD_mem_t alloc_type, hid_t dxpl_id, haddr_t addr,
hsize_t size)
{
H5F_io_info_t fio_info; /* I/O info for operation */
@@ -717,7 +717,7 @@ HDfprintf(stderr, "%s: dropping addr = %a, size = %Hu, on the floor!\n", FUNC, a
* space isn't at the end of the file, so start up (or create)
* the file space manager
*/
- if(H5MF_alloc_start(f, dxpl_id, fs_type) < 0)
+ if(H5MF__alloc_start(f, dxpl_id, fs_type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTINIT, FAIL, "can't initialize file free space")
} /* end if */
@@ -839,7 +839,7 @@ HDfprintf(stderr, "%s: Entering: alloc_type = %u, addr = %a, size = %Hu, extra_r
/* Check if the free space for the file has been initialized */
if(!f->shared->fs_man[fs_type] && H5F_addr_defined(f->shared->fs_addr[fs_type]))
- if(H5MF_alloc_open(f, dxpl_id, fs_type) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, fs_type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTINIT, FAIL, "can't initialize file free space")
/* Check for test block able to block in free space manager */
@@ -930,7 +930,7 @@ H5MF_get_freespace(H5F_t *f, hid_t dxpl_id, hsize_t *tot_space, hsize_t *meta_si
/* Check if the free space for the file has been initialized */
if(!f->shared->fs_man[type] && H5F_addr_defined(f->shared->fs_addr[type])) {
- if(H5MF_alloc_open(f, dxpl_id, type) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTINIT, FAIL, "can't initialize file free space")
HDassert(f->shared->fs_man[type]);
fs_started[type] = TRUE;
@@ -1088,7 +1088,7 @@ HDfprintf(stderr, "%s: Leaving, ret_value = %d\n", FUNC, ret_value);
/*-------------------------------------------------------------------------
- * Function: H5MF_close_shrink_eoa
+ * Function: H5MF__close_shrink_eoa
*
* Purpose: Shrink the EOA while closing
*
@@ -1100,7 +1100,7 @@ HDfprintf(stderr, "%s: Leaving, ret_value = %d\n", FUNC, ret_value);
*-------------------------------------------------------------------------
*/
static herr_t
-H5MF_close_shrink_eoa(H5F_t *f, hid_t dxpl_id)
+H5MF__close_shrink_eoa(H5F_t *f, hid_t dxpl_id)
{
H5FD_mem_t type; /* Memory type for iteration */
hbool_t eoa_shrank; /* Whether an EOA shrink occurs */
@@ -1108,7 +1108,7 @@ H5MF_close_shrink_eoa(H5F_t *f, hid_t dxpl_id)
H5MF_sect_ud_t udata; /* User data for callback */
herr_t ret_value = SUCCEED; /* Return value */
- FUNC_ENTER_NOAPI_NOINIT_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
+ FUNC_ENTER_STATIC_TAG(dxpl_id, H5AC__FREESPACE_TAG, FAIL)
/* check args */
HDassert(f);
@@ -1144,7 +1144,7 @@ H5MF_close_shrink_eoa(H5F_t *f, hid_t dxpl_id)
done:
FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
-} /* end H5MF_close_shrink_eoa() */
+} /* end H5MF__close_shrink_eoa() */
/*-------------------------------------------------------------------------
@@ -1329,7 +1329,7 @@ HDfprintf(stderr, "%s: Entering\n", FUNC);
HGOTO_ERROR(H5E_FILE, H5E_CANTFREE, FAIL, "can't free aggregators")
/* Trying shrinking the EOA for the file */
- if(H5MF_close_shrink_eoa(f, dxpl_id) < 0)
+ if(H5MF__close_shrink_eoa(f, dxpl_id) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTSHRINK, FAIL, "can't shrink eoa")
/* Making free-space managers persistent for superblock version >= 2 */
@@ -1435,7 +1435,7 @@ HDfprintf(stderr, "%s: Entering\n", FUNC);
/* Trying shrinking the EOA for the file */
/* (in case any free space is now at the EOA) */
- if(H5MF_close_shrink_eoa(f, dxpl_id) < 0)
+ if(H5MF__close_shrink_eoa(f, dxpl_id) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTSHRINK, FAIL, "can't shrink eoa")
done:
@@ -1538,7 +1538,7 @@ H5MF_get_free_sections(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type, size_t nsects,
/* Open free space manager of this type, if it isn't already */
if(!f->shared->fs_man[ty] && H5F_addr_defined(f->shared->fs_addr[ty])) {
- if(H5MF_alloc_open(f, dxpl_id, ty) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, ty) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTOPENOBJ, FAIL, "can't initialize file free space")
HDassert(f->shared->fs_man[ty]);
fs_started = TRUE;
diff --git a/src/H5MFdbg.c b/src/H5MFdbg.c
index ef4f1bb..57bac9e 100644
--- a/src/H5MFdbg.c
+++ b/src/H5MFdbg.c
@@ -171,7 +171,7 @@ H5MF_sects_debug(H5F_t *f, hid_t dxpl_id, haddr_t fs_addr, FILE *stream, int ind
for(type = H5FD_MEM_DEFAULT; type < H5FD_MEM_NTYPES; H5_INC_ENUM(H5FD_mem_t, type))
if(H5F_addr_eq(f->shared->fs_addr[type], fs_addr)) {
if(!f->shared->fs_man[type])
- if(H5MF_alloc_open(f, dxpl_id, type) < 0)
+ if(H5MF__alloc_open(f, dxpl_id, type) < 0)
HGOTO_ERROR(H5E_RESOURCE, H5E_CANTINIT, FAIL, "can't initialize file free space")
if(f->shared->fs_man[type]) {
diff --git a/src/H5MFpkg.h b/src/H5MFpkg.h
index 1a62710..5b9210e 100644
--- a/src/H5MFpkg.h
+++ b/src/H5MFpkg.h
@@ -143,8 +143,8 @@ H5_DLLVAR H5FS_section_class_t H5MF_FSPACE_SECT_CLS_SIMPLE[1];
/******************************/
/* Allocator routines */
-H5_DLL herr_t H5MF_alloc_open(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type);
-H5_DLL herr_t H5MF_alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type);
+H5_DLL herr_t H5MF__alloc_start(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type);
+H5_DLL herr_t H5MF__alloc_open(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type);
H5_DLL herr_t H5MF_sects_dump(H5F_t *f, hid_t dxpl_id, FILE *stream);
/* 'simple' section routines */
diff --git a/src/H5MFprivate.h b/src/H5MFprivate.h
index cb797b7..0adcfd4 100644
--- a/src/H5MFprivate.h
+++ b/src/H5MFprivate.h
@@ -59,7 +59,7 @@ H5_DLL herr_t H5MF_try_close(H5F_t *f, hid_t dxpl_id);
/* File space allocation routines */
H5_DLL haddr_t H5MF_alloc(H5F_t *f, H5FD_mem_t type, hid_t dxpl_id, hsize_t size);
H5_DLL haddr_t H5MF_aggr_vfd_alloc(H5F_t *f, H5FD_mem_t type, hid_t dxpl_id, hsize_t size);
-H5_DLL herr_t H5MF_xfree(const H5F_t *f, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr,
+H5_DLL herr_t H5MF_xfree(H5F_t *f, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr,
hsize_t size);
H5_DLL herr_t H5MF_try_extend(H5F_t *f, hid_t dxpl_id, H5FD_mem_t type,
haddr_t addr, hsize_t size, hsize_t extra_requested);