diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-13 17:48:07 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-13 17:48:07 (GMT) |
commit | 14b00edf0aeb92c493205b41748f50cb89eaa055 (patch) | |
tree | da3ee20963be0d218b9c7a567a1b7ece89bfee2c /src/H5F.c | |
parent | dbcce6d77f08563a5a20606f7d019bd632f9090e (diff) | |
download | hdf5-14b00edf0aeb92c493205b41748f50cb89eaa055.zip hdf5-14b00edf0aeb92c493205b41748f50cb89eaa055.tar.gz hdf5-14b00edf0aeb92c493205b41748f50cb89eaa055.tar.bz2 |
[svn-r5403] Purpose:
Back out changes.
Description:
Back out changes to VFL 'flush' API function, pending review.
Platforms tested:
IRIX64 6.5 (modi4)
Diffstat (limited to 'src/H5F.c')
-rw-r--r-- | src/H5F.c | 28 |
1 files changed, 11 insertions, 17 deletions
@@ -65,7 +65,7 @@ typedef struct H5F_olist_t { static H5F_t *H5F_new(H5F_file_t *shared, hid_t fcpl_id, hid_t fapl_id); static herr_t H5F_dest(H5F_t *f); static herr_t H5F_flush(H5F_t *f, H5F_scope_t scope, hbool_t invalidate, - hbool_t alloc_only, hbool_t closing); + hbool_t alloc_only); static haddr_t H5F_locate_signature(H5FD_t *file); static int H5F_flush_all_cb(H5F_t *f, hid_t fid, const void *_invalidate); static herr_t H5F_get_obj_count(H5F_t *f, unsigned types, @@ -631,7 +631,7 @@ static int H5F_flush_all_cb(H5F_t *f, hid_t UNUSED fid, const void *_invalidate) { hbool_t invalidate = *((const hbool_t*)_invalidate); - H5F_flush(f, H5F_SCOPE_LOCAL, invalidate, FALSE, FALSE); + H5F_flush(f, H5F_SCOPE_LOCAL, invalidate, FALSE); return 0; } @@ -1747,7 +1747,7 @@ H5F_open(const char *name, unsigned flags, hid_t fcpl_id, hid_t fapl_id) shared->boot_addr = userblock_size; shared->base_addr = shared->boot_addr; shared->consist_flags = 0x03; - if (H5F_flush(file, H5F_SCOPE_LOCAL, FALSE, TRUE, FALSE)<0) + if (H5F_flush(file, H5F_SCOPE_LOCAL, FALSE, TRUE)<0) HGOTO_ERROR(H5E_FILE, H5E_CANTINIT, NULL, "unable to write file superblock"); /* Create and open the root group */ @@ -2222,7 +2222,7 @@ H5Fflush(hid_t object_id, H5F_scope_t scope) } /* Flush the file */ - if (H5F_flush(f, scope, FALSE, FALSE, FALSE)<0) { + if (H5F_flush(f, scope, FALSE, FALSE)<0) { HRETURN_ERROR(H5E_FILE, H5E_CANTINIT, FAIL, "flush failed"); } @@ -2268,17 +2268,11 @@ H5Fflush(hid_t object_id, H5F_scope_t scope) * Raymond Lu, 2001-10-14 * Changed to new generic property list. * - * Quincey Koziol, 2002-05-10 - * Added new 'closing' parameter to indicate that this function - * is being called immediately before a file is closed. This - * may allow some file drivers to bypass duplicating certain - * syncronizations that are already performed when a file - * closes. *------------------------------------------------------------------------- */ static herr_t H5F_flush(H5F_t *f, H5F_scope_t scope, hbool_t invalidate, - hbool_t alloc_only, hbool_t closing) + hbool_t alloc_only) { uint8_t sbuf[2048], dbuf[2048], *p=NULL; unsigned nerrors=0, i; @@ -2309,7 +2303,7 @@ H5F_flush(H5F_t *f, H5F_scope_t scope, hbool_t invalidate, } if (H5F_SCOPE_DOWN==scope) { for (i=0; i<f->mtab.nmounts; i++) { - if (H5F_flush(f->mtab.child[i].file, scope, invalidate, FALSE, closing)<0) + if (H5F_flush(f->mtab.child[i].file, scope, invalidate, FALSE)<0) nerrors++; } } @@ -2437,7 +2431,7 @@ H5F_flush(H5F_t *f, H5F_scope_t scope, hbool_t invalidate, } /* end else */ /* Flush file buffers to disk */ - if (!alloc_only && H5FD_flush(f->shared->lf, closing)<0) + if (!alloc_only && H5FD_flush(f->shared->lf)<0) HRETURN_ERROR(H5E_IO, H5E_WRITEERROR, FAIL, "low level flush failed"); /* Check flush errors for children - errors are already on the stack */ @@ -2496,7 +2490,7 @@ H5F_close(H5F_t *f) * count, flush the file, and return. */ if (f->nrefs>1) { - if (H5F_flush(f, H5F_SCOPE_LOCAL, FALSE, FALSE, FALSE)<0) { + if (H5F_flush(f, H5F_SCOPE_LOCAL, FALSE, FALSE)<0) { HRETURN_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush cache"); } @@ -2522,7 +2516,7 @@ H5F_close(H5F_t *f) assert(1==f->nrefs); if (1==f->shared->nrefs) { /* Flush and destroy all caches */ - if (H5F_flush(f, H5F_SCOPE_LOCAL, TRUE, FALSE, TRUE)<0) { + if (H5F_flush(f, H5F_SCOPE_LOCAL, TRUE, FALSE)<0) { HRETURN_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush cache"); } @@ -2557,7 +2551,7 @@ H5F_close(H5F_t *f) * instead. */ if (f->nopen_objs>0) { - if (H5F_flush(f, H5F_SCOPE_LOCAL, FALSE, FALSE, TRUE)<0) + if (H5F_flush(f, H5F_SCOPE_LOCAL, FALSE, FALSE)<0) HRETURN_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush cache"); #ifdef H5F_DEBUG @@ -2625,7 +2619,7 @@ H5F_close(H5F_t *f) * this file are closed the flush isn't really necessary, but lets * just be safe. */ - if (H5F_flush(f, H5F_SCOPE_LOCAL, TRUE, FALSE, FALSE)<0) { + if (H5F_flush(f, H5F_SCOPE_LOCAL, TRUE, FALSE)<0) { HRETURN_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush cache"); } |