Lines Matching refs:log

151 static void diLog(struct jfs_log *log, struct tblock *tblk, struct lrd *lrd,
153 static void dataLog(struct jfs_log *log, struct tblock *tblk, struct lrd *lrd,
155 static void dtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd,
157 static void mapLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd,
162 static void txLog(struct jfs_log *log, struct tblock *tblk,
166 static void xtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd,
352 struct jfs_log *log; in txBegin() local
355 log = JFS_SBI(sb)->log; in txBegin()
366 if (test_bit(log_SYNCBARRIER, &log->flag) || in txBegin()
367 test_bit(log_QUIESCE, &log->flag)) { in txBegin()
369 TXN_SLEEP(&log->syncwait); in txBegin()
421 ++log->logtid; in txBegin()
422 tblk->logtid = log->logtid; in txBegin()
424 ++log->active; in txBegin()
449 struct jfs_log *log; in txBeginAnon() local
451 log = JFS_SBI(sb)->log; in txBeginAnon()
460 if (test_bit(log_SYNCBARRIER, &log->flag) || in txBeginAnon()
461 test_bit(log_QUIESCE, &log->flag)) { in txBeginAnon()
463 TXN_SLEEP(&log->syncwait); in txBeginAnon()
490 struct jfs_log *log; in txEnd() local
501 log = JFS_SBI(tblk->sb)->log; in txEnd()
515 spin_lock_irq(&log->gclock); // LOGGC_LOCK in txEnd()
517 spin_unlock_irq(&log->gclock); // LOGGC_UNLOCK in txEnd()
534 if (--log->active == 0) { in txEnd()
535 clear_bit(log_FLUSH, &log->flag); in txEnd()
540 if (test_bit(log_SYNCBARRIER, &log->flag)) { in txEnd()
544 jfs_syncpt(log, 1); in txEnd()
546 jfs_info("log barrier off: 0x%x", log->lsn); in txEnd()
549 clear_bit(log_SYNCBARRIER, &log->flag); in txEnd()
552 TXN_WAKEUP(&log->syncwait); in txEnd()
901 struct jfs_log *log; in txUnlock() local
906 log = JFS_SBI(tblk->sb)->log; in txUnlock()
930 LOGSYNC_LOCK(log, flags); in txUnlock()
932 logdiff(difft, tblk->clsn, log); in txUnlock()
933 logdiff(diffp, mp->clsn, log); in txUnlock()
938 LOGSYNC_UNLOCK(log, flags); in txUnlock()
969 LOGSYNC_LOCK(log, flags); in txUnlock()
970 log->count--; in txUnlock()
972 LOGSYNC_UNLOCK(log, flags); in txUnlock()
1129 struct jfs_log *log; in txCommit() local
1155 log = JFS_SBI(sb)->log; in txCommit()
1156 cd.log = log; in txCommit()
1259 txLog(log, tblk, &cd); in txCommit()
1297 lmLog(log, tblk, lrd, NULL); in txCommit()
1299 lmGroupCommit(log, tblk); in txCommit()
1367 static void txLog(struct jfs_log *log, struct tblock *tblk, struct commit *cd) in txLog() argument
1385 lrd->log.redopage.fileset = cpu_to_le32(JFS_IP(ip)->fileset); in txLog()
1386 lrd->log.redopage.inode = cpu_to_le32(ip->i_ino); in txLog()
1391 xtLog(log, tblk, lrd, tlck); in txLog()
1395 dtLog(log, tblk, lrd, tlck); in txLog()
1399 diLog(log, tblk, lrd, tlck, cd); in txLog()
1403 mapLog(log, tblk, lrd, tlck); in txLog()
1407 dataLog(log, tblk, lrd, tlck); in txLog()
1423 static void diLog(struct jfs_log *log, struct tblock *tblk, struct lrd *lrd, in diLog() argument
1433 lrd->log.redopage.type = cpu_to_le16(LOG_INODE); in diLog()
1434 lrd->log.redopage.l2linesize = cpu_to_le16(L2INODESLOTSIZE); in diLog()
1436 pxd = &lrd->log.redopage.pxd; in diLog()
1447 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in diLog()
1477 lrd->log.noredoinoext.iagnum = in diLog()
1479 lrd->log.noredoinoext.inoext_idx = in diLog()
1484 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in diLog()
1511 lrd->log.updatemap.type = in diLog()
1514 lrd->log.updatemap.type = in diLog()
1516 lrd->log.updatemap.nxd = cpu_to_le16(1); in diLog()
1517 lrd->log.updatemap.pxd = pxdlock->pxd; in diLog()
1519 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in diLog()
1535 static void dataLog(struct jfs_log *log, struct tblock *tblk, struct lrd *lrd, in dataLog() argument
1544 lrd->log.redopage.type = cpu_to_le16(LOG_DATA); in dataLog()
1545 lrd->log.redopage.l2linesize = cpu_to_le16(L2DATASLOTSIZE); in dataLog()
1547 pxd = &lrd->log.redopage.pxd; in dataLog()
1568 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dataLog()
1581 static void dtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in dtLog() argument
1591 lrd->log.redopage.type = cpu_to_le16(LOG_DTREE); in dtLog()
1592 lrd->log.redopage.l2linesize = cpu_to_le16(L2DTSLOTSIZE); in dtLog()
1594 pxd = &lrd->log.redopage.pxd; in dtLog()
1597 lrd->log.redopage.type |= cpu_to_le16(LOG_BTROOT); in dtLog()
1612 lrd->log.redopage.type |= cpu_to_le16(LOG_EXTEND); in dtLog()
1614 lrd->log.redopage.type |= cpu_to_le16(LOG_NEW); in dtLog()
1618 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dtLog()
1647 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dtLog()
1669 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in dtLog()
1684 static void xtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in xtLog() argument
1701 lrd->log.redopage.type = cpu_to_le16(LOG_XTREE); in xtLog()
1702 lrd->log.redopage.l2linesize = cpu_to_le16(L2XTSLOTSIZE); in xtLog()
1704 page_pxd = &lrd->log.redopage.pxd; in xtLog()
1707 lrd->log.redopage.type |= cpu_to_le16(LOG_BTROOT); in xtLog()
1710 lrd->log.redopage.type |= in xtLog()
1737 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1828 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in xtLog()
1834 cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1843 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEXADLIST); in xtLog()
1846 lrd->log.updatemap.nxd = in xtLog()
1852 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1947 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1961 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEPXD); in xtLog()
1962 lrd->log.updatemap.nxd = cpu_to_le16(1); in xtLog()
1963 lrd->log.updatemap.pxd = pxdlock->pxd; in xtLog()
1966 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in xtLog()
1978 lrd->log.updatemap.type = in xtLog()
1982 lrd->log.updatemap.nxd = in xtLog()
1989 cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
2067 static void mapLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in mapLog() argument
2087 pxd = &lrd->log.redopage.pxd; in mapLog()
2089 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2102 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEPXD); in mapLog()
2103 lrd->log.updatemap.nxd = cpu_to_le16(1); in mapLog()
2104 lrd->log.updatemap.pxd = pxdlock->pxd; in mapLog()
2105 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2129 lrd->log.updatemap.type = in mapLog()
2132 lrd->log.updatemap.type = in mapLog()
2134 lrd->log.updatemap.nxd = cpu_to_le16(1); in mapLog()
2135 lrd->log.updatemap.pxd = pxdlock->pxd; in mapLog()
2137 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2681 struct jfs_log *log; in txLazyCommit() local
2695 log = (struct jfs_log *) JFS_SBI(tblk->sb)->log; in txLazyCommit()
2697 spin_lock_irq(&log->gclock); // LOGGC_LOCK in txLazyCommit()
2702 log->gcrtc--; in txLazyCommit()
2710 spin_unlock_irq(&log->gclock); // LOGGC_UNLOCK in txLazyCommit()
2715 spin_unlock_irq(&log->gclock); // LOGGC_UNLOCK in txLazyCommit()
2822 struct jfs_log *log = mp->log; in LogSyncRelease() local
2825 assert(log); in LogSyncRelease()
2843 struct jfs_log *log = JFS_SBI(sb)->log; in txQuiesce() local
2846 set_bit(log_QUIESCE, &log->flag); in txQuiesce()
2887 jfs_flush_journal(log, 0); in txQuiesce()
2897 struct jfs_log *log = JFS_SBI(sb)->log; in txResume() local
2899 clear_bit(log_QUIESCE, &log->flag); in txResume()
2900 TXN_WAKEUP(&log->syncwait); in txResume()