xfs
[Top] [All Lists]

[XFS updates] XFS development tree branch, master, updated. v2.6.33-6372

To: xfs@xxxxxxxxxxx
Subject: [XFS updates] XFS development tree branch, master, updated. v2.6.33-6372-gf0ef9eb
From: xfs@xxxxxxxxxxx
Date: Fri, 16 Apr 2010 16:18:32 -0500
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "XFS development tree".

The branch, master has been updated
  f0ef9eb xfs: xfs_trace.c: duplicated include
  4230937 xfs: minor odds and ends in xfs_log_recover.c
  8057706 xfs: avoid repeated pointer dereferences
  9be02e0 xfs: change a few labels in xfs_log_recover.c
  4fd190c xfs: enforce synchronous writes in xfs_bwrite
  1155962 xfs: remove periodic superblock writeback
  d65d59d xfs: make the log ticket transaction id random
  d993394 xfs: nothing special about 1-block log sector
  cf7af48 xfs: encapsulate bbcount validity checking
  6610af4 xfs: kill XLOG_SECTOR_ROUND*()
  4853b38 xfs: simplify XLOG_SECTOR_ROUND*()
  55515d6 xfs: fix min bufsize bugs in two places
  c2b1d4f xfs: add const qualifiers to xfs error function args
  4d62bf7 xfs: remove xfs_dqmarker
  4e66454 xfs: convert the dquot free list to use list heads
  ff19c6b xfs: convert the dquot hash list to use list heads
  808e75a xfs: remove duplicate code from dquot reclaim
  23a35f5 xfs: convert the per-mount dquot list to use list heads
  bf886d4 xfs: add log item recovery tracing
  777d8f6 xfs: don't warn on EAGAIN in inode reclaim
  e877e08 xfs: ensure that sync updates the log tail correctly
      from  68a2ac777cca40ccc993512bcf457999be71cc36 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit f0ef9eb19288ba3ed213348ea1f581d7b83b451e
Author: Andrea Gelmini <andrea.gelmini@xxxxxxxxx>
Date:   Thu Mar 25 17:22:41 2010 +0000

    xfs: xfs_trace.c: duplicated include
    
    fs/xfs/linux-2.6/xfs_trace.c: xfs_attr_sf.h is included more than once.
    
    Signed-off-by: Andrea Gelmini <andrea.gelmini@xxxxxxxxx>
    Signed-off-by: Alex Elder <aelder@xxxxxxx>

