Diff for /xfs-linux/xfs_bmap.c between versions 1.360 and 1.361

version 1.360, 2006/12/21 02:50:36 version 1.361, 2007/01/10 14:42:05
Line 684  xfs_bmap_add_extent( Line 684  xfs_bmap_add_extent(
                 ASSERT(nblks <= da_old);                  ASSERT(nblks <= da_old);
                 if (nblks < da_old)                  if (nblks < da_old)
                         xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS,                          xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS,
                                 (int)(da_old - nblks), rsvd);                                  (int64_t)(da_old - nblks), rsvd);
         }          }
         /*          /*
          * Clear out the allocated field, done with it now in any case.           * Clear out the allocated field, done with it now in any case.
Line 1209  xfs_bmap_add_extent_delay_real( Line 1209  xfs_bmap_add_extent_delay_real(
                 diff = (int)(temp + temp2 - STARTBLOCKVAL(PREV.br_startblock) -                  diff = (int)(temp + temp2 - STARTBLOCKVAL(PREV.br_startblock) -
                         (cur ? cur->bc_private.b.allocated : 0));                          (cur ? cur->bc_private.b.allocated : 0));
                 if (diff > 0 &&                  if (diff > 0 &&
                     xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS, -diff, rsvd)) {                      xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS, -((int64_t)diff), rsvd)) {
                         /*                          /*
                          * Ick gross gag me with a spoon.                           * Ick gross gag me with a spoon.
                          */                           */
Line 1220  xfs_bmap_add_extent_delay_real( Line 1220  xfs_bmap_add_extent_delay_real(
                                         diff--;                                          diff--;
                                         if (!diff ||                                          if (!diff ||
                                             !xfs_mod_incore_sb(ip->i_mount,                                              !xfs_mod_incore_sb(ip->i_mount,
                                                     XFS_SBS_FDBLOCKS, -diff, rsvd))                                                      XFS_SBS_FDBLOCKS, -((int64_t)diff), rsvd))
                                                 break;                                                  break;
                                 }                                  }
                                 if (temp2) {                                  if (temp2) {
Line 1228  xfs_bmap_add_extent_delay_real( Line 1228  xfs_bmap_add_extent_delay_real(
                                         diff--;                                          diff--;
                                         if (!diff ||                                          if (!diff ||
                                             !xfs_mod_incore_sb(ip->i_mount,                                              !xfs_mod_incore_sb(ip->i_mount,
                                                     XFS_SBS_FDBLOCKS, -diff, rsvd))                                                      XFS_SBS_FDBLOCKS, -((int64_t)diff), rsvd))
                                                 break;                                                  break;
                                 }                                  }
                         }                          }
