diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2009-03-31 17:32:54 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2009-03-31 17:32:54 (GMT) |
commit | a29e811343bce0275dc44671b767a2eebbf86593 (patch) | |
tree | 11eec69c03676e21a4cbecb7dda280ac76fd1e73 /src/H5EAdblkpage.c | |
parent | 505b31ee08bfd3efc62df84e00602a9fd6c46a4f (diff) | |
download | hdf5-a29e811343bce0275dc44671b767a2eebbf86593.zip hdf5-a29e811343bce0275dc44671b767a2eebbf86593.tar.gz hdf5-a29e811343bce0275dc44671b767a2eebbf86593.tar.bz2 |
[svn-r16634] Description:
Bring r16618:16633 back from trunk to revise_chunks branch.
Tested on:
FreeBSD/32 6.3 (duty) in debug mode
FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (jam) w/PGI compilers, w/C++ & FORTRAN, w/threadsafe,
in debug mode
Linux/64-amd64 2.6 (smirom) w/Intel compilers w/default API=1.6.x,
w/C++ & FORTRAN, in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, in production mode
Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
in production mode
Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in production mode
Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode
Mac OS X/32 10.5.6 (amazon) in debug mode
Mac OS X/32 10.5.6 (amazon) w/C++ & FORTRAN, w/threadsafe,
in production mode
Diffstat (limited to 'src/H5EAdblkpage.c')
-rw-r--r-- | src/H5EAdblkpage.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/H5EAdblkpage.c b/src/H5EAdblkpage.c index a8edae1..429e9f8 100644 --- a/src/H5EAdblkpage.c +++ b/src/H5EAdblkpage.c @@ -100,7 +100,7 @@ H5FL_DEFINE_STATIC(H5EA_dblk_page_t); */ BEGIN_FUNC(PKG, ERR, H5EA_dblk_page_t *, NULL, NULL, -H5EA__dblk_page_alloc(H5EA_hdr_t *hdr)) +H5EA__dblk_page_alloc(H5EA_hdr_t *hdr, H5EA_sblock_t *parent)) /* Local variables */ H5EA_dblk_page_t *dblk_page = NULL; /* Extensible array data block page */ @@ -118,7 +118,7 @@ H5EA__dblk_page_alloc(H5EA_hdr_t *hdr)) dblk_page->hdr = hdr; /* Set non-zero internal fields */ - /* <none> */ + dblk_page->parent = parent; /* Allocate buffer for elements in data block page */ if(NULL == (dblk_page->elmts = H5EA__hdr_alloc_elmts(hdr, hdr->dblk_page_nelmts))) @@ -150,7 +150,8 @@ END_FUNC(PKG) /* end H5EA__dblk_page_alloc() */ */ BEGIN_FUNC(PKG, ERR, herr_t, SUCCEED, FAIL, -H5EA__dblk_page_create(H5EA_hdr_t *hdr, hid_t dxpl_id, haddr_t addr)) +H5EA__dblk_page_create(H5EA_hdr_t *hdr, hid_t dxpl_id, H5EA_sblock_t *parent, + haddr_t addr)) /* Local variables */ H5EA_dblk_page_t *dblk_page = NULL; /* Extensible array data block page */ @@ -163,7 +164,7 @@ HDfprintf(stderr, "%s: Called, addr = %a\n", FUNC, addr); HDassert(hdr); /* Allocate the data block page */ - if(NULL == (dblk_page = H5EA__dblk_page_alloc(hdr))) + if(NULL == (dblk_page = H5EA__dblk_page_alloc(hdr, parent))) H5E_THROW(H5E_CANTALLOC, "memory allocation failed for extensible array data block page") /* Set info about data block page on disk */ @@ -208,10 +209,11 @@ END_FUNC(PKG) /* end H5EA__dblk_page_create() */ */ BEGIN_FUNC(PKG, ERR, H5EA_dblk_page_t *, NULL, NULL, -H5EA__dblk_page_protect(H5EA_hdr_t *hdr, hid_t dxpl_id, haddr_t dblk_page_addr, - H5AC_protect_t rw)) +H5EA__dblk_page_protect(H5EA_hdr_t *hdr, hid_t dxpl_id, H5EA_sblock_t *parent, + haddr_t dblk_page_addr, H5AC_protect_t rw)) /* Local variables */ + H5EA_dblk_page_load_ud_t load_ud; /* Information needed for loading data block page */ #ifdef QAK HDfprintf(stderr, "%s: Called\n", FUNC); @@ -221,8 +223,11 @@ HDfprintf(stderr, "%s: Called\n", FUNC); HDassert(hdr); HDassert(H5F_addr_defined(dblk_page_addr)); + /* Set up user data */ + load_ud.parent = parent; + /* Protect the data block page */ - if(NULL == (ret_value = (H5EA_dblk_page_t *)H5AC_protect(hdr->f, dxpl_id, H5AC_EARRAY_DBLK_PAGE, dblk_page_addr, NULL, hdr, rw))) + if(NULL == (ret_value = (H5EA_dblk_page_t *)H5AC_protect(hdr->f, dxpl_id, H5AC_EARRAY_DBLK_PAGE, dblk_page_addr, &load_ud, hdr, rw))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block page, address = %llu", (unsigned long long)dblk_page_addr) CATCH |