1. 19 5月, 2010 2 次提交
    • C
      xfs: enforce synchronous writes in xfs_bwrite · 8c38366f
      Christoph Hellwig 提交于
      xfs_bwrite is used with the intention of synchronously writing out
      buffers, but currently it does not actually clear the async flag if
      that's left from previous writes but instead implements async
      behaviour if it finds it.  Remove the code handling asynchronous
      writes as we've got rid of those entirely outside of the log and
      delwri buffers, and make sure that we clear the async and read flags
      before writing the buffer.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      8c38366f
    • J
      xfs: add blockdev name to kthreads · e2a07812
      Jan Engelhardt 提交于
      This allows to see in `ps` and similar tools which kthreads are
      allotted to which block device/filesystem, similar to what jbd2
      does. As the process name is a fixed 16-char array, no extra
      space is needed in tasks.
      
        PID TTY      STAT   TIME COMMAND
          2 ?        S      0:00 [kthreadd]
        197 ?        S      0:00  \_ [jbd2/sda2-8]
        198 ?        S      0:00  \_ [ext4-dio-unwrit]
        204 ?        S      0:00  \_ [flush-8:0]
       2647 ?        S      0:00  \_ [xfs_mru_cache]
       2648 ?        S      0:00  \_ [xfslogd/0]
       2649 ?        S      0:00  \_ [xfsdatad/0]
       2650 ?        S      0:00  \_ [xfsconvertd/0]
       2651 ?        S      0:00  \_ [xfsbufd/ram0]
       2652 ?        S      0:00  \_ [xfsaild/ram0]
       2653 ?        S      0:00  \_ [xfssyncd/ram0]
      Signed-off-by: NJan Engelhardt <jengelh@medozas.de>
      Reviewed-by: NDave Chinner <david@fromorbit.com>
      e2a07812
  2. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  3. 17 3月, 2010 2 次提交
    • A
      xfs: use scalable vmap API · 8a262e57
      Alex Elder 提交于
      Re-apply a commit that had been reverted due to regressions
      that have since been fixed.
      
          From 95f8e302 Mon Sep 17 00:00:00 2001
          From: Nick Piggin <npiggin@suse.de>
          Date: Tue, 6 Jan 2009 14:43:09 +1100
      
          Implement XFS's large buffer support with the new vmap APIs. See the vmap
          rewrite (db64fe02) for some numbers. The biggest improvement that comes from
          using the new APIs is avoiding the global KVA allocation lock on every call.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      
      Only modifications here were a minor reformat, plus making the patch
      apply given the new use of xfs_buf_is_vmapped().
      Modified-by: NAlex Elder <aelder@sgi.com>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      8a262e57
    • A
      xfs: remove old vmap cache · cd9640a7
      Alex Elder 提交于
      Re-apply a commit that had been reverted due to regressions
      that have since been fixed.
      
          Original commit: d2859751
          Author: Nick Piggin <npiggin@suse.de>
          Date: Tue, 6 Jan 2009 14:40:44 +1100
      
          XFS's vmap batching simply defers a number (up to 64) of vunmaps,
          and keeps track of them in a list. To purge the batch, it just goes
          through the list and calls vunamp on each one. This is pretty poor:
          a global TLB flush is generally still performed on each vunmap, with
          the most expensive parts of the operation being the broadcast IPIs
          and locking involved in the SMP callouts, and the locking involved
          in the vmap management -- none of these are avoided by just batching
          up the calls. I'm actually surprised it ever made much difference.
          (Now that the lazy vmap allocator is upstream, this description is
          not quite right, but the vunmap batching still doesn't seem to do
          much).
      
          Rip all this logic out of XFS completely. I will improve vmap
          performance and scalability directly in subsequent patch.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      
      The only change I made was to use the "new" xfs_buf_is_vmapped()
      function in a place it had been open-coded in the original.
      Modified-by: NAlex Elder <aelder@sgi.com>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      cd9640a7
  4. 06 2月, 2010 1 次提交
  5. 04 2月, 2010 1 次提交
  6. 26 1月, 2010 1 次提交
    • D
      xfs: Sort delayed write buffers before dispatch · 089716aa
      Dave Chinner 提交于
      Currently when the xfsbufd writes delayed write buffers, it pushes
      them to disk in the order they come off the delayed write list. If
      there are lots of buffers ѕpread widely over the disk, this results
      in overwhelming the elevator sort queues in the block layer and we
      end up losing the posibility of merging adjacent buffers to minimise
      the number of IOs.
      
      Use the new generic list_sort function to sort the delwri dispatch
      queue before issue to ensure that the buffers are pushed in the most
      friendly order possible to the lower layers.
      Signed-off-by: NDave Chinner <david@fromorbit.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      089716aa
  7. 02 2月, 2010 1 次提交
    • D
      xfs: Don't issue buffer IO direct from AIL push V2 · d808f617
      Dave Chinner 提交于
      All buffers logged into the AIL are marked as delayed write.
      When the AIL needs to push the buffer out, it issues an async write of the
      buffer. This means that IO patterns are dependent on the order of
      buffers in the AIL.
      
      Instead of flushing the buffer, promote the buffer in the delayed
      write list so that the next time the xfsbufd is run the buffer will
      be flushed by the xfsbufd. Return the state to the xfsaild that the
      buffer was promoted so that the xfsaild knows that it needs to cause
      the xfsbufd to run to flush the buffers that were promoted.
      
      Using the xfsbufd for issuing the IO allows us to dispatch all
      buffer IO from the one queue. This means that we can make much more
      enlightened decisions on what order to flush buffers to disk as
      we don't have multiple places issuing IO. Optimisations to xfsbufd
      will be in a future patch.
      
      Version 2
      - kill XFS_ITEM_FLUSHING as it is now unused.
      Signed-off-by: NDave Chinner <david@fromorbit.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      d808f617
  8. 22 1月, 2010 2 次提交
  9. 20 1月, 2010 1 次提交
  10. 16 1月, 2010 3 次提交
  11. 17 12月, 2009 2 次提交
    • D
      XFS: Free buffer pages array unconditionally · 3fc98b1a
      Dave Chinner 提交于
      The code in xfs_free_buf() only attempts to free the b_pages array if the
      buffer is a page cache backed or page allocated buffer. The extra log buffer
      that is used when the log wraps uses pages that are allocated to a different
      log buffer, but it still has a b_pages array allocated when those pages
      are associated to with the extra buffer in xfs_buf_associate_memory.
      
      Hence we need to always attempt to free the b_pages array when tearing
      down a buffer, not just on buffers that are explicitly marked as page bearing
      buffers. This fixes a leak detected by the kernel memory leak code.
      Signed-off-by: NDave Chinner <david@fromorbit.com>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      3fc98b1a
    • D
      xfs: improve metadata I/O merging in the elevator · 2ee1abad
      Dave Chinner 提交于
      Change all async metadata buffers to use [READ|WRITE]_META I/O types
      so that the I/O doesn't get issued immediately. This allows merging of
      adjacent metadata requests but still prioritises them over bulk data.
      This shows a 10-15% improvement in sequential create speed of small
      files.
      
      Don't include the log buffers in this classification - leave them as
      sync types so they are issued immediately.
      Signed-off-by: NDave Chinner <dgc@sgi.com>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      2ee1abad
  12. 15 12月, 2009 1 次提交
    • C
      xfs: event tracing support · 0b1b213f
      Christoph Hellwig 提交于
      Convert the old xfs tracing support that could only be used with the
      out of tree kdb and xfsidbg patches to use the generic event tracer.
      
      To use it make sure CONFIG_EVENT_TRACING is enabled and then enable
      all xfs trace channels by:
      
         echo 1 > /sys/kernel/debug/tracing/events/xfs/enable
      
      or alternatively enable single events by just doing the same in one
      event subdirectory, e.g.
      
         echo 1 > /sys/kernel/debug/tracing/events/xfs/xfs_ihold/enable
      
      or set more complex filters, etc. In Documentation/trace/events.txt
      all this is desctribed in more detail.  To reads the events do a
      
         cat /sys/kernel/debug/tracing/trace
      
      Compared to the last posting this patch converts the tracing mostly to
      the one tracepoint per callsite model that other users of the new
      tracing facility also employ.  This allows a very fine-grained control
      of the tracing, a cleaner output of the traces and also enables the
      perf tool to use each tracepoint as a virtual performance counter,
           allowing us to e.g. count how often certain workloads git various
           spots in XFS.  Take a look at
      
          http://lwn.net/Articles/346470/
      
      for some examples.
      
      Also the btree tracing isn't included at all yet, as it will require
      additional core tracing features not in mainline yet, I plan to
      deliver it later.
      
      And the really nice thing about this patch is that it actually removes
      many lines of code while adding this nice functionality:
      
       fs/xfs/Makefile                |    8
       fs/xfs/linux-2.6/xfs_acl.c     |    1
       fs/xfs/linux-2.6/xfs_aops.c    |   52 -
       fs/xfs/linux-2.6/xfs_aops.h    |    2
       fs/xfs/linux-2.6/xfs_buf.c     |  117 +--
       fs/xfs/linux-2.6/xfs_buf.h     |   33
       fs/xfs/linux-2.6/xfs_fs_subr.c |    3
       fs/xfs/linux-2.6/xfs_ioctl.c   |    1
       fs/xfs/linux-2.6/xfs_ioctl32.c |    1
       fs/xfs/linux-2.6/xfs_iops.c    |    1
       fs/xfs/linux-2.6/xfs_linux.h   |    1
       fs/xfs/linux-2.6/xfs_lrw.c     |   87 --
       fs/xfs/linux-2.6/xfs_lrw.h     |   45 -
       fs/xfs/linux-2.6/xfs_super.c   |  104 ---
       fs/xfs/linux-2.6/xfs_super.h   |    7
       fs/xfs/linux-2.6/xfs_sync.c    |    1
       fs/xfs/linux-2.6/xfs_trace.c   |   75 ++
       fs/xfs/linux-2.6/xfs_trace.h   | 1369 +++++++++++++++++++++++++++++++++++++++++
       fs/xfs/linux-2.6/xfs_vnode.h   |    4
       fs/xfs/quota/xfs_dquot.c       |  110 ---
       fs/xfs/quota/xfs_dquot.h       |   21
       fs/xfs/quota/xfs_qm.c          |   40 -
       fs/xfs/quota/xfs_qm_syscalls.c |    4
       fs/xfs/support/ktrace.c        |  323 ---------
       fs/xfs/support/ktrace.h        |   85 --
       fs/xfs/xfs.h                   |   16
       fs/xfs/xfs_ag.h                |   14
       fs/xfs/xfs_alloc.c             |  230 +-----
       fs/xfs/xfs_alloc.h             |   27
       fs/xfs/xfs_alloc_btree.c       |    1
       fs/xfs/xfs_attr.c              |  107 ---
       fs/xfs/xfs_attr.h              |   10
       fs/xfs/xfs_attr_leaf.c         |   14
       fs/xfs/xfs_attr_sf.h           |   40 -
       fs/xfs/xfs_bmap.c              |  507 +++------------
       fs/xfs/xfs_bmap.h              |   49 -
       fs/xfs/xfs_bmap_btree.c        |    6
       fs/xfs/xfs_btree.c             |    5
       fs/xfs/xfs_btree_trace.h       |   17
       fs/xfs/xfs_buf_item.c          |   87 --
       fs/xfs/xfs_buf_item.h          |   20
       fs/xfs/xfs_da_btree.c          |    3
       fs/xfs/xfs_da_btree.h          |    7
       fs/xfs/xfs_dfrag.c             |    2
       fs/xfs/xfs_dir2.c              |    8
       fs/xfs/xfs_dir2_block.c        |   20
       fs/xfs/xfs_dir2_leaf.c         |   21
       fs/xfs/xfs_dir2_node.c         |   27
       fs/xfs/xfs_dir2_sf.c           |   26
       fs/xfs/xfs_dir2_trace.c        |  216 ------
       fs/xfs/xfs_dir2_trace.h        |   72 --
       fs/xfs/xfs_filestream.c        |    8
       fs/xfs/xfs_fsops.c             |    2
       fs/xfs/xfs_iget.c              |  111 ---
       fs/xfs/xfs_inode.c             |   67 --
       fs/xfs/xfs_inode.h             |   76 --
       fs/xfs/xfs_inode_item.c        |    5
       fs/xfs/xfs_iomap.c             |   85 --
       fs/xfs/xfs_iomap.h             |    8
       fs/xfs/xfs_log.c               |  181 +----
       fs/xfs/xfs_log_priv.h          |   20
       fs/xfs/xfs_log_recover.c       |    1
       fs/xfs/xfs_mount.c             |    2
       fs/xfs/xfs_quota.h             |    8
       fs/xfs/xfs_rename.c            |    1
       fs/xfs/xfs_rtalloc.c           |    1
       fs/xfs/xfs_rw.c                |    3
       fs/xfs/xfs_trans.h             |   47 +
       fs/xfs/xfs_trans_buf.c         |   62 -
       fs/xfs/xfs_vnodeops.c          |    8
       70 files changed, 2151 insertions(+), 2592 deletions(-)
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NAlex Elder <aelder@sgi.com>
      0b1b213f
  13. 12 12月, 2009 2 次提交
  14. 12 8月, 2009 1 次提交
    • C
      xfs: switch to NOFS allocation under i_lock in xfs_buf_associate_memory · 36fae17a
      Christoph Hellwig 提交于
      xfs_buf_associate_memory is used for setting up the spare buffer for the
      log wrap case in xlog_sync which can happen under i_lock when called from
      xfs_fsync. The i_lock mutex is taken in reclaim context so all allocations
      under it must avoid recursions into the filesystem.  There are a couple
      more uses of xfs_buf_associate_memory in the log recovery code that are
      also affected by this, but I'd rather keep the code simple than passing on
      a gfp_mask argument.  Longer term we should just stop requiring the memoery
      allocation in xlog_sync by some smaller rework of the buffer layer.
      
      Reported by the new reclaim context tracing in lockdep.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NFelix Blyakher <felixb@sgi.com>
      Signed-off-by: NFelix Blyakher <felixb@sgi.com>
      36fae17a
  15. 11 8月, 2009 1 次提交
    • C
      xfs: switch to NOFS allocation under i_lock in xfs_buf_associate_memory · 837273b8
      Christoph Hellwig 提交于
      xfs_buf_associate_memory is used for setting up the spare buffer for the
      log wrap case in xlog_sync which can happen under i_lock when called from
      xfs_fsync. The i_lock mutex is taken in reclaim context so all allocations
      under it must avoid recursions into the filesystem.  There are a couple
      more uses of xfs_buf_associate_memory in the log recovery code that are
      also affected by this, but I'd rather keep the code simple than passing on
      a gfp_mask argument.  Longer term we should just stop requiring the memoery
      allocation in xlog_sync by some smaller rework of the buffer layer.
      
      Reported by the new reclaim context tracing in lockdep.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NFelix Blyakher <felixb@sgi.com>
      Signed-off-by: NFelix Blyakher <felixb@sgi.com>
      837273b8
  16. 11 7月, 2009 1 次提交
  17. 23 5月, 2009 1 次提交
  18. 07 4月, 2009 1 次提交
  19. 07 3月, 2009 1 次提交
  20. 04 3月, 2009 1 次提交
  21. 20 2月, 2009 2 次提交
  22. 19 2月, 2009 2 次提交
  23. 09 1月, 2009 2 次提交
    • N
      [XFS] use scalable vmap API · 0087167c
      Nick Piggin 提交于
      Implement XFS's large buffer support with the new vmap APIs. See the vmap
      rewrite (db64fe02) for some numbers. The biggest improvement that comes from
      using the new APIs is avoiding the global KVA allocation lock on every call.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      0087167c
    • N
      [XFS] remove old vmap cache · 958f8c0e
      Nick Piggin 提交于
      XFS's vmap batching simply defers a number (up to 64) of vunmaps, and keeps
      track of them in a list. To purge the batch, it just goes through the list and
      calls vunamp on each one. This is pretty poor: a global TLB flush is generally
      still performed on each vunmap, with the most expensive parts of the operation
      being the broadcast IPIs and locking involved in the SMP callouts, and the
      locking involved in the vmap management -- none of these are avoided by just
      batching up the calls. I'm actually surprised it ever made much difference.
      (Now that the lazy vmap allocator is upstream, this description is not quite
      right, but the vunmap batching still doesn't seem to do much)
      
      Rip all this logic out of XFS completely. I will improve vmap performance
      and scalability directly in subsequent patch.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      958f8c0e
  24. 06 1月, 2009 2 次提交
    • N
      [XFS] use scalable vmap API · 95f8e302
      Nick Piggin 提交于
      Implement XFS's large buffer support with the new vmap APIs. See the vmap
      rewrite (db64fe02) for some numbers. The biggest improvement that comes from
      using the new APIs is avoiding the global KVA allocation lock on every call.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      95f8e302
    • N
      [XFS] remove old vmap cache · d2859751
      Nick Piggin 提交于
      XFS's vmap batching simply defers a number (up to 64) of vunmaps, and keeps
      track of them in a list. To purge the batch, it just goes through the list and
      calls vunamp on each one. This is pretty poor: a global TLB flush is generally
      still performed on each vunmap, with the most expensive parts of the operation
      being the broadcast IPIs and locking involved in the SMP callouts, and the
      locking involved in the vmap management -- none of these are avoided by just
      batching up the calls. I'm actually surprised it ever made much difference.
      (Now that the lazy vmap allocator is upstream, this description is not quite
      right, but the vunmap batching still doesn't seem to do much)
      
      Rip all this logic out of XFS completely. I will improve vmap performance
      and scalability directly in subsequent patch.
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Reviewed-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      d2859751
  25. 12 12月, 2008 1 次提交
  26. 11 12月, 2008 1 次提交
  27. 04 12月, 2008 1 次提交
    • C
      kill xfs_buf_iostart · 5d765b97
      Christoph Hellwig 提交于
      xfs_buf_iostart is a "shared" helper for xfs_buf_read_flags,
      xfs_bawrite, and xfs_bdwrite - except that there isn't much shared
      code but rather special cases for each caller.
      
      So remove this function and move the functionality to the caller.
      xfs_bawrite and xfs_bdwrite are now big enough to be moved out of
      line and the xfs_buf_read_flags is moved into a new helper called
      _xfs_buf_read.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NDave Chinner <david@fromorbit.com>
      Signed-off-by: NNiv Sardi <xaiki@sgi.com>
      5d765b97
  28. 11 10月, 2008 1 次提交
  29. 13 8月, 2008 1 次提交
    • L
      [XFS] Use KM_NOFS for debug trace buffers · 5695ef46
      Lachlan McIlroy 提交于
      Use KM_NOFS to prevent recursion back into the filesystem which can cause
      deadlocks.
      
      In the case of xfs_iread() we hold the lock on the inode cluster buffer
      while allocating memory for the trace buffers. If we recurse back into XFS
      to flush data that may require a transaction to allocate extents which
      needs log space. This can deadlock with the xfsaild thread which can't
      push the tail of the log because it is trying to get the inode cluster
      buffer lock.
      
      SGI-PV: 981498
      
      SGI-Modid: xfs-linux-melb:xfs-kern:31838a
      Signed-off-by: NLachlan McIlroy <lachlan@sgi.com>
      Signed-off-by: NDavid Chinner <david@fromorbit.com>
      5695ef46