1. 08 Jun, 2009 1 commit
    • Christoph Hellwig's avatar
      xfs: kill xfs_qmops · 7d095257
      Christoph Hellwig authored
      
      Kill the quota ops function vector and replace it with direct calls or
      stubs in the CONFIG_XFS_QUOTA=n case.
      
      Make sure we check XFS_IS_QUOTA_RUNNING in the right spots.  We can remove
      the number of those checks because the XFS_TRANS_DQ_DIRTY flag can't be set
      otherwise.
      
      This brings us back closer to the way this code worked in IRIX and earlier
      Linux versions, but we keep a lot of the more useful factoring of common
      code.
      
      Eventually we should also kill xfs_qm_bhv.c, but that's left for a later
      patch.
      
      Reduces the size of the source code by about 250 lines and the size of
      XFS module by about 1.5 kilobytes with quotas enabled:
      
         text	   data	    bss	    dec	    hex	filename
       615957	   2960	   3848	 622765	  980ad	fs/xfs/xfs.o
       617231	   3152	   3848	 624231	  98667	fs/xfs/xfs.o.old
      
      Fallout:
      
       - xfs_qm_dqattach is split into xfs_qm_dqattach_locked which expects
         the inode locked and xfs_qm_dqattach which does the locking around it,
         thus removing XFS_QMOPT_ILOCKED.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Reviewed-by: default avatarEric Sandeen <sandeen@sandeen.net>
      7d095257
  2. 06 Apr, 2009 1 commit
    • Dave Chinner's avatar
      xfs: use xfs_sync_inodes() for device flushing · a8d770d9
      Dave Chinner authored
      
      Currently xfs_device_flush calls sync_blockdev() which is
      a no-op for XFS as all it's metadata is held in a different
      address to the one sync_blockdev() works on.
      
      Call xfs_sync_inodes() instead to flush all the delayed
      allocation blocks out. To do this as efficiently as possible,
      do it via two passes - one to do an async flush of all the
      dirty blocks and a second to wait for all the IO to complete.
      This requires some modification to the xfs-sync_inodes_ag()
      flush code to do efficiently.
      Signed-off-by: default avatarDave Chinner <david@fromorbit.com>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      a8d770d9
  3. 29 Mar, 2009 4 commits
  4. 09 Feb, 2009 2 commits
  5. 04 Feb, 2009 1 commit
  6. 19 Jan, 2009 3 commits
  7. 16 Jan, 2009 1 commit
  8. 11 Dec, 2008 1 commit
    • Christoph Hellwig's avatar
      [XFS] resync headers with libxfs · 6d73cf13
      Christoph Hellwig authored
      
       - xfs_sb.h add the XFS_SB_VERSION2_PARENTBIT features2 that has been
         around in userspace for some time
       - xfs_inode.h: move a few things out of __KERNEL__ that are needed by
         userspace
       - xfs_mount.h: only include xfs_sync.h under __KERNEL__
       - xfs_inode.c: minor whitespace fixup.  I accidentaly changes this when
         importing this file for use by userspace.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
      6d73cf13
  9. 04 Dec, 2008 5 commits
  10. 01 Dec, 2008 2 commits
  11. 30 Oct, 2008 10 commits
  12. 13 Aug, 2008 2 commits
  13. 28 Jul, 2008 5 commits
    • Christoph Hellwig's avatar
      [XFS] streamline init/exit path · 9f8868ff
      Christoph Hellwig authored
      
      Currently the xfs module init/exit code is a mess. It's farmed out over a
      lot of function with very little error checking. This patch makes sure we
      propagate all initialization failures properly and clean up after them.
      Various runtime initializations are replaced with compile-time
      initializations where possible to make this easier. The exit path is
      similarly consolidated.
      
      There's now split out function to create/destroy the kmem zones and
      alloc/free the trace buffers. I've also changed the ktrace allocations to
      KM_MAYFAIL and handled errors resulting from that.
      
      And yes, we really should replace the XFS_*_TRACE ifdefs with a single
      XFS_TRACE..
      
      SGI-PV: 976035
      
      SGI-Modid: xfs-linux-melb:xfs-kern:31354a
      Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
      9f8868ff
    • Barry Naujok's avatar
      [XFS] Name operation vector for hash and compare · 5163f95a
      Barry Naujok authored
      
      Adds two pieces of functionality for the basis of case-insensitive support
      in XFS:
      
      1. A comparison result enumerated type: xfs_dacmp. It represents an
      
      exact match, case-insensitive match or no match at all. This patch
      
      only implements different and exact results.
      
      2. xfs_nameops vector for specifying how to perform the hash generation
      
      of filenames and comparision methods. In this patch the hash vector
      
      points to the existing xfs_da_hashname function and the comparison
      
      method does a length compare, and if the same, does a memcmp and
      
      return the xfs_dacmp result.
      
      All filename functions that use the hash (create, lookup remove, rename,
      etc) now use the xfs_nameops.hashname function and all directory lookup
      functions also use the xfs_nameops.compname function.
      
      The lookup functions also handle case-insensitive results even though the
      default comparison function cannot return that. And important aspect of
      the lookup functions is that an exact match always has precedence over a
      case-insensitive. So while a case-insensitive match is found, we have to
      keep looking just in case there is an exact match. In the meantime, the
      info for the first case-insensitive match is retained if no exact match is
      found.
      
      SGI-PV: 981519
      SGI-Modid: xfs-linux-melb:xfs-kern:31205a
      Signed-off-by: default avatarBarry Naujok <bnaujok@sgi.com>
      Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
      5163f95a
    • Christoph Hellwig's avatar
      [XFS] kill xfs_mount_init · c962fb79
      Christoph Hellwig authored
      
      xfs_mount_init is inlined into xfs_fs_fill_super and allocation switched
      to kzalloc. Plug a leak of the mount structure for most early mount
      failures. Move xfs_icsb_init_counters to as late as possible in the mount
      path and make sure to undo it so that no stale hotplug cpu notifiers are
      left around on mount failures.
      
      SGI-PV: 981951
      SGI-Modid: xfs-linux-melb:xfs-kern:31196a
      Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
      Signed-off-by: default avatarDavid Chinner <dgc@sgi.com>
      Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
      c962fb79
    • Christoph Hellwig's avatar
      [XFS] sort out opening and closing of the block devices · 19f354d4
      Christoph Hellwig authored
      
      Currently closing the rt/log block device is done in the wrong spot, and
      far too early. So revampt it:
      
      - xfs_blkdev_put moved out of xfs_free_buftarg into the caller so that
      
      it is done after tearing down the buftarg completely.
      
      - call to xfs_unmountfs_close moved from xfs_mountfs into caller so
      
      that it's done after tearing down the filesystem completely.
      
      - xfs_unmountfs_close is renamed to xfs_close_devices and made static
      
      in xfs_super.c
      
      - opening of the block devices is split into a helper xfs_open_devices
      
      that is symetric in use to xfs_close_devices
      
      - xfs_unmountfs can now lose struct cred
      
      - error handling around device opening sanitized in xfs_fs_fill_super
      
      SGI-PV: 981951
      SGI-Modid: xfs-linux-melb:xfs-kern:31193a
      Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
      Signed-off-by: default avatarDavid Chinner <dgc@sgi.com>
      Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
      19f354d4
    • Tim Shimmin's avatar
      [XFS] Fix up noattr2 so that it will properly update the versionnum and · 7c12f296
      Tim Shimmin authored
      features2 fields.
      
      Previously, mounting with noattr2 failed to achieve anything because
      although it cleared the attr2 mount flag, it would set it again as soon as
      it processed the superblock fields. The fix now has an explicit noattr2
      flag and uses it later to fix up the versionnum and features2 fields.
      
      SGI-PV: 980021
      SGI-Modid: xfs-linux-melb:xfs-kern:31003a
      Signed-off-by: default avatarTim Shimmin <tes@sgi.com>
      Signed-off-by: default avatarChristoph Hellwig <hch@infradead.org>
      Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
      7c12f296
  14. 29 Apr, 2008 2 commits