Line 2015  xfs_bmap_add_extent_hole_delay( Line 2015  xfs_bmap_add_extent_hole_delay(
         if (oldlen != newlen) {          if (oldlen != newlen) {
                 ASSERT(oldlen > newlen);                  ASSERT(oldlen > newlen);
                 xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS,                  xfs_mod_incore_sb(ip->i_mount, XFS_SBS_FDBLOCKS,
                         (int)(oldlen - newlen), rsvd);                          (int64_t)(oldlen - newlen), rsvd);
                 /*                  /*
                  * Nothing to do for disk quota accounting here.                   * Nothing to do for disk quota accounting here.
                  */                   */
Line 3359  xfs_bmap_del_extent( Line 3359  xfs_bmap_del_extent(
          */           */
         ASSERT(da_old >= da_new);          ASSERT(da_old >= da_new);
         if (da_old > da_new)          if (da_old > da_new)
                 xfs_mod_incore_sb(mp, XFS_SBS_FDBLOCKS, (int)(da_old - da_new),                  xfs_mod_incore_sb(mp, XFS_SBS_FDBLOCKS, (int64_t)(da_old - da_new),
                         rsvd);                          rsvd);
         if (delta) {          if (delta) {
                 /* DELTA: report the original extent. */                  /* DELTA: report the original extent. */
Line 4930  xfs_bmapi( Line 4930  xfs_bmapi(
                                 if (rt) {                                  if (rt) {
                                         error = xfs_mod_incore_sb(mp,                                          error = xfs_mod_incore_sb(mp,
                                                         XFS_SBS_FREXTENTS,                                                          XFS_SBS_FREXTENTS,
                                                         -(extsz), (flags &                                                          -((int64_t)extsz), (flags &
                                                         XFS_BMAPI_RSVBLOCKS));                                                          XFS_BMAPI_RSVBLOCKS));
                                 } else {                                  } else {
                                         error = xfs_mod_incore_sb(mp,                                          error = xfs_mod_incore_sb(mp,
                                                         XFS_SBS_FDBLOCKS,                                                          XFS_SBS_FDBLOCKS,
                                                         -(alen), (flags &                                                          -((int64_t)alen), (flags &
                                                         XFS_BMAPI_RSVBLOCKS));                                                          XFS_BMAPI_RSVBLOCKS));
                                 }                                  }
                                 if (!error) {                                  if (!error) {
                                         error = xfs_mod_incore_sb(mp,                                          error = xfs_mod_incore_sb(mp,
                                                         XFS_SBS_FDBLOCKS,                                                          XFS_SBS_FDBLOCKS,
                                                         -(indlen), (flags &                                                          -((int64_t)indlen), (flags &
                                                         XFS_BMAPI_RSVBLOCKS));                                                          XFS_BMAPI_RSVBLOCKS));
                                         if (error && rt)                                          if (error && rt)
                                                 xfs_mod_incore_sb(mp,                                                  xfs_mod_incore_sb(mp,
                                                         XFS_SBS_FREXTENTS,                                                          XFS_SBS_FREXTENTS,
                                                         extsz, (flags &                                                          (int64_t)extsz, (flags &
                                                         XFS_BMAPI_RSVBLOCKS));                                                          XFS_BMAPI_RSVBLOCKS));
                                         else if (error)                                          else if (error)
                                                 xfs_mod_incore_sb(mp,                                                  xfs_mod_incore_sb(mp,
                                                         XFS_SBS_FDBLOCKS,                                                          XFS_SBS_FDBLOCKS,
                                                         alen, (flags &                                                          (int64_t)alen, (flags &
                                                         XFS_BMAPI_RSVBLOCKS));                                                          XFS_BMAPI_RSVBLOCKS));
                                 }                                  }
   
Line 5617  xfs_bunmapi( Line 5617  xfs_bunmapi(
                                 rtexts = XFS_FSB_TO_B(mp, del.br_blockcount);                                  rtexts = XFS_FSB_TO_B(mp, del.br_blockcount);
                                 do_div(rtexts, mp->m_sb.sb_rextsize);                                  do_div(rtexts, mp->m_sb.sb_rextsize);
                                 xfs_mod_incore_sb(mp, XFS_SBS_FREXTENTS,                                  xfs_mod_incore_sb(mp, XFS_SBS_FREXTENTS,
                                                 (int)rtexts, rsvd);                                                  (int64_t)rtexts, rsvd);
                                 (void)XFS_TRANS_RESERVE_QUOTA_NBLKS(mp,                                  (void)XFS_TRANS_RESERVE_QUOTA_NBLKS(mp,
                                         NULL, ip, -((long)del.br_blockcount), 0,                                          NULL, ip, -((long)del.br_blockcount), 0,
                                         XFS_QMOPT_RES_RTBLKS);                                          XFS_QMOPT_RES_RTBLKS);
                         } else {                          } else {
                                 xfs_mod_incore_sb(mp, XFS_SBS_FDBLOCKS,                                  xfs_mod_incore_sb(mp, XFS_SBS_FDBLOCKS,
                                                 (int)del.br_blockcount, rsvd);                                                  (int64_t)del.br_blockcount, rsvd);
                                 (void)XFS_TRANS_RESERVE_QUOTA_NBLKS(mp,                                  (void)XFS_TRANS_RESERVE_QUOTA_NBLKS(mp,
                                         NULL, ip, -((long)del.br_blockcount), 0,                                          NULL, ip, -((long)del.br_blockcount), 0,
                                         XFS_QMOPT_RES_REGBLKS);                                          XFS_QMOPT_RES_REGBLKS);

Removed from v.1.360  
changed lines
  Added in v.1.361


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>