commit 42309371c555fa84c711a4dc61d24712bcd52909
Author: Alex Elder <aelder@xxxxxxx>
Date:   Thu Apr 15 18:17:34 2010 +0000

    xfs: minor odds and ends in xfs_log_recover.c
    
    Odds and ends in "xfs_log_recover.c".  This patch just contains some
    minor things that didn't seem to warrant their own individual
    patches:
    - In xlog_bread_noalign(), drop an assertion that a pointer is
      non-null (the crash will tell us it was a bad pointer).
    - Add a more descriptive header comment for xlog_find_verify_cycle().
    - Make a few additions to the comments in xlog_find_head().  Also
      rearrange some expressions in a few spots to produce the same
      result, but in a way that seems more clear what's being computed.
    
    (Updated in response to Dave's review comments.  Note I did not
    split this patch like I said I would.)
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 80577062897a796452df3e53f7509439d4eef443
Author: Alex Elder <aelder@xxxxxxx>
Date:   Thu Apr 15 18:17:30 2010 +0000

    xfs: avoid repeated pointer dereferences
    
    In xlog_find_cycle_start() use a local variable for some repeated
    operations rather than constantly accessing the memory location
    whose address is passed in.
    
    (This version drops an assertion that a pointer is non-null.)
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 9be02e0bc07fb3c2619d2e32914191d16a724f61
Author: Alex Elder <aelder@xxxxxxx>
Date:   Thu Apr 15 18:17:26 2010 +0000

    xfs: change a few labels in xfs_log_recover.c
    
    Rename a label used in xlog_find_head() that I thought was poorly
    chosen.  Also combine two adjacent labels xlog_find_tail() into a
    single label, and give it a more generic name.
    
    (Now using Dave's suggested "validate_head" name for first label.)
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 4fd190cfb8dc99e379090fab659bdb17d943bac1
Author: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date:   Fri Mar 12 10:59:40 2010 +0000

    xfs: enforce synchronous writes in xfs_bwrite
    
    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: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Alex Elder <aelder@xxxxxxx>

commit 115596240606d3b2a7959589aa396d4382aeb507
Author: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date:   Fri Mar 12 10:59:16 2010 +0000

    xfs: remove periodic superblock writeback
    
    All modifications to the superblock are done transactional through
    xfs_trans_log_buf, so there is no reason to initiate periodic
    asynchronous writeback.  This only removes the superblock from the
    delwri list and will lead to sub-optimal I/O scheduling.
    
    Cut down xfs_sync_fsdata now that it's only used for synchronous
    superblock writes and move the log coverage checks into the two
    callers.
    
    Signed-off-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Alex Elder <aelder@xxxxxxx>

commit d65d59d0a01c5996c9d6643da07bdf224cb0f678
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Wed Apr 14 15:47:55 2010 +1000

    xfs: make the log ticket transaction id random
    
    The transaction ID that is written to the log for a transaction is
    currently set by taking the lower 32 bits of the memory address of
    the ticket structure.  This is not guaranteed to be unique as
    tickets comes from a slab and slots can be reallocated immediately
    after being freed. As a result, there is no guarantee of uniqueness
    in the ticket ID value.
    
    Fix this by assigning a random number to the ticket ID field so that
    it is extremely unlikely that duplicates will occur and remove the
    possibility of transactions being mixed up during recovery due to
    duplicate IDs.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit d9933943a6fcba7065608a775fc31aedb1679e15
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:21:13 2010 +1000

    xfs: nothing special about 1-block log sector
    
    There are a number of places where a log sector size of 1 uses
    special case code.  The round_up() and round_down() macros
    produce the correct result even when the log sector size is 1, and
    this eliminates the need for treating this as a special case.
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit cf7af487e1eb9c098f7204c209f25ff293438a66
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:22:58 2010 +1000

    xfs: encapsulate bbcount validity checking
    
    Define a function that encapsulates checking the validity of a log
    block count.
    
    (Updated from previous version--no longer includes error reporting in the
    encapsulated validation function.)
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>

commit 6610af4b562acdecf58a82919fd4715557df09f5
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:22:48 2010 +1000

    xfs: kill XLOG_SECTOR_ROUND*()
    
    XLOG_SECTOR_ROUNDUP_BBCOUNT() and XLOG_SECTOR_ROUNDDOWN_BLKNO()
    are now fairly simple macro translations.  Just get rid of them in
    favor of the round_up() and round_down() macro calls they represent.
    
    Also, in spots in xlog_get_bp() and xlog_write_log_records(),
    round_up() was being called with value 1, which just evaluates
    to the macro's second argument; so just use that instead.
    In the latter case, make use of that value, as long as it's
    already been computed.
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>

commit 4853b380a3aac6e2842a4f87a5b9336a46f2a3df
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:22:40 2010 +1000

    xfs: simplify XLOG_SECTOR_ROUND*()
    
    XLOG_SECTOR_ROUNDUP_BBCOUNT() is defined in "fs/xfs/xfs_log_recover.c"
    in an overly-complicated way.  It is basically roundup(), but that
    is not at all clear from its definition.  (Actually, there is
    another macro round_up() that applies for power-of-two-based masks
    which I'll be using here.)
    
    The operands in XLOG_SECTOR_ROUNDUP_BBCOUNT() are basically the
    block number (bbs) and the log sector basic block mask
    (log->l_sectbb_mask).  I'll call them B and M for this discussion.
    
    The macro computes is value this way:
        M && (B & M) ? (B + M + 1) & ~M : B
    
    Put another way, we can break it into 3 cases:
        1)  ! M          -> B                   # 0 mask, no effect
        2)  ! (B & M)    -> B                   # sector aligned
        3)  M && (B & M) -> (B + M + 1) & ~M    # round up otherwise
    
    The round_up() macro is cleverly defined using a value, v, and a
    power-of-2, p, and the result is the nearest multiple of p greater
    than or equal to v.  Its value is computed something like this:
        ((v - 1) | (p - 1)) + 1
    Let's consider using this in the context of the 3 cases above.
    
    When p = 2^0 = 1, the result boils down to ((v - 1) | 0) + 1, so it
    just translates any value v to itself.  That handles case (1) above.
    
    When p = 2^n, n > 0, we know that (p - 1) will be a mask with all n
    bits 0..n-1 set.  The condition in this case occurs when none of
    those mask bits is set in the value v provided.  If that is the
    case, subtracting 1 from v will have 1's in all those lower bits (at
    least).  Therefore, OR-ing the mask with that decremented value has
    no effect, so adding the 1 back again will just translate the v to
    itself.  This handles case (2).
    
    Otherwise, the value v is greater than some multiple of p, and
    decrementing it will produce a result greater than or equal to that
    multiple.  OR-ing in the mask will produce a value 1 less than the
    next multiple of p, so finally adding 1 back will result in the
    desired rounded-up value.  This handles case (3).
    
    Hopefully this is convincing.
    
    While I was at it, I converted XLOG_SECTOR_ROUNDDOWN_BLKNO() to use
    the round_down() macro.
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>

