vserver 1.9.5.x5
[linux-2.6.git] / fs / xfs / xfs_log_recover.c
index 2e5ab6a..6079aad 100644 (file)
@@ -2047,12 +2047,11 @@ xfs_qm_dqcheck(
                errs++;
        }
 
-       if (! errs) {
+       if (! errs && !INT_ISZERO(ddq->d_id, ARCH_CONVERT)) {
                if (INT_GET(ddq->d_blk_softlimit, ARCH_CONVERT) &&
                    INT_GET(ddq->d_bcount, ARCH_CONVERT) >=
                                INT_GET(ddq->d_blk_softlimit, ARCH_CONVERT)) {
-                       if (INT_ISZERO(ddq->d_btimer, ARCH_CONVERT) &&
-                           !INT_ISZERO(ddq->d_id, ARCH_CONVERT)) {
+                       if (INT_ISZERO(ddq->d_btimer, ARCH_CONVERT)) {
                                if (flags & XFS_QMOPT_DOWARN)
                                        cmn_err(CE_ALERT,
                                        "%s : Dquot ID 0x%x (0x%p) "
@@ -2065,8 +2064,7 @@ xfs_qm_dqcheck(
                if (INT_GET(ddq->d_ino_softlimit, ARCH_CONVERT) &&
                    INT_GET(ddq->d_icount, ARCH_CONVERT) >=
                                INT_GET(ddq->d_ino_softlimit, ARCH_CONVERT)) {
-                       if (INT_ISZERO(ddq->d_itimer, ARCH_CONVERT) &&
-                           !INT_ISZERO(ddq->d_id, ARCH_CONVERT)) {
+                       if (INT_ISZERO(ddq->d_itimer, ARCH_CONVERT)) {
                                if (flags & XFS_QMOPT_DOWARN)
                                        cmn_err(CE_ALERT,
                                        "%s : Dquot ID 0x%x (0x%p) "
@@ -2076,6 +2074,19 @@ xfs_qm_dqcheck(
                                errs++;
                        }
                }
+               if (INT_GET(ddq->d_rtb_softlimit, ARCH_CONVERT) &&
+                   INT_GET(ddq->d_rtbcount, ARCH_CONVERT) >=
+                               INT_GET(ddq->d_rtb_softlimit, ARCH_CONVERT)) {
+                       if (INT_ISZERO(ddq->d_rtbtimer, ARCH_CONVERT)) {
+                               if (flags & XFS_QMOPT_DOWARN)
+                                       cmn_err(CE_ALERT,
+                                       "%s : Dquot ID 0x%x (0x%p) "
+                                       "RTBLK TIMER NOT STARTED",
+                                       str, (int)
+                                       INT_GET(ddq->d_id, ARCH_CONVERT), ddq);
+                               errs++;
+                       }
+               }
        }
 
        if (!errs || !(flags & XFS_QMOPT_DQREPAIR))
@@ -2319,7 +2330,7 @@ xlog_recover_do_inode_trans(
                 * invalidate the buffer when we write it out below.
                 */
                imap.im_blkno = 0;
-               xfs_imap(log->l_mp, 0, ino, &imap, 0);
+               xfs_imap(log->l_mp, NULL, ino, &imap, 0);
        }
 
        /*
@@ -3251,7 +3262,7 @@ xlog_recover_process_iunlinks(
                                xfs_buf_relse(agibp);
 
                                ino = XFS_AGINO_TO_INO(mp, agno, agino);
-                               error = xfs_iget(mp, NULL, ino, 0, &ip, 0);
+                               error = xfs_iget(mp, NULL, ino, 0, 0, &ip, 0);
                                ASSERT(error || (ip != NULL));
 
                                if (!error) {
@@ -3373,10 +3384,11 @@ xlog_pack_data_checksum(
 void
 xlog_pack_data(
        xlog_t                  *log,
-       xlog_in_core_t          *iclog)
+       xlog_in_core_t          *iclog,
+       int                     roundoff)
 {
        int                     i, j, k;
-       int                     size = iclog->ic_offset + iclog->ic_roundoff;
+       int                     size = iclog->ic_offset + roundoff;
        uint                    cycle_lsn;
        xfs_caddr_t             dp;
        xlog_in_core_2_t        *xhdr;