1. 12 12月, 2009 2 次提交
  2. 18 11月, 2009 2 次提交
    • N
      xfs: copy li_lsn before dropping AIL lock · 6c06f072
      Nathaniel W. Turner 提交于
      Access to log items on the AIL is generally protected by m_ail_lock;
      this is particularly needed when we're getting or setting the 64-bit
      li_lsn on a 32-bit platform.  This patch fixes a couple places where we
      were accessing the log item after dropping the AIL lock on 32-bit
      machines.
      
      This can result in a partially-zeroed log->l_tail_lsn if
      xfs_trans_ail_delete is racing with xfs_trans_ail_update, and in at
      least some cases, this can leave the l_tail_lsn with a zero cycle
      number, which means xlog_space_left will think the log is full (unless
      CONFIG_XFS_DEBUG is set, in which case we'll trip an ASSERT), leading to
      processes stuck forever in xlog_grant_log_space.
      
      Thanks to Adrian VanderSpek for first spotting the race potential and to
      Dave Chinner for debug assistance.
      Signed-off-by: NNathaniel W. Turner <nate@houseofnate.net>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      6c06f072
    • J
      XFS bug in log recover with quota (bugzilla id 855) · 8ec6dba2
      Jan Rekorajski 提交于
      Hi,
      I was hit by a bug in linux 2.6.31 when XFS is not able to recover the
      log after a crash if fs was mounted with quotas. Gory details in XFS
      bugzilla: http://oss.sgi.com/bugzilla/show_bug.cgi?id=855.
      
      It looks like wrong struct is used in buffer length check, and the following
      patch should fix the problem.
      
      xfs_dqblk_t has a size of 104+32 bytes, while xfs_disk_dquot_t is 104 bytes
      long, and this is exactly what I see in system logs - "XFS: dquot too small
      (104) in xlog_recover_do_dquot_trans."
      Signed-off-by: NJan Rekorajski <baggins@sith.mimuw.edu.pl>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      8ec6dba2
  3. 30 10月, 2009 2 次提交
    • R
      xfs: fix xfs_quota remove error · c7ff91d7
      Ryota Yamauchi 提交于
      The xfs_quota returns ENOSYS when remove command is executed.
      Reproducable with following steps.
      
          # mount -t xfs -o uquota /dev/sda7 /mnt/mp1
          # xfs_quota -x -c off -c remove
          XFS_QUOTARM: Function not implemented.
      
      The remove command is allowed during quotaoff, but xfs_fs_set_xstate()
      checks whether quota is running, and it leads to ENOSYS.
      
      To solve this problem, add a check for X_QUOTARM.
      Signed-off-by: NRyota Yamauchi <r-yamauchi@vf.jp.nec.com>
      Signed-off-by: NUtako Kusaka <u-kusaka@wm.jp.nec.com>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      c7ff91d7
    • E
      xfs: free temporary cursor in xfs_dialloc · 3b826386
      Eric Sandeen 提交于
      Commit bd169565 seems
      to have a slight regression where this code path:
      
          if (!--searchdistance) {
              /*
               * Not in range - save last search
               * location and allocate a new inode
               */
              ...
              goto newino;
          }
      
      doesn't free the temporary cursor (tcur) that got dup'd in
      this function.
      
      This leaks an item in the xfs_btree_cur zone, and it's caught
      on module unload:
      
      ===========================================================
      BUG xfs_btree_cur: Objects remaining on kmem_cache_close()
      -----------------------------------------------------------
      
      It seems like maybe a single free at the end of the function might
      be cleaner, but for now put a del_cursor right in this code block
      similar to the handling in the rest of the function.
      Signed-off-by: NEric Sandeen <sandeen@sandeen.net>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      3b826386
  4. 14 10月, 2009 1 次提交
  5. 09 10月, 2009 7 次提交
  6. 28 9月, 2009 1 次提交
  7. 24 9月, 2009 1 次提交
  8. 22 9月, 2009 2 次提交
  9. 21 9月, 2009 1 次提交
  10. 16 9月, 2009 3 次提交
  11. 14 9月, 2009 1 次提交
  12. 10 9月, 2009 1 次提交
  13. 09 9月, 2009 1 次提交
  14. 03 9月, 2009 1 次提交
    • A
      xfs: xfs_showargs() reports group *and* project quotas enabled · 988abe40
      Alex Elder 提交于
      If you enable group or project quotas on an XFS file system, then the
      mount table presented through /proc/self/mounts erroneously shows
      that both options are in effect for the file system.  The root of
      the problem is some bad logic in the xfs_showargs() function, which
      is used to format the file system type-specific options in effect
      for a file system.
      
      The problem originated in this GIT commit:
          Move platform specific mount option parse out of core XFS code
          Date: 11/22/07
          Author: Dave Chinner
          SHA1 ID: a67d7c5f
      
      For XFS quotas, project and group quota management are mutually
      exclusive--only one can be in effect at a time.  There are two
      parts to managing quotas:  aggregating usage information; and
      enforcing limits.  It is possible to have a quota in effect
      (aggregating usage) but not enforced.
      
      These features are recorded on an XFS mount point using these flags:
          XFS_PQUOTA_ACCT - Project quotas are aggregated
          XFS_GQUOTA_ACCT - Group quotas are aggregated
          XFS_OQUOTA_ENFD - Project/group quotas are enforced
      
      The code in error is in fs/xfs/linux-2.6/xfs_super.c:
      
              if (mp->m_qflags & (XFS_PQUOTA_ACCT|XFS_OQUOTA_ENFD))
                      seq_puts(m, "," MNTOPT_PRJQUOTA);
              else if (mp->m_qflags & XFS_PQUOTA_ACCT)
                      seq_puts(m, "," MNTOPT_PQUOTANOENF);
      
              if (mp->m_qflags & (XFS_GQUOTA_ACCT|XFS_OQUOTA_ENFD))
                      seq_puts(m, "," MNTOPT_GRPQUOTA);
              else if (mp->m_qflags & XFS_GQUOTA_ACCT)
                      seq_puts(m, "," MNTOPT_GQUOTANOENF);
      
      The problem is that XFS_OQUOTA_ENFD will be set in mp->m_qflags
      if either group or project quotas are enforced, and as a result
      both MNTOPT_PRJQUOTA and MNTOPT_GRPQUOTA will be shown as mount
      options.
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NFelix Blyakher <felixb@sgi.com>
      988abe40
  15. 02 9月, 2009 12 次提交
  16. 01 9月, 2009 2 次提交