commit 55515d66885654cf7498dd66074abbca5be2fc8a
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:22:29 2010 +1000

    xfs: fix min bufsize bugs in two places
    
    This fixes a bug in two places that I found by inspection.  In
    xlog_find_verify_cycle() and xlog_write_log_records(), the code
    attempts to allocate a buffer to hold as many blocks as possible.
    It gives up if the number of blocks to be allocated gets too small.
    Right now it uses log->l_sectbb_log as that lower bound, but I'm
    sure it's supposed to be the actual log sector size instead.  That
    is, the lower bound should be (1 << log->l_sectbb_log).
    
    Also define a simple macro xlog_sectbb(log) to represent the number
    of basic blocks in a sector for the given log.
    
    (No change from original submission; I have implemented Christoph's
    suggestion about storing l_sectsize rather than l_sectbb_log in
    a new, separate patch in this series.)
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>

commit c2b1d4f7561c25b0265eebeeeccd48240a18136e
Author: Alex Elder <aelder@xxxxxxx>
Date:   Tue Apr 13 15:22:08 2010 +1000

    xfs: add const qualifiers to xfs error function args
    
    Change the tag and file name arguments to xfs_error_report() and
    xfs_corruption_error() to use a const qualifier.
    
    Signed-off-by: Alex Elder <aelder@xxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>

commit 4d62bf75b0b31b90ffd2f02b106f978e0b7c6fd8
Author: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date:   Tue Apr 13 15:06:53 2010 +1000

    xfs: remove xfs_dqmarker
    
    The xfs_dqmarker structure does not need to exist anymore. Move the
    remaining flags field out of it and remove the structure altogether.
    
    Signed-off-by: Christoph Hellwig <hch@xxxxxx>
    Reviewed-by: Dave Chinner <david@xxxxxxxxxxxxx>

commit 4e664548972c6f05c79b24a3b709d7e0cc4aed32
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:52 2010 +1000

    xfs: convert the dquot free list to use list heads
    
    Convert the dquot free list on the filesystem to use listhead
    infrastructure rather than the roll-your-own in the quota code.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit ff19c6b85cadc5c6dbc95e3ae767f6b686f21dfc
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:51 2010 +1000

    xfs: convert the dquot hash list to use list heads
    
    Convert the dquot hash list on the filesystem to use listhead
    infrastructure rather than the roll-your-own in the quota code.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 808e75a8edd648ce6c7dedd18bf2a21e06292752
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:50 2010 +1000

    xfs: remove duplicate code from dquot reclaim
    
    The dquot shaker and the free-list reclaim code use exactly the same
    algorithm but the code is duplicated and slightly different in each
    case. Make the shaker code use the single dquot reclaim code to
    remove the code duplication.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 23a35f57a4132fc8128227347e954e2f6f128c7f
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:48 2010 +1000

    xfs: convert the per-mount dquot list to use list heads
    
    Convert the dquot list on the filesytesm to use listhead
    infrastructure rather than the roll-your-own in the quota code.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit bf886d416a879d55d6ca097cb1306fe423400203
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:46 2010 +1000

    xfs: add log item recovery tracing
    
    Currently there is no tracing in log recovery, so it is difficult to
    determine what is going on when something goes wrong.
    
    Add tracing for log item recovery to provide visibility into the log
    recovery process. The tracing added shows regions being extracted
    from the log transactions and added to the transaction hash forming
    recovery items, followed by the reordering, cancelling and finally
    recovery of the items.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

