1. 01 Dec, 2008 8 commits
    • Eric Sandeen's avatar
      [XFS] Add new getbmap flags. · 5af317c9
      Eric Sandeen authored
      This adds a new output flag, BMV_OF_LAST to indicate if we've hit
      the last extent in the inode.  This potentially saves an extra call
      from userspace to see when the whole mapping is done.
      
      It also adds BMV_IF_DELALLOC and BMV_OF_DELALLOC to request, and
      indicate, delayed-allocation extents.  In this case bmv_block
      is set to -2 (-1 was already taken for HOLESTARTBLOCK; unfortunately
      these are the reverse of the in-kernel constants.)
      
      These new flags facilitate addition of the new fiemap interface.
      
      Rather than adding sh_delalloc, remove sh_unwritten & just test
      the flags directly.
      Signed-off-by: default avatarEric Sandeen <sandeen@sandeen.net>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      5af317c9
    • Eric Sandeen's avatar
      [XFS] convert xfs_getbmap to take formatter functions · 8a7141a8
      Eric Sandeen authored
      Preliminary work to hook up fiemap, this allows us to pass in an
      arbitrary formatter to copy extent data back to userspace.
      
      The formatter takes info for 1 extent, a pointer to the user "thing*"
      and a pointer to a "filled" variable to indicate whether a userspace
      buffer did get filled in (for fiemap, hole "extents" are skipped).
      
      I'm just using the getbmapx struct as a "common denominator" because
      as far as I can see, it holds all info that any formatters will care
      about.
      
      ("*thing" because fiemap doesn't pass the user pointer around, but rather
      has a pointer to a fiemap info structure, and helpers associated with it)
      Signed-off-by: default avatarEric Sandeen <sandeen@sandeen.net>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      8a7141a8
    • Dave Chinner's avatar
      [XFS] fix uninitialised variable bug in dquot release. · 0924b585
      Dave Chinner authored
      gcc is warning about an uninitialised variable in xfs_growfs_rt().
      This is a false positive. Fix it by changing the scope of the
      transaction pointer to wholly within the internal loop inside
      the function.
      
      While there, preemptively change xfs_growfs_rt_alloc() in the
      same way as it has exactly the same structure as xfs_growfs_rt()
      but gcc is not warning about it. Yet.
      Signed-off-by: default avatarDave Chinner <david@fromorbit.com>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      0924b585
    • Dave Chinner's avatar
      [XFS] fix error inversion problems with data flushing · 2e656092
      Dave Chinner authored
      XFS gets the sign of the error wrong in several places when
      gathering the error from generic linux functions. These functions
      return negative error values, while the core XFS code returns
      positive error values. Hence when XFS inverts the error to be
      returned to the VFS, it can incorrectly invert a negative
      error and this error will be ignored by the syscall return.
      
      Fix all the problems related to calling filemap_* functions.
      
      Problem initially identified by Nick Piggin in xfs_fsync().
      Signed-off-by: default avatarDave Chinner <david@fromorbit.com>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      2e656092
    • Christoph Hellwig's avatar
      [XFS] fix spurious gcc warnings · 65795910
      Christoph Hellwig authored
      Some recent gcc warnings don't like passing string variables to
      printf-like functions without using at least a "%s" format string.
      Change the two occurances of that in xfs to please gcc.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Reviewed-by: default avatarEric Sandeen <sandeen@sandeen.net>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      65795910
    • Christoph Hellwig's avatar
      [XFS] allow inode64 mount option on 32 bit systems · 6c31b93a
      Christoph Hellwig authored
      Now that we've stopped using the Linux inode cache when can trivally
      support the inode64 mount option on 32bit architectures.  As far as the
      kernel and most userspace is concerned this works perfectly, but
      applications still using really old stat and readdir interfaces will get
      an EOVERFLOW error when hitting an inode number not fitting into 32
      bits (that problem of course also exists when using these applications
      on a 64bit kernel).
      
      Note that because inode64 is simply a mount option we can currently
      mount a filesystem having > 32 bit inode numbers and cause a variety of
      problems, all this is solved but this patch which enables XFS_BIG_INUMS,
      even when inode64 is not used.
      
      (First sent on October 18th)
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Reviewed-by: default avatarDave Chinner <david@fromorbit.com>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      6c31b93a
    • Christoph Hellwig's avatar
      [XFS] wire up ->open for directories · f999a5bf
      Christoph Hellwig authored
      Currently there's no ->open method set for directories on XFS.  That
      means we don't perform any check for opening too large directories
      without O_LARGEFILE, we don't check for shut down filesystems, and we
      don't actually do the readahead for the first block in the directory.
      
      Instead of just setting the directories open routine to xfs_file_open
      we merge the shutdown check directly into xfs_file_open and create
      a new xfs_dir_open that first calls xfs_file_open and then performs
      the readahead for block 0.
      
      (First sent on September 29th)
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Reviewed-by: default avatarDave Chinner <david@fromorbit.com>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      f999a5bf
    • Christoph Hellwig's avatar
      [XFS] fix NULL pointer dereference in xfs_log_force_umount · bac8dca9
      Christoph Hellwig authored
      xfs_log_force_umount may be called very early during log recovery where
      
      If we fail a buffer read in xlog_recover_do_inode_trans we abort the mount.
      But at that point log recovery has started delayed writeback of inode
      buffers.   As part of the aborted mount we try to flush out all delwri
      buffers, but at that point we have already freed the superblock, and set
      mp->m_sb_bp to NULL, and xfs_log_force_umount which gets called after
      the inode buffer writeback trips over it.
      
      Make xfs_log_force_umount a little more careful when accessing mp->m_sb_bp
      to avoid this.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Reviewed-by: default avatarEric Sandeen <sandeen@sandeen.net>
      Signed-off-by: default avatarNiv Sardi <xaiki@sgi.com>
      bac8dca9
  2. 28 Nov, 2008 1 commit
  3. 21 Nov, 2008 1 commit
    • Linus Torvalds's avatar
      Merge master.kernel.org:/home/rmk/linux-2.6-arm · ed313489
      Linus Torvalds authored
      * master.kernel.org:/home/rmk/linux-2.6-arm:
        [ARM] 5330/1: mach-pxa: Fixup reset for systems using reboot=cold or other strings
        [ARM] pxa: fix incorrect PCMCIA PSKTSEL pin configuration for spitz
        [ARM] pxa: fix I2C controller device being registered twice on Akita
        pxafb: only initialize the smart panel thread when dealing with a smartpanel
        pxafb: introduce LCD_TYPE_MASK and use it.
      ed313489
  4. 20 Nov, 2008 30 commits