Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
jfs_txnmgr.c File Reference
#include <linux/fs.h>
#include <linux/vmalloc.h>
#include <linux/completion.h>
#include <linux/freezer.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/kthread.h>
#include <linux/seq_file.h>
#include "jfs_incore.h"
#include "jfs_inode.h"
#include "jfs_filsys.h"
#include "jfs_metapage.h"
#include "jfs_dinode.h"
#include "jfs_imap.h"
#include "jfs_dmap.h"
#include "jfs_superblock.h"
#include "jfs_debug.h"

Go to the source code of this file.

Macros

#define TXN_LOCK()   spin_lock(&jfsTxnLock)
 
#define TXN_UNLOCK()   spin_unlock(&jfsTxnLock)
 
#define LAZY_LOCK_INIT()   spin_lock_init(&TxAnchor.LazyLock);
 
#define LAZY_LOCK(flags)   spin_lock_irqsave(&TxAnchor.LazyLock, flags)
 
#define LAZY_UNLOCK(flags)   spin_unlock_irqrestore(&TxAnchor.LazyLock, flags)
 
#define TXN_SLEEP(event)
 
#define TXN_WAKEUP(event)   wake_up_all(event)
 

Functions

 module_param (nTxBlock, int, 0)
 
 MODULE_PARM_DESC (nTxBlock,"Number of transaction blocks (max:65536)")
 
 module_param (nTxLock, int, 0)
 
 MODULE_PARM_DESC (nTxLock,"Number of transaction locks (max:65536)")
 
int txInit (void)
 
void txExit (void)
 
tid_t txBegin (struct super_block *sb, int flag)
 
void txBeginAnon (struct super_block *sb)
 
void txEnd (tid_t tid)
 
struct tlocktxLock (tid_t tid, struct inode *ip, struct metapage *mp, int type)
 
struct tlocktxMaplock (tid_t tid, struct inode *ip, int type)
 
struct linelocktxLinelock (struct linelock *tlock)
 
int txCommit (tid_t tid, int nip, struct inode **iplist, int flag)
 
void txEA (tid_t tid, struct inode *ip, dxd_t *oldea, dxd_t *newea)
 
void txFreeMap (struct inode *ip, struct maplock *maplock, struct tblock *tblk, int maptype)
 
void txFreelock (struct inode *ip)
 
void txAbort (tid_t tid, int dirty)
 
int jfs_lazycommit (void *arg)
 
void txLazyUnlock (struct tblock *tblk)
 
void txQuiesce (struct super_block *sb)
 
void txResume (struct super_block *sb)
 
int jfs_sync (void *arg)
 

Variables

int jfs_tlocks_low
 
struct tblockTxBlock
 
struct tlockTxLock
 

Macro Definition Documentation

#define LAZY_LOCK (   flags)    spin_lock_irqsave(&TxAnchor.LazyLock, flags)

Definition at line 122 of file jfs_txnmgr.c.

#define LAZY_LOCK_INIT ( )    spin_lock_init(&TxAnchor.LazyLock);

Definition at line 121 of file jfs_txnmgr.c.

#define LAZY_UNLOCK (   flags)    spin_unlock_irqrestore(&TxAnchor.LazyLock, flags)

Definition at line 123 of file jfs_txnmgr.c.

#define TXN_LOCK ( )    spin_lock(&jfsTxnLock)

Definition at line 118 of file jfs_txnmgr.c.

#define TXN_SLEEP (   event)
Value:
{\
TXN_SLEEP_DROP_LOCK(event);\
TXN_LOCK();\
}

Definition at line 143 of file jfs_txnmgr.c.

#define TXN_UNLOCK ( )    spin_unlock(&jfsTxnLock)

Definition at line 119 of file jfs_txnmgr.c.

#define TXN_WAKEUP (   event)    wake_up_all(event)

Definition at line 149 of file jfs_txnmgr.c.

Function Documentation

int jfs_lazycommit ( void arg)