commit 777d8f6489a80534921e7a54bccb1cce0d88e51a
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:45 2010 +1000

    xfs: don't warn on EAGAIN in inode reclaim
    
    Any inode reclaim flush that returns EAGAIN will result in the inode
    reclaim being attempted again later. There is no need to issue a
    warning into the logs about this situation.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Alex Elder <aelder@xxxxxxx>

commit e877e0888cefba8d0ffe64deb69468811ee5fcae
Author: Dave Chinner <dchinner@xxxxxxxxxx>
Date:   Tue Apr 13 15:06:44 2010 +1000

    xfs: ensure that sync updates the log tail correctly
    
    Updates to the VFS layer removed an extra ->sync_fs call into the
    filesystem during the sync process (from the quota code).
    Unfortunately the sync code was unknowingly relying on this call to
    make sure metadata buffers were flushed via a xfs_buftarg_flush()
    call to move the tail of the log forward in memory before the final
    transactions of the sync process were issued.
    
    As a result, the old code would write a very recent log tail value
    to the log by the end of the sync process, and so a subsequent crash
    would leave nothing for log recovery to do. Hence in qa test 182,
    log recovery only replayed a small handle for inode fsync
    transactions in this case.
    
    However, with the removal of the extra ->sync_fs call, the log tail
    was now not moved forward with the inode fsync transactions near the
    end of the sync procese the first (and only) buftarg flush occurred
    after these transactions went to disk. The result is that log
    recovery now sees a large number of transactions for metadata that
    is already on disk.
    
    This usually isn't a problem, but when the transactions include
    inode chunk allocation, the inode create transactions and all
    subsequent changes are replayed as we cannt rely on what is on disk
    is valid. As a result, if the inode was written and contains
    unlogged changes, the unlogged changes are lost, thereby violating
    sync semantics.
    
    The fix is to always issue a transaction after the buftarg flush
    occurs is the log iÑ? not idle or covered. This results in a dummy
    transaction being written that contains the up-to-date log tail
    value, which will be very recent. Indeed, it will be at least as
    recent as the old code would have left on disk, so log recovery
    will behave exactly as it used to in this situation.
    
    Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
    Reviewed-by: Christoph Hellwig <hch@xxxxxx>

-----------------------------------------------------------------------

Summary of changes:
 fs/xfs/linux-2.6/xfs_buf.c     |   17 +-
 fs/xfs/linux-2.6/xfs_sync.c    |   93 +++-----
 fs/xfs/linux-2.6/xfs_trace.c   |    4 +-
 fs/xfs/linux-2.6/xfs_trace.h   |  141 +++++++++++-
 fs/xfs/quota/xfs_dquot.c       |  120 ++++------
 fs/xfs/quota/xfs_dquot.h       |   35 +---
 fs/xfs/quota/xfs_qm.c          |  515 ++++++++++++++--------------------------
 fs/xfs/quota/xfs_qm.h          |   23 +--
 fs/xfs/quota/xfs_qm_stats.c    |    2 +-
 fs/xfs/quota/xfs_qm_syscalls.c |   38 ++--
 fs/xfs/quota/xfs_quota_priv.h  |   75 ------
 fs/xfs/xfs_buf_item.h          |    2 +-
 fs/xfs/xfs_error.c             |   30 ++--
 fs/xfs/xfs_error.h             |    9 +-
 fs/xfs/xfs_log.c               |   40 ++-
 fs/xfs/xfs_log_recover.c       |  231 ++++++++++++-------
 fs/xfs/xfs_trans.h             |    9 +
 17 files changed, 632 insertions(+), 752 deletions(-)


hooks/post-receive
-- 
XFS development tree

<Prev in Thread] Current Thread [Next in Thread>
  • [XFS updates] XFS development tree branch, master, updated. v2.6.33-6372-gf0ef9eb, xfs <=