1. 11 6月, 2014 1 次提交
  2. 22 5月, 2014 2 次提交
    • J
      ext3: Fix deadlock in data=journal mode when fs is frozen · 166418cc
      Jan Kara 提交于
      When ext3 is used in data=journal mode, syncing filesystem makes sure
      all the data is committed in the journal but the data doesn't have to be
      checkpointed. ext3_freeze() then takes care of checkpointing all the
      data so all buffer heads are clean but pages can still have dangling
      dirty bits. So when flusher thread comes later when filesystem is
      frozen, it tries to write back dirty pages, ext3_journalled_writepage()
      tries to start a transaction and hangs waiting for frozen fs causing a
      deadlock because a holder of s_umount semaphore may be waiting for
      flusher thread to complete.
      
      The fix is luckily relatively easy. We don't have to start a transaction
      in ext3_journalled_writepage() when a page is just dirty (and doesn't
      have PageChecked set) because in that case all buffers should be already
      mapped (mapping must happen before writing a buffer to the journal) and
      it is enough to write them out. This optimization also solves the deadlock
      because block_write_full_page() will just find out there's no buffer to
      write and do nothing.
      Signed-off-by: NJan Kara <jack@suse.cz>
      166418cc
    • J
      reiserfs: call truncate_setsize under tailpack mutex · 22e7478d
      Jeff Mahoney 提交于
      Prior to commit 0e4f6a79 (Fix reiserfs_file_release()), reiserfs
      truncates serialized on i_mutex. They mostly still do, with the exception
      of reiserfs_file_release. That blocks out other writers via the tailpack
      mutex and the inode openers counter adjusted in reiserfs_file_open.
      
      However, NFS will call reiserfs_setattr without having called ->open, so
      we end up with a race when nfs is calling ->setattr while another
      process is releasing the file. Ultimately, it triggers the
      BUG_ON(inode->i_size != new_file_size) check in maybe_indirect_to_direct.
      
      The solution is to pull the lock into reiserfs_setattr to encompass the
      truncate_setsize call as well.
      Signed-off-by: NJeff Mahoney <jeffm@suse.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NJan Kara <jack@suse.cz>
      22e7478d
  3. 21 5月, 2014 1 次提交
  4. 15 5月, 2014 1 次提交
  5. 13 5月, 2014 3 次提交
  6. 08 5月, 2014 14 次提交
  7. 07 5月, 2014 18 次提交