Definition at line 2748 of file jfs_txnmgr.c.

int jfs_sync ( void arg)

Definition at line 2933 of file jfs_txnmgr.c.

module_param ( nTxBlock  ,
int  ,
 
)
module_param ( nTxLock  ,
int  ,
 
)
MODULE_PARM_DESC ( nTxBlock  ,
"Number of transaction blocks (max:65536)"   
)
MODULE_PARM_DESC ( nTxLock  ,
"Number of transaction locks (max:65536)"   
)
void txAbort ( tid_t  tid,
int  dirty 
)

Definition at line 2643 of file jfs_txnmgr.c.

tid_t txBegin ( struct super_block sb,
int  flag 
)

Definition at line 362 of file jfs_txnmgr.c.

void txBeginAnon ( struct super_block sb)

Definition at line 461 of file jfs_txnmgr.c.

int txCommit ( tid_t  tid,
int  nip,
struct inode **  iplist,
int  flag 
)

Definition at line 1136 of file jfs_txnmgr.c.

void txEA ( tid_t  tid,
struct inode ip,
dxd_t oldea,
dxd_t newea 
)

Definition at line 2174 of file jfs_txnmgr.c.

void txEnd ( tid_t  tid)

Definition at line 501 of file jfs_txnmgr.c.

void txExit ( void  )

Definition at line 341 of file jfs_txnmgr.c.

void txFreelock ( struct inode ip)

Definition at line 2597 of file jfs_txnmgr.c.

void txFreeMap ( struct inode ip,
struct maplock maplock,
struct tblock tblk,
int  maptype 
)

Definition at line 2498 of file jfs_txnmgr.c.

int txInit ( void  )

Definition at line 239 of file jfs_txnmgr.c.

void txLazyUnlock ( struct tblock tblk)

Definition at line 2823 of file jfs_txnmgr.c.

struct linelock* txLinelock ( struct linelock tlock)
read

Definition at line 1069 of file jfs_txnmgr.c.

struct tlock* txLock ( tid_t  tid,
struct inode ip,
struct metapage mp,
int  type 
)
read

Definition at line 591 of file jfs_txnmgr.c.

struct tlock* txMaplock ( tid_t  tid,
struct inode ip,
int  type 
)
read

Definition at line 996 of file jfs_txnmgr.c.

void txQuiesce ( struct super_block sb)

Definition at line 2861 of file jfs_txnmgr.c.

void txResume ( struct super_block sb)

Definition at line 2918 of file jfs_txnmgr.c.

Variable Documentation

struct list_head anon_list

Definition at line 76 of file jfs_txnmgr.c.

struct list_head anon_list2

Definition at line 77 of file jfs_txnmgr.c.

int freelock

Definition at line 68 of file jfs_txnmgr.c.

wait_queue_head_t freelockwait

Definition at line 70 of file jfs_txnmgr.c.

int freetid

Definition at line 67 of file jfs_txnmgr.c.

Definition at line 69 of file jfs_txnmgr.c.

int jfs_tlocks_low

Definition at line 81 of file jfs_txnmgr.c.

spinlock_t LazyLock

Definition at line 73 of file jfs_txnmgr.c.

wait_queue_head_t lowlockwait

Definition at line 71 of file jfs_txnmgr.c.

lid_t maxlid

Definition at line 156 of file jfs_txnmgr.c.

tid_t maxtid

Definition at line 155 of file jfs_txnmgr.c.

int nlid

Definition at line 158 of file jfs_txnmgr.c.

int ntid

Definition at line 157 of file jfs_txnmgr.c.

int tlocksInUse

Definition at line 72 of file jfs_txnmgr.c.

struct tblock* TxBlock

Definition at line 107 of file jfs_txnmgr.c.

struct tlock* TxLock

Definition at line 111 of file jfs_txnmgr.c.

struct list_head unlock_queue

Definition at line 75 of file jfs_txnmgr.c.

int waitlock

Definition at line 159 of file jfs_txnmgr.c.