-/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
- * vim:expandtab:shiftwidth=8:tabstop=8:
- *
+/*
* GPL HEADER START
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#define DEBUG_SUBSYSTEM S_LOG
-#ifndef EXPORT_SYMTAB
-#define EXPORT_SYMTAB
-#endif
-
#ifndef __KERNEL__
#include <liblustre.h>
#endif
if (index == 0)
index = 1;
+
+ cfs_spin_lock(&loghandle->lgh_hdr_lock);
+ llh->llh_count++;
if (ext2_set_bit(index, llh->llh_bitmap)) {
CERROR("argh, index %u already set in log bitmap?\n",
index);
+ cfs_spin_unlock(&loghandle->lgh_hdr_lock);
LBUG(); /* should never happen */
}
+ cfs_spin_unlock(&loghandle->lgh_hdr_lock);
+
cathandle->lgh_last_idx = index;
- llh->llh_count++;
llh->llh_tail.lrt_index = index;
CDEBUG(D_RPCTRACE,"new recovery log "LPX64":%x for index %u of catalog "
/*
* Make sure that all cached data is sent.
*/
- llog_sync(ctxt, NULL);
+ llog_sync(ctxt, NULL, 0);
GOTO(release_llh, rc);
release_llh:
rc = llog_cat_put(llh);