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()
1501 static void dataLog(struct jfs_log *log, struct tblock *tblk, struct lrd *lrd, in dataLog() argument
1510 lrd->log.redopage.type = cpu_to_le16(LOG_DATA); in dataLog()
1511 lrd->log.redopage.l2linesize = cpu_to_le16(L2DATASLOTSIZE); in dataLog()
1513 pxd = &lrd->log.redopage.pxd; in dataLog()
1534 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dataLog()
1547 static void dtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in dtLog() argument
1557 lrd->log.redopage.type = cpu_to_le16(LOG_DTREE); in dtLog()
1558 lrd->log.redopage.l2linesize = cpu_to_le16(L2DTSLOTSIZE); in dtLog()
1560 pxd = &lrd->log.redopage.pxd; in dtLog()
1563 lrd->log.redopage.type |= cpu_to_le16(LOG_BTROOT); in dtLog()
1578 lrd->log.redopage.type |= cpu_to_le16(LOG_EXTEND); in dtLog()
1580 lrd->log.redopage.type |= cpu_to_le16(LOG_NEW); in dtLog()
1584 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dtLog()
1613 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in dtLog()
1635 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in dtLog()
1650 static void xtLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in xtLog() argument
1667 lrd->log.redopage.type = cpu_to_le16(LOG_XTREE); in xtLog()
1668 lrd->log.redopage.l2linesize = cpu_to_le16(L2XTSLOTSIZE); in xtLog()
1670 page_pxd = &lrd->log.redopage.pxd; in xtLog()
1673 lrd->log.redopage.type |= cpu_to_le16(LOG_BTROOT); in xtLog()
1676 lrd->log.redopage.type |= in xtLog()
1703 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1794 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in xtLog()
1800 cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1809 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEXADLIST); in xtLog()
1812 lrd->log.updatemap.nxd = in xtLog()
1818 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1913 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
1927 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEPXD); in xtLog()
1928 lrd->log.updatemap.nxd = cpu_to_le16(1); in xtLog()
1929 lrd->log.updatemap.pxd = pxdlock->pxd; in xtLog()
1932 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in xtLog()
1944 lrd->log.updatemap.type = in xtLog()
1948 lrd->log.updatemap.nxd = in xtLog()
1955 cpu_to_le32(lmLog(log, tblk, lrd, tlck)); in xtLog()
2033 static void mapLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd, in mapLog() argument
2053 pxd = &lrd->log.redopage.pxd; in mapLog()
2055 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2068 lrd->log.updatemap.type = cpu_to_le16(LOG_FREEPXD); in mapLog()
2069 lrd->log.updatemap.nxd = cpu_to_le16(1); in mapLog()
2070 lrd->log.updatemap.pxd = pxdlock->pxd; in mapLog()
2071 lrd->backchain = cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2095 lrd->log.updatemap.type = in mapLog()
2098 lrd->log.updatemap.type = in mapLog()
2100 lrd->log.updatemap.nxd = cpu_to_le16(1); in mapLog()
2101 lrd->log.updatemap.pxd = pxdlock->pxd; in mapLog()
2103 cpu_to_le32(lmLog(log, tblk, lrd, NULL)); in mapLog()
2647 struct jfs_log *log; in txLazyCommit() local
2661 log = (struct jfs_log *) JFS_SBI(tblk->sb)->log; in txLazyCommit()
2663 spin_lock_irq(&log->gclock); // LOGGC_LOCK in txLazyCommit()
2668 log->gcrtc--; in txLazyCommit()
2676 spin_unlock_irq(&log->gclock); // LOGGC_UNLOCK in txLazyCommit()
2681 spin_unlock_irq(&log->gclock); // LOGGC_UNLOCK in txLazyCommit()
2788 struct jfs_log *log = mp->log; in LogSyncRelease() local
2791 assert(log); in LogSyncRelease()
2809 struct jfs_log *log = JFS_SBI(sb)->log; in txQuiesce() local
2812 set_bit(log_QUIESCE, &log->flag); in txQuiesce()
2853 jfs_flush_journal(log, 0); in txQuiesce()
2863 struct jfs_log *log = JFS_SBI(sb)->log; in txResume() local
2865 clear_bit(log_QUIESCE, &log->flag); in txResume()
2866 TXN_WAKEUP(&log->syncwait); in txResume()