diff options
author | Alex Gorrod <alexander.gorrod@mongodb.com> | 2016-05-27 15:51:43 +1000 |
---|---|---|
committer | Alex Gorrod <alexander.gorrod@mongodb.com> | 2016-05-27 15:51:52 +1000 |
commit | f5be31696774455a67ca8c3f6268252d1d4086a4 (patch) | |
tree | 9ab8d44354f28d9e2db7309ab81fc4ae71dc102e /src/third_party/wiredtiger/src/os_posix | |
parent | 832d65c6eec6eb4314b2700a18a332185b5baa36 (diff) | |
download | mongo-f5be31696774455a67ca8c3f6268252d1d4086a4.tar.gz |
Import wiredtiger-wiredtiger-2.8.0-441-g6f9a7a4.tar.gz from wiredtiger branch mongodb-3.4
ref: 636a7b2..6f9a7a4
WT-2554 Implement a framework for adding C test cases
WT-2610 Investigate eviction hazard pointer check
WT-2611 wtperf and/or WT_CONFIG_PARSER do not allow escaped double quotes
WT-2617 Bug in pluggable file system example
WT-2624 snprintf unsupported on MSVC 2013
WT-2626 snprintf errors with macro redefinition on MSVC2015
WT-2627 Coverity complaints
WT-2628 reconciliation can return without unlocking the page lock
WT-2629 Introduction of ppc64le crc32c assembly file has made the stack executable
WT-2630 Rename WT_FSTREAM methods to avoid using C99 reserved names
WT-2632 Test format failures due to "checkpoints cannot be dropped when in-use"
WT-2637 The file-extension documentation doesn't cover not-supported cases
WT-2644 'wt load -r' (rename) fails with LSM
WT-2646 Split the lock_wait flag into two, adding a checkpoint_wait flag
WT-2651 Coverity 1355591 resource leak
WT-2653 the custom file-system example should show device configuration
WT-2656 Builds failing on GCC 4.7 builder
WT-2659 csuite tests, assorted lint and cleanup.
WT-2660 Hang between eviction and connection close
WT-2661 Coverity failures: 1356050-1356053
WT-2662 For internal spell checking, strip out double quote literals, they confuse aspell
SERVER-24151 WiredTiger changes for MongoDB 3.3.7
Diffstat (limited to 'src/third_party/wiredtiger/src/os_posix')
-rw-r--r-- | src/third_party/wiredtiger/src/os_posix/os_fallocate.c | 16 | ||||
-rw-r--r-- | src/third_party/wiredtiger/src/os_posix/os_fs.c | 72 | ||||
-rw-r--r-- | src/third_party/wiredtiger/src/os_posix/os_map.c | 2 |
3 files changed, 55 insertions, 35 deletions
diff --git a/src/third_party/wiredtiger/src/os_posix/os_fallocate.c b/src/third_party/wiredtiger/src/os_posix/os_fallocate.c index a162dbe01a1..9e5d9519900 100644 --- a/src/third_party/wiredtiger/src/os_posix/os_fallocate.c +++ b/src/third_party/wiredtiger/src/os_posix/os_fallocate.c @@ -125,28 +125,28 @@ __wt_posix_file_fallocate(WT_FILE_HANDLE *file_handle, * avoid locking on Linux if at all possible. */ if (__posix_std_fallocate(file_handle, wt_session, offset, len) == 0) { - file_handle->fallocate_nolock = __posix_std_fallocate; - WT_PUBLISH(file_handle->fallocate, NULL); + file_handle->fh_allocate_nolock = __posix_std_fallocate; + WT_PUBLISH(file_handle->fh_allocate, NULL); return (0); } if (__posix_sys_fallocate(file_handle, wt_session, offset, len) == 0) { - file_handle->fallocate_nolock = __posix_sys_fallocate; - WT_PUBLISH(file_handle->fallocate, NULL); + file_handle->fh_allocate_nolock = __posix_sys_fallocate; + WT_PUBLISH(file_handle->fh_allocate, NULL); return (0); } if (__posix_posix_fallocate( file_handle, wt_session, offset, len) == 0) { #if defined(__linux__) - file_handle->fallocate = __posix_posix_fallocate; + file_handle->fh_allocate = __posix_posix_fallocate; WT_WRITE_BARRIER(); #else - file_handle->fallocate_nolock = __posix_posix_fallocate; - WT_PUBLISH(file_handle->fallocate, NULL); + file_handle->fh_allocate_nolock = __posix_posix_fallocate; + WT_PUBLISH(file_handle->fh_allocate, NULL); #endif return (0); } - file_handle->fallocate = NULL; + file_handle->fh_allocate = NULL; WT_WRITE_BARRIER(); return (ENOTSUP); } diff --git a/src/third_party/wiredtiger/src/os_posix/os_fs.c b/src/third_party/wiredtiger/src/os_posix/os_fs.c index ab9c82613d6..c05f75f2bd5 100644 --- a/src/third_party/wiredtiger/src/os_posix/os_fs.c +++ b/src/third_party/wiredtiger/src/os_posix/os_fs.c @@ -1,9 +1,29 @@ /*- - * Copyright (c) 2014-2016 MongoDB, Inc. - * Copyright (c) 2008-2014 WiredTiger, Inc. - * All rights reserved. + * Public Domain 2014-2016 MongoDB, Inc. + * Public Domain 2008-2014 WiredTiger, Inc. * - * See the file LICENSE for redistribution information. + * This is free and unencumbered software released into the public domain. + * + * Anyone is free to copy, modify, publish, use, compile, sell, or + * distribute this software, either in source code form or as a compiled + * binary, for any purpose, commercial or non-commercial, and by any + * means. + * + * In jurisdictions that recognize copyright laws, the author or authors + * of this software dedicate any and all copyright interest in the + * software to the public domain. We make this dedication for the benefit + * of the public at large and to the detriment of our heirs and + * successors. We intend this dedication to be an overt act of + * relinquishment in perpetuity of all present and future rights to this + * software under copyright law. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. + * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR + * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, + * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + * OTHER DEALINGS IN THE SOFTWARE. */ #include "wt_internal.h" @@ -208,7 +228,7 @@ __posix_file_advise(WT_FILE_HANDLE *file_handle, WT_SESSION *wt_session, * handle method to prevent future calls. */ if (ret == EINVAL) { - file_handle->fadvise = NULL; + file_handle->fh_advise = NULL; return (ENOTSUP); } @@ -603,31 +623,31 @@ directory_open: * interesting. */ if (!pfh->direct_io) - file_handle->fadvise = __posix_file_advise; + file_handle->fh_advise = __posix_file_advise; #endif - file_handle->fallocate = __wt_posix_file_fallocate; - file_handle->lock = __posix_file_lock; + file_handle->fh_allocate = __wt_posix_file_fallocate; + file_handle->fh_lock = __posix_file_lock; #ifdef WORDS_BIGENDIAN /* * The underlying objects are little-endian, mapping objects isn't * currently supported on big-endian systems. */ #else - file_handle->map = __wt_posix_map; + file_handle->fh_map = __wt_posix_map; #ifdef HAVE_POSIX_MADVISE - file_handle->map_discard = __wt_posix_map_discard; - file_handle->map_preload = __wt_posix_map_preload; + file_handle->fh_map_discard = __wt_posix_map_discard; + file_handle->fh_map_preload = __wt_posix_map_preload; #endif - file_handle->unmap = __wt_posix_unmap; + file_handle->fh_unmap = __wt_posix_unmap; #endif - file_handle->read = __posix_file_read; - file_handle->size = __posix_file_size; - file_handle->sync = __posix_file_sync; + file_handle->fh_read = __posix_file_read; + file_handle->fh_size = __posix_file_size; + file_handle->fh_sync = __posix_file_sync; #ifdef HAVE_SYNC_FILE_RANGE - file_handle->sync_nowait = __posix_file_sync_nowait; + file_handle->fh_sync_nowait = __posix_file_sync_nowait; #endif - file_handle->truncate = __posix_file_truncate; - file_handle->write = __posix_file_write; + file_handle->fh_truncate = __posix_file_truncate; + file_handle->fh_write = __posix_file_write; *file_handlep = file_handle; @@ -669,16 +689,16 @@ __wt_os_posix(WT_SESSION_IMPL *session) WT_RET(__wt_calloc_one(session, &file_system)); /* Initialize the POSIX jump table. */ - file_system->directory_list = __wt_posix_directory_list; - file_system->directory_list_free = __wt_posix_directory_list_free; + file_system->fs_directory_list = __wt_posix_directory_list; + file_system->fs_directory_list_free = __wt_posix_directory_list_free; #ifdef __linux__ - file_system->directory_sync = __posix_directory_sync; + file_system->fs_directory_sync = __posix_directory_sync; #endif - file_system->exist = __posix_fs_exist; - file_system->open_file = __posix_open_file; - file_system->remove = __posix_fs_remove; - file_system->rename = __posix_fs_rename; - file_system->size = __posix_fs_size; + file_system->fs_exist = __posix_fs_exist; + file_system->fs_open_file = __posix_open_file; + file_system->fs_remove = __posix_fs_remove; + file_system->fs_rename = __posix_fs_rename; + file_system->fs_size = __posix_fs_size; file_system->terminate = __posix_terminate; /* Switch it into place. */ diff --git a/src/third_party/wiredtiger/src/os_posix/os_map.c b/src/third_party/wiredtiger/src/os_posix/os_map.c index 7fde4037250..9cdb58b95c8 100644 --- a/src/third_party/wiredtiger/src/os_posix/os_map.c +++ b/src/third_party/wiredtiger/src/os_posix/os_map.c @@ -40,7 +40,7 @@ __wt_posix_map(WT_FILE_HANDLE *fh, WT_SESSION *wt_session, * underneath us, our caller needs to ensure consistency of the mapped * region vs. any other file activity. */ - WT_RET(fh->size(fh, wt_session, &file_size)); + WT_RET(fh->fh_size(fh, wt_session, &file_size)); len = (size_t)file_size; (void)__wt_verbose(session, WT_VERB_HANDLEOPS, |