close[t:4756] Remove the pwrite_lock_init and destroy functions. Closes #4756.

git-svn-id: file:///svn/toku/tokudb@42143 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
Bradley C. Kuszmaul 2013-04-17 00:00:23 -04:00 committed by Yoni Fogel
parent 6ed9c14269
commit 3e3a5f70cd
2 changed files with 0 additions and 32 deletions

View file

@ -83,18 +83,6 @@ toku_brt_serialize_destroy(void) {
static toku_pthread_mutex_t pwrite_mutex = TOKU_PTHREAD_MUTEX_INITIALIZER;
static int pwrite_is_locked=0;
int
toku_pwrite_lock_init(void) {
int r = toku_pthread_mutex_init(&pwrite_mutex, NULL); resource_assert_zero(r);
return r;
}
int
toku_pwrite_lock_destroy(void) {
int r = toku_pthread_mutex_destroy(&pwrite_mutex); resource_assert_zero(r);
return r;
}
static inline void
lock_for_pwrite (void) {
// Locks the pwrite_mutex.

View file

@ -6489,22 +6489,6 @@ int toku_brt_truncate (BRT brt) {
return r;
}
static int
toku_brt_lock_init(void) {
int r = 0;
if (r==0)
r = toku_pwrite_lock_init();
return r;
}
static int
toku_brt_lock_destroy(void) {
int r = 0;
if (r==0)
r = toku_pwrite_lock_destroy();
return r;
}
int toku_brt_init(void (*ydb_lock_callback)(void),
void (*ydb_unlock_callback)(void),
void (*db_set_brt)(DB*,BRT)) {
@ -6512,8 +6496,6 @@ int toku_brt_init(void (*ydb_lock_callback)(void),
//Portability must be initialized first
if (r==0)
r = toku_portability_init();
if (r==0)
r = toku_brt_lock_init();
if (r==0)
r = toku_checkpoint_init(ydb_lock_callback, ydb_unlock_callback);
if (r == 0)
@ -6527,8 +6509,6 @@ int toku_brt_destroy(void) {
int r = 0;
if (r == 0)
r = toku_brt_serialize_destroy();
if (r==0)
r = toku_brt_lock_destroy();
if (r==0)
r = toku_checkpoint_destroy();
//Portability must be cleaned up last