1. 05 9月, 2006 11 次提交
  2. 04 9月, 2006 2 次提交
  3. 02 9月, 2006 1 次提交
  4. 01 9月, 2006 3 次提交
    • S
      [GFS2] Update copyright, tidy up incore.h · e9fc2aa0
      Steven Whitehouse 提交于
      As per comments from Jan Engelhardt <jengelh@linux01.gwdg.de> this
      updates the copyright message to say "version" in full rather than
      "v.2". Also incore.h has been updated to remove forward structure
      declarations which are not required.
      
      The gfs2_quota_lvb structure has now had endianess annotations added
      to it. Also quota.c has been updated so that we now store the
      lvb data locally in endian independant format to avoid needing
      a structure in host endianess too. As a result the endianess
      conversions are done as required at various points and thus the
      conversion routines in lvb.[ch] are no longer required. I've
      moved the one remaining constant in lvb.h thats used into lm.h
      and removed the unused lvb.[ch].
      
      I have not changed the HIF_ constants. That is left to a later patch
      which I hope will unify the gh_flags and gh_iflags fields of the
      struct gfs2_holder.
      
      Cc: Jan Engelhardt <jengelh@linux01.gwdg.de>
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      e9fc2aa0
    • D
      [DLM] force removal of user lockspace · c6e6f0ba
      David Teigland 提交于
      Check if the FORCEFREE flag has been provided from user space.  If so, set
      the force option to dlm_release_lockspace() so that any remaining locks
      will be freed.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      c6e6f0ba
    • S
      [GFS2] Fix releasepage bug (fixes direct i/o writes) · 623d9355
      Steven Whitehouse 提交于
      This patch fixes three main bugs. Firstly the direct i/o get_block
      was returning the wrong return code in certain cases. Secondly, the
      GFS2's releasepage function was not dealing with cases when clean,
      ordered buffers were found still queued on a transaction (which can
      happen depending on the ordering of journal flushes). Thirdly, the
      journaling code itself needed altering to take account of the
      after effects of removing the clean ordered buffers from the transactions
      before a journal flush.
      
      The releasepage bug did also show up under "normal" buffered i/o
      as well, so its not just a fix for direct i/o. In fact its not
      normally used in the direct i/o path at all, except when flushing
      existing buffers after performing a direct i/o write, but that was
      the code path that led us to spot this.
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      623d9355
  5. 31 8月, 2006 1 次提交
  6. 30 8月, 2006 5 次提交
  7. 28 8月, 2006 11 次提交
    • A
      [PATCH] /proc/meminfo: don't put spaces in names · f5ef68da
      Andrew Morton 提交于
      None of the other /proc/meminfo lines have a space in the identifier.  This
      post-2.6.17 addition has the potential to break existing parsers, so use an
      underscore instead (like Committed_AS).
      
      Cc: Christoph Lameter <clameter@engr.sgi.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      f5ef68da
    • D
      [PATCH] fix up lockdep trace in fs/exec.c · 513627d7
      Dave Jones 提交于
      This fixes the locking error noticed by lockdep:
      
        =============================================
        [ INFO: possible recursive locking detected ]
        ---------------------------------------------
        init/1 is trying to acquire lock:
         (&sighand->siglock){....}, at: [<c047a78a>] flush_old_exec+0x3ae/0x859
      
        but task is already holding lock:
         (&sighand->siglock){....}, at: [<c047a77a>] flush_old_exec+0x39e/0x859
      
        other info that might help us debug this:
        2 locks held by init/1:
         #0:  (tasklist_lock){..--}, at: [<c047a76a>] flush_old_exec+0x38e/0x859
         #1:  (&sighand->siglock){....}, at: [<c047a77a>] flush_old_exec+0x39e/0x859
      
        stack backtrace:
         [<c04051e1>] show_trace_log_lvl+0x54/0xfd
         [<c040579d>] show_trace+0xd/0x10
         [<c04058b6>] dump_stack+0x19/0x1b
         [<c043b33a>] __lock_acquire+0x773/0x997
         [<c043bacf>] lock_acquire+0x4b/0x6c
         [<c060630b>] _spin_lock+0x19/0x28
         [<c047a78a>] flush_old_exec+0x3ae/0x859
         [<c0498053>] load_elf_binary+0x4aa/0x1628
         [<c0479cab>] search_binary_handler+0xa7/0x24e
         [<c047b577>] do_execve+0x15b/0x1f9
         [<c04022b4>] sys_execve+0x29/0x4d
         [<c0403faf>] syscall_call+0x7/0xb
      Signed-off-by: NArjan van de Ven <arjan@infradead.org>
      Signed-off-by: NDave Jones <davej@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      513627d7
    • I
      [PATCH] lockdep: annotate reiserfs · 4df46240
      Ingo Molnar 提交于
      reiserfs seems to have another locking level layer for the i_mutex due to the
      xattrs-are-a-directory thing.
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      4df46240
    • B
      [PATCH] Manage jbd allocations from its own slabs · ea817398
      Badari Pulavarty 提交于
      JBD currently allocates commit and frozen buffers from slabs.  With
      CONFIG_SLAB_DEBUG, its possible for an allocation to cross the page
      boundary causing IO problems.
      
      https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=200127
      
      So, instead of allocating these from regular slabs - manage allocation from
      its own slabs and disable slab debug for these slabs.
      
      [akpm@osdl.org: cleanups]
      Signed-off-by: NBadari Pulavarty <pbadari@us.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ea817398
    • M
      [PATCH] eventpoll.c compile fix · 45f17e0c
      Masoud Asgharifard Sharbiani 提交于
      Fix two compile failures in eventpoll.c code which would happen if
      DEBUG_EPOLL is bigger than zero.
      Signed-off-by: NMasoud Sharbiani <masouds@google.com>
      Cc: Davide Libenzi <davidel@xmailserver.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      45f17e0c
    • E
      [PATCH] ufs: truncate correction · ecdc6394
      Evgeniy Dushistov 提交于
      1) When we allocated last fragment in ufs_truncate, we read page, check
         if block mapped to address, and if not trying to allocate it.  This is
         wrong behaviour, fragment may be NOT allocated, but mapped, this
         happened because of "block map" function not checked allocated fragment
         or not, it just take address of the first fragment in the block, add
         offset of fragment and return result, this is correct behaviour in
         almost all situation except call from ufs_truncate.
      
      2) Almost all implementation of UFS, which I can investigate have such
         "defect": if you have full disk, and try truncate file, for example 3GB
         to 2MB, and have hole in this region, truncate return -ENOSPC.  I tried
         evade from this problem, but "block allocation" algorithm is tied to
         right value of i_lastfrag, and fix of this corner case may slow down of
         ordinaries scenarios, so this patch makes behavior of "truncate"
         operations similar to what other UFS implementations do.
      Signed-off-by: NEvgeniy Dushistov <dushistov@mail.ru>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ecdc6394
    • E
      [PATCH] ufs: write to hole in big file · c37336b0
      Evgeniy Dushistov 提交于
      On UFS, this scenario:
      	open(O_TRUNC)
      	lseek(1024 * 1024 * 80)
      	write("A")
      	lseek(1024 * 2)
      	write("A")
      
      may cause access to invalid address.
      
      This happened because of "goal" is calculated in wrong way in block
      allocation path, as I see this problem exists also in 2.4.
      
      We use construction like this i_data[lastfrag], i_data array of pointers to
      direct blocks, indirect and so on, it has ceratain size ~20 elements, and
      lastfrag may have value for example 40000.
      
      Also this patch fixes related to handling such scenario issues, wrong
      zeroing metadata, in case of block(not fragment) allocation, and wrong goal
      calculation, when we allocate block
      Signed-off-by: NEvgeniy Dushistov <dushistov@mail.ru>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      c37336b0
    • M
      [PATCH] ext3 filesystem bogus ENOSPC with reservation fix · 08fb306f
      Mingming Cao 提交于
      To handle the earlier bogus ENOSPC error caused by filesystem full of block
      reservation, current code falls back to non block reservation, starts to
      allocate block(s) from the goal allocation block group as if there is no
      block reservation.
      
      Current code needs to re-load the corresponding block group descriptor for
      the initial goal block group in this case.  The patch fixes this.
      Signed-off-by: NMingming Cao <cmm@us.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      08fb306f
    • A
      [PATCH] ext2: prevent div-by-zero on corrupted fs · 607eb266
      Andries Brouwer 提交于
      Mounting an ext2 filesystem with zero s_inodes_per_group will cause a
      divide error.
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      607eb266
    • A
      [PATCH] Fix for minix crash · f5fb09fa
      Andries Brouwer 提交于
      Mounting a (corrupt) minix filesystem with zero s_zmap_blocks
      gives a spectacular crash on my 2.6.17.8 system, no doubt
      because minix/inode.c does an unconditional
      	minix_set_bit(0,sbi->s_zmap[0]->b_data);
      
      [akpm@osdl.org: make labels conistent while we're there]
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      f5fb09fa
    • P
      [PATCH] lockdep: fix blkdev_open() warning · 6946bd63
      Peter Zijlstra 提交于
      On Wed, 2006-08-09 at 07:57 +0200, Rolf Eike Beer wrote:
      > =============================================
      > [ INFO: possible recursive locking detected ]
      > ---------------------------------------------
      > parted/7929 is trying to acquire lock:
      >  (&bdev->bd_mutex){--..}, at: [<c105eb8d>] __blkdev_put+0x1e/0x13c
      >
      > but task is already holding lock:
      >  (&bdev->bd_mutex){--..}, at: [<c105eec6>] do_open+0x72/0x3a8
      >
      > other info that might help us debug this:
      > 1 lock held by parted/7929:
      >  #0:  (&bdev->bd_mutex){--..}, at: [<c105eec6>] do_open+0x72/0x3a8
      > stack backtrace:
      >  [<c1003aad>] show_trace_log_lvl+0x58/0x15b
      >  [<c100495f>] show_trace+0xd/0x10
      >  [<c1004979>] dump_stack+0x17/0x1a
      >  [<c102dee5>] __lock_acquire+0x753/0x99c
      >  [<c102e3b0>] lock_acquire+0x4a/0x6a
      >  [<c1204501>] mutex_lock_nested+0xc8/0x20c
      >  [<c105eb8d>] __blkdev_put+0x1e/0x13c
      >  [<c105ecc4>] blkdev_put+0xa/0xc
      >  [<c105f18a>] do_open+0x336/0x3a8
      >  [<c105f21b>] blkdev_open+0x1f/0x4c
      >  [<c1057b40>] __dentry_open+0xc7/0x1aa
      >  [<c1057c91>] nameidata_to_filp+0x1c/0x2e
      >  [<c1057cd1>] do_filp_open+0x2e/0x35
      >  [<c1057dd7>] do_sys_open+0x38/0x68
      >  [<c1057e33>] sys_open+0x16/0x18
      >  [<c1002845>] sysenter_past_esp+0x56/0x8d
      
      OK, I'm having a look here; its all new to me so bear with me.
      
      blkdev_open() calls
        do_open(bdev, ...,BD_MUTEX_NORMAL) and takes
          mutex_lock_nested(&bdev->bd_mutex, BD_MUTEX_NORMAL)
      
      then something fails, and we're thrown to:
      
      out_first: where
          if (bdev != bdev->bd_contains)
            blkdev_put(bdev->bd_contains) which is
              __blkdev_put(bdev->bd_contains, BD_MUTEX_NORMAL) which does
                mutex_lock_nested(&bdev->bd_contains->bd_mutex, BD_MUTEX_NORMAL) <--- lockdep trigger
      
      When going to out_first, dbev->bd_contains is either bdev or whole, and
      since we take the branch it must be whole. So it seems to me the
      following patch would be the right one:
      
      [akpm@osdl.org: compile fix]
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Arjan van de Ven <arjan@linux.intel.com>
      Acked-by: NNeilBrown <neilb@suse.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      6946bd63
  8. 27 8月, 2006 1 次提交
  9. 26 8月, 2006 1 次提交
  10. 25 8月, 2006 4 次提交
    • D
      [DLM] add new lockspace to list ealier · 5f88f1ea
      David Teigland 提交于
      When a new lockspace was being created, the recoverd thread was being
      started for it before the lockspace was added to the global list of
      lockspaces.  The new thread was looking up the lockspace in the global
      list and sometimes not finding it due to the race with the original thread
      adding it to the list.  We need to add the lockspace to the global list
      before starting the thread instead of after, and if the new thread can't
      find the lockspace for some reason, it should return an error.
      Signed-off-by: NDavid Teigland <teigland@redhat.com>
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      5f88f1ea
    • B
      [GFS2] Fix journal off-by-one error · 5dc39fe6
      Benjamin Marzinski 提交于
      log_refund() incorrectly assumed that if a transaction had been touched, it
      always committed buffers to the incore log. Thus, when you got around to
      flushing the log, you would need one more block than you committed, to account
      for the header. So it automatically set reserved to 1, which had the effect of
      making sdp->sd_log_blks_reserved one greater when you got to gfs2_log_flush().
      However, if you don't actually commit anything to the incore log between
      flushes, you don't need the header, because you aren't writing anything out.
      With this patch, log_refund() only increments reservered to account for the
      header if something has been committed since the last flush.
      Signed-off-by: NBenjamin E. Marzinski <bmarzins@redhat.com>
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      5dc39fe6
    • S
      [GFS2] Speed up scanning of glocks · a2242db0
      Steven Whitehouse 提交于
      I noticed the gfs2_scand seemed to be taking a lot of CPU,
      so in order to cut that down a bit, here is a patch. Firstly
      the type of a glock is a constant during its lifetime, so that
      its possible to check this without needing locking. I've moved
      the (common) case of testing for an inode glock outside of
      the glmutex lock.
      
      Also there was a mutex left over from when the glock cache was
      master of the inode cache. That isn't required any more so I've
      removed that too.
      
      There is probably scope for further speed ups in the future
      in this area.
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      a2242db0
    • S
      [GFS2] Tidy up error handling in gfs2_releasepage() · 166afccd
      Steven Whitehouse 提交于
      This should clarify the logic in gfs2_releasepage() relating to
      error handling as well as making the response to errors a bit
      more graceful.
      Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
      166afccd