• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/fs/jfs/

Lines Matching refs:tblk

102 #define LOGGC_WAKEUP(tblk)	wake_up_all(&(tblk)->gcwait)
173 static int lmWriteRecord(struct jfs_log * log, struct tblock * tblk,
224 int lmLog(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd,
232 jfs_info("lmLog: log:0x%p tblk:0x%p, lrd:0x%p tlck:0x%p",
233 log, tblk, lrd, tlck);
238 if (tblk == NULL)
283 if (tblk->lsn == 0) {
285 tblk->lsn = mp->lsn;
289 list_add(&tblk->synclist, &mp->synclist);
297 logdiff(difft, tblk->lsn, log);
300 tblk->lsn = mp->lsn;
303 list_move(&tblk->synclist, &mp->synclist);
313 lsn = lmWriteRecord(log, tblk, lrd, tlck);
343 lmWriteRecord(struct jfs_log * log, struct tblock * tblk, struct lrd * lrd,
499 tblk->clsn = lsn;
500 jfs_info("wr: tclsn:0x%x, beor:0x%x", tblk->clsn,
516 tblk->flag = tblkGC_QUEUE;
517 tblk->bp = log->bp;
518 tblk->pn = log->page;
519 tblk->eor = log->eor;
522 list_add_tail(&tblk->cqueue, &log->cqueue);
566 struct tblock *tblk;
579 /* get the tail tblk on commit queue */
581 tblk = NULL;
583 tblk = list_entry(log->cqueue.prev, struct tblock, cqueue);
585 /* every tblk who has COMMIT record on the current page,
587 * since tblk is queued at commit queueu at the time
589 * page becomes full (even though the tblk thread
594 /* is page bound with outstanding tail tblk ? */
595 if (tblk && tblk->pn == pn) {
596 /* mark tblk for end-of-page */
597 tblk->flag |= tblkGC_EOP;
616 /* page is not bound with outstanding tblk:
665 int lmGroupCommit(struct jfs_log * log, struct tblock * tblk)
672 if (tblk->flag & tblkGC_COMMITTED) {
673 if (tblk->flag & tblkGC_ERROR)
679 jfs_info("lmGroup Commit: tblk = 0x%p, gcrtc = %d", tblk, log->gcrtc);
681 if (tblk->xflag & COMMIT_LAZY)
682 tblk->flag |= tblkGC_LAZY;
685 (!(tblk->xflag & COMMIT_LAZY) || test_bit(log_FLUSH, &log->flag)
697 if (tblk->xflag & COMMIT_LAZY) {
707 if (tblk->flag & tblkGC_COMMITTED) {
708 if (tblk->flag & tblkGC_ERROR)
718 tblk->flag |= tblkGC_READY;
720 __SLEEP_COND(tblk->gcwait, (tblk->flag & tblkGC_COMMITTED),
724 if (tblk->flag & tblkGC_ERROR)
749 struct tblock *tblk;
758 /* get the head tblk on the commit queue */
761 list_for_each_entry(tblk, &log->cqueue, cqueue) {
762 if (tblk->pn != gcpn)
765 xtblk = tblk;
768 tblk->flag |= tblkGC_COMMIT;
770 tblk = xtblk; /* last tblk of the page */
775 bp = (struct lbuf *) tblk->bp;
778 if (tblk->flag & tblkGC_EOP) {
780 tblk->flag &= ~tblkGC_EOP;
781 tblk->flag |= tblkGC_FREE;
790 bp->l_ceor = tblk->eor; /* ? bp->l_ceor = bp->l_eor; */
814 struct tblock *tblk, *temp;
824 list_for_each_entry_safe(tblk, temp, &log->cqueue, cqueue) {
825 if (!(tblk->flag & tblkGC_COMMIT))
833 tblk->flag |= tblkGC_ERROR;
836 list_del(&tblk->cqueue);
837 tblk->flag &= ~tblkGC_QUEUE;
839 if (tblk == log->flush_tblk) {
845 jfs_info("lmPostGC: tblk = 0x%p, flag = 0x%x", tblk,
846 tblk->flag);
848 if (!(tblk->xflag & COMMIT_FORCE))
850 * Hand tblk over to lazy commit thread
852 txLazyUnlock(tblk);
855 tblk->flag |= tblkGC_COMMITTED;
857 if (tblk->flag & tblkGC_READY)
860 LOGGC_WAKEUP(tblk);
864 * (and this is the last tblk bound with the page)
866 if (tblk->flag & tblkGC_FREE)
869 * (and this is the last tblk bound with the page)
871 else if (tblk->flag & tblkGC_EOP) {
891 ((log->gcrtc > 0) || (tblk->bp->l_wqnext != NULL) ||
2286 * redrive next page without any bound tblk