1. 25 Mar, 2011 19 commits
    • Linus Torvalds's avatar
      Merge branch 'nfs-for-2.6.39' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6 · 40471856
      Linus Torvalds authored
      * 'nfs-for-2.6.39' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6: (28 commits)
        Cleanup XDR parsing for LAYOUTGET, GETDEVICEINFO
        NFSv4.1 convert layoutcommit sync to boolean
        NFSv4.1 pnfs_layoutcommit_inode fixes
        NFS: Determine initial mount security
        NFS: use secinfo when crossing mountpoints
        NFS: Add secinfo procedure
        NFS: lookup supports alternate client
        NFS: convert call_sync() to a function
        NFSv4.1 remove temp code that prevented ds commits
        NFSv4.1: layoutcommit
        NFSv4.1: filelayout driver specific code for COMMIT
        NFSv4.1: remove GETATTR from ds commits
        NFSv4.1: add generic layer hooks for pnfs COMMIT
        NFSv4.1: alloc and free commit_buckets
        NFSv4.1: shift filelayout_free_lseg
        NFSv4.1: pull out code from nfs_commit_release
        NFSv4.1: pull error handling out of nfs_commit_list
        NFSv4.1: add callback to nfs4_commit_done
        NFSv4.1: rearrange nfs_commit_rpcsetup
        NFSv4.1: don't send COMMIT to ds for data sync writes
        ...
      40471856
    • Linus Torvalds's avatar
      Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · ae005cbe
      Linus Torvalds authored
      * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (43 commits)
        ext4: fix a BUG in mb_mark_used during trim.
        ext4: unused variables cleanup in fs/ext4/extents.c
        ext4: remove redundant set_buffer_mapped() in ext4_da_get_block_prep()
        ext4: add more tracepoints and use dev_t in the trace buffer
        ext4: don't kfree uninitialized s_group_info members
        ext4: add missing space in printk's in __ext4_grp_locked_error()
        ext4: add FITRIM to compat_ioctl.
        ext4: handle errors in ext4_clear_blocks()
        ext4: unify the ext4_handle_release_buffer() api
        ext4: handle errors in ext4_rename
        jbd2: add COW fields to struct jbd2_journal_handle
        jbd2: add the b_cow_tid field to journal_head struct
        ext4: Initialize fsync transaction ids in ext4_new_inode()
        ext4: Use single thread to perform DIO unwritten convertion
        ext4: optimize ext4_bio_write_page() when no extent conversion is needed
        ext4: skip orphan cleanup if fs has unknown ROCOMPAT features
        ext4: use the nblocks arg to ext4_truncate_restart_trans()
        ext4: fix missing iput of root inode for some mount error paths
        ext4: make FIEMAP and delayed allocation play well together
        ext4: suppress verbose debugging information if malloc-debug is off
        ...
      
      Fi up conflicts in fs/ext4/super.c due to workqueue changes
      ae005cbe
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-block · 3961cdf8
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.dk/linux-2.6-block:
        block: fix issue with calling blk_stop_queue() from the request_fn handler
        block: fix bug with inserting flush requests as sort/merge
      3961cdf8
    • Jens Axboe's avatar
      block: fix issue with calling blk_stop_queue() from the request_fn handler · ad3d9d7e
      Jens Axboe authored
      When the queue work handler was converted to delayed work, the
      stopping was inadvertently made sync as well. Change this back
      to being async stop, using __cancel_delayed_work() instead of
      cancel_delayed_work().
      Reported-by: default avatarJeremy Fitzhardinge <jeremy@goop.org>
      Reported-by: default avatarChris Mason <chris.mason@oracle.com>
      Signed-off-by: default avatarJens Axboe <jaxboe@fusionio.com>
      ad3d9d7e
    • Jens Axboe's avatar
      block: fix bug with inserting flush requests as sort/merge · 401a18e9
      Jens Axboe authored
      With the introduction of the on-stack plugging, we would assume
      that any request being inserted was a normal file system request.
      As flush/fua requires a special insert mode, this caused problems.
      
      Fix this up by checking for this in flush_plug_list() and use
      the appropriate insert mechanism.
      
      Big thanks goes to Markus Tripplesdorf for tirelessly testing
      patches, and to Sergey Senozhatsky for helping find the real
      issue.
      Reported-by: default avatarMarkus Tripplesdorf <markus@trippelsdorf.de>
      Signed-off-by: default avatarJens Axboe <jaxboe@fusionio.com>
      401a18e9
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6 · d39dd11c
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
        fs: simplify iget & friends
        fs: pull inode->i_lock up out of writeback_single_inode
        fs: rename inode_lock to inode_hash_lock
        fs: move i_wb_list out from under inode_lock
        fs: move i_sb_list out from under inode_lock
        fs: remove inode_lock from iput_final and prune_icache
        fs: Lock the inode LRU list separately
        fs: factor inode disposal
        fs: protect inode->i_state with inode->i_lock
        autofs4: Do not potentially dereference NULL pointer returned by fget() in autofs_dev_ioctl_setpipefd()
        autofs4 - remove autofs4_lock
        autofs4 - fix d_manage() return on rcu-walk
        autofs4 - fix autofs4_expire_indirect() traversal
        autofs4 - fix dentry leak in autofs4_expire_direct()
        autofs4 - reinstate last used update on access
        vfs - check non-mountpoint dentry might block in __follow_mount_rcu()
      d39dd11c
    • Stephen Rothwell's avatar
      [media] rc: update for bitop name changes · 30f5b28e
      Stephen Rothwell authored
      Fix the following compile failure:
      
        drivers/media/rc/ite-cir.c: In function 'ite_decode_bytes':
        drivers/media/rc/ite-cir.c:190: error: implicit declaration of function 'generic_find_next_le_bit'
        drivers/media/rc/ite-cir.c:199: error: implicit declaration of function 'generic_find_next_zero_le_bit'
      
      Caused by commit 620a32bb ("[media] rc: New rc-based ite-cir driver
      for several ITE CIRs") interacting with commit c4945b9e
      ("asm-generic: rename generic little-endian bitops functions").
      Signed-off-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      30f5b28e
    • Christoph Hellwig's avatar
      fs: simplify iget & friends · 0b2d0724
      Christoph Hellwig authored
      Merge get_new_inode/get_new_inode_fast into iget5_locked/iget_locked
      as those were the only callers.  Remove the internal ifind/ifind_fast
      helpers - ifind_fast only had a single caller, and ifind had two
      callers wanting it to do different things.  Also clean up the comments
      in this area to focus on information important to a developer trying
      to use it, instead of overloading them with implementation details.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      0b2d0724
    • Dave Chinner's avatar
      fs: pull inode->i_lock up out of writeback_single_inode · 0f1b1fd8
      Dave Chinner authored
      First thing we do in writeback_single_inode() is take the i_lock and
      the last thing we do is drop it. A caller already holds the i_lock,
      so pull the i_lock out of writeback_single_inode() to reduce the
      round trips on this lock during inode writeback.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      0f1b1fd8
    • Dave Chinner's avatar
      fs: rename inode_lock to inode_hash_lock · 67a23c49
      Dave Chinner authored
      All that remains of the inode_lock is protecting the inode hash list
      manipulation and traversals. Rename the inode_lock to
      inode_hash_lock to reflect it's actual function.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      67a23c49
    • Dave Chinner's avatar
      fs: move i_wb_list out from under inode_lock · a66979ab
      Dave Chinner authored
      Protect the inode writeback list with a new global lock
      inode_wb_list_lock and use it to protect the list manipulations and
      traversals. This lock replaces the inode_lock as the inodes on the
      list can be validity checked while holding the inode->i_lock and
      hence the inode_lock is no longer needed to protect the list.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      a66979ab
    • Dave Chinner's avatar
      fs: move i_sb_list out from under inode_lock · 55fa6091
      Dave Chinner authored
      Protect the per-sb inode list with a new global lock
      inode_sb_list_lock and use it to protect the list manipulations and
      traversals. This lock replaces the inode_lock as the inodes on the
      list can be validity checked while holding the inode->i_lock and
      hence the inode_lock is no longer needed to protect the list.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      55fa6091
    • Dave Chinner's avatar
      fs: remove inode_lock from iput_final and prune_icache · f283c86a
      Dave Chinner authored
      Now that inode state changes are protected by the inode->i_lock and
      the inode LRU manipulations by the inode_lru_lock, we can remove the
      inode_lock from prune_icache and the initial part of iput_final().
      
      instead of using the inode_lock to protect the inode during
      iput_final, use the inode->i_lock instead. This protects the inode
      against new references being taken while we change the inode state
      to I_FREEING, as well as preventing prune_icache from grabbing the
      inode while we are manipulating it. Hence we no longer need the
      inode_lock in iput_final prior to setting I_FREEING on the inode.
      
      For prune_icache, we no longer need the inode_lock to protect the
      LRU list, and the inodes themselves are protected against freeing
      races by the inode->i_lock. Hence we can lift the inode_lock from
      prune_icache as well.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      f283c86a
    • Dave Chinner's avatar
      fs: Lock the inode LRU list separately · 02afc410
      Dave Chinner authored
      Introduce the inode_lru_lock to protect the inode_lru list. This
      lock is nested inside the inode->i_lock to allow the inode to be
      added to the LRU list in iput_final without needing to deal with
      lock inversions. This keeps iput_final() clean and neat.
      
      Further, where marking the inode I_FREEING and removing it from the
      LRU, move the LRU list manipulation within the inode->i_lock to keep
      the list manipulation consistent with iput_final. This also means
      that most of the open coded LRU list removal + unused inode
      accounting can now use the inode_lru_list_del() wrappers which
      cleans the code up further.
      
      However, this locking change means what the LRU traversal in
      prune_icache() inverts this lock ordering and needs to use trylock
      semantics on the inode->i_lock to avoid deadlocking. In these cases,
      if we fail to lock the inode we move it to the back of the LRU to
      prevent spinning on it.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      02afc410
    • Dave Chinner's avatar
      fs: factor inode disposal · b2b2af8e
      Dave Chinner authored
      We have a couple of places that dispose of inodes. factor the
      disposal into evict() to isolate this code and make it simpler to
      peel away the inode_lock from the code.
      
      While doing this, change the logic flow in iput_final() to separate
      the different cases that need to be handled to make the transitions
      the inode goes through more obvious.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      b2b2af8e
    • Dave Chinner's avatar
      fs: protect inode->i_state with inode->i_lock · 250df6ed
      Dave Chinner authored
      Protect inode state transitions and validity checks with the
      inode->i_lock. This enables us to make inode state transitions
      independently of the inode_lock and is the first step to peeling
      away the inode_lock from the code.
      
      This requires that __iget() is done atomically with i_state checks
      during list traversals so that we don't race with another thread
      marking the inode I_FREEING between the state check and grabbing the
      reference.
      
      Also remove the unlock_new_inode() memory barrier optimisation
      required to avoid taking the inode_lock when clearing I_NEW.
      Simplify the code by simply taking the inode->i_lock around the
      state change and wakeup. Because the wakeup is no longer tricky,
      remove the wake_up_inode() function and open code the wakeup where
      necessary.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      250df6ed
    • Linus Torvalds's avatar
      Merge branch 'slab/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6 · a7351402
      Linus Torvalds authored
      * 'slab/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6:
        SLUB: Write to per cpu data when allocating it
        slub: Fix debugobjects with lockless fastpath
      a7351402
    • David Rientjes's avatar
      lib, arch: add filter argument to show_mem and fix private implementations · b2b755b5
      David Rientjes authored
      Commit ddd588b5 ("oom: suppress nodes that are not allowed from
      meminfo on oom kill") moved lib/show_mem.o out of lib/lib.a, which
      resulted in build warnings on all architectures that implement their own
      versions of show_mem():
      
      	lib/lib.a(show_mem.o): In function `show_mem':
      	show_mem.c:(.text+0x1f4): multiple definition of `show_mem'
      	arch/sparc/mm/built-in.o:(.text+0xd70): first defined here
      
      The fix is to remove __show_mem() and add its argument to show_mem() in
      all implementations to prevent this breakage.
      
      Architectures that implement their own show_mem() actually don't do
      anything with the argument yet, but they could be made to filter nodes
      that aren't allowed in the current context in the future just like the
      generic implementation.
      Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      Reported-by: default avatarJames Bottomley <James.Bottomley@hansenpartnership.com>
      Suggested-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarDavid Rientjes <rientjes@google.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      b2b755b5
    • Linus Torvalds's avatar
      Merge branch 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 · e285c174
      Linus Torvalds authored
      * 'drm-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
        drm/vblank: update recently added vbl interface to be more future proof.
        drm radeon: Return -EINVAL on wrong pm sysfs access
        drm/radeon/kms: fix hardcoded EDID handling
        Revert "drm/i915: Don't save/restore hardware status page address register"
        drm/i915: Avoid unmapping pages from a NULL address space
        drm/i915: Fix use after free within tracepoint
        drm/i915: Restore missing command flush before interrupt on BLT ring
        drm/i915: Disable pagefaults along execbuffer relocation fast path
        drm/i915: Fix computation of pitch for dumb bo creator
        drm/i915: report correct render clock frequencies on SNB
        drm/i915/dp: Correct the order of deletion for ghost eDP devices
        drm/i915: Fix tiling corruption from pipelined fencing
        drm/i915: Re-enable self-refresh
        drm/i915: Prevent racy removal of request from client list
        drm/i915: skip redundant operations whilst enabling pipes and planes
        drm/i915: Remove surplus POSTING_READs before wait_for_vblank
        drm/radeon/kms: prefer legacy pll algo for tv-out
        drm: check for modesetting on modeset ioctls
        drm/kernel: vblank wait on crtc > 1
        drm: Fix use-after-free in drm_gem_vm_close()
      e285c174
  2. 24 Mar, 2011 21 commits