1. 09 Jul, 2014 8 commits
    • Linus Torvalds's avatar
      Merge tag 'f2fs-fixes-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs · 191d385f
      Linus Torvalds authored
      Pull f2fs bugfixes from Jaegeuk Kim:
       "This includes a couple of bug fixes found by xfstests.  In addition,
        one critical bug was reported by Brian Chadwick, which is falling into
        the infinite loop in balance_dirty_pages.  And it turned out due to
        the IO merging policy in f2fs, which was newly merged in 3.16.
      
         - fix normal and recovery path for fallocated regions
         - fix error case mishandling
         - recover renamed fsync inodes correctly
         - fix to get out of infinite loops in balance_dirty_pages
         - fix kernel NULL pointer error"
      
      * tag 'f2fs-fixes-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs:
        f2fs: avoid to access NULL pointer in issue_flush_thread
        f2fs: check bdi->dirty_exceeded when trying to skip data writes
        f2fs: do checkpoint for the renamed inode
        f2fs: release new entry page correctly in error path of f2fs_rename
        f2fs: fix error path in init_inode_metadata
        f2fs: check lower bound nid value in check_nid_range
        f2fs: remove unused variables in f2fs_sm_info
        f2fs: fix not to allocate unnecessary blocks during fallocate
        f2fs: recover fallocated data and its i_size together
        f2fs: fix to report newly allocate region as extent
      191d385f
    • Chao Yu's avatar
      f2fs: avoid to access NULL pointer in issue_flush_thread · 50e1f8d2
      Chao Yu authored
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=75861
      
      Denis 2014-05-10 11:28:59 UTC reported:
      "F2FS-fs (mmcblk0p28): mounting..
       Unable to handle kernel NULL pointer dereference at virtual address 00000018
       ...
       [<c0a2f678>] (_raw_spin_lock+0x3c/0x70) from [<c03a0330>] (issue_flush_thread+0x50/0x17c)
       [<c03a0330>] (issue_flush_thread+0x50/0x17c) from [<c01b4064>] (kthread+0x98/0xa4)
       [<c01b4064>] (kthread+0x98/0xa4) from [<c0108060>] (kernel_thread_exit+0x0/0x8)"
      
      This patch assign cmd_control_info in sm_info before issue_flush_thread is being
      created, so this make sure that issue flush thread will have no chance to access
      invalid info in fcc.
      Signed-off-by: default avatarChao Yu <chao2.yu@samsung.com>
      Reviewed-by: default avatarGu Zheng <guz.fnst@cn.fujitsu.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      50e1f8d2
    • Jaegeuk Kim's avatar
      f2fs: check bdi->dirty_exceeded when trying to skip data writes · 2743f865
      Jaegeuk Kim authored
      If we don't check the current backing device status, balance_dirty_pages can
      fall into infinite pausing routine.
      
      This can be occurred when a lot of directories make a small number of dirty
      dentry pages including files.
      Reported-by: default avatarBrian Chadwick <brianchad@westnet.com.au>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      2743f865
    • Jaegeuk Kim's avatar
      f2fs: do checkpoint for the renamed inode · b2c08299
      Jaegeuk Kim authored
      If an inode is renamed, it should be registered as file_lost_pino to conduct
      checkpoint at f2fs_sync_file.
      Otherwise, the inode cannot be recovered due to no dent_mark in the following
      scenario.
      
      Note that, this scenario is from xfstests/322.
      
      1. create "a"
      2. fsync "a"
      3. rename "a" to "b"
      4. fsync "b"
      5. Sudden power-cut
      
      After recovery is done, "b" should be seen.
      However, the result shows "a", since the recovery procedure does not enter
      recover_dentry due to no dent_mark.
      
      The reason is like below.
      - The nid of "a" is checkpointed during #2, f2fs_sync_file.
      - The inode page for "b" produced by #3 is written without dent_mark by
      sync_node_pages.
      
      So, this patch fixes this bug by assinging file_lost_pino to the "a"'s inode.
      If the pino is lost, f2fs_sync_file conducts checkpoint, and then recovers
      the latest pino and its dentry information for further recovery.
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      b2c08299
    • Chao Yu's avatar
      f2fs: release new entry page correctly in error path of f2fs_rename · dd4d961f
      Chao Yu authored
      This patch correct releasing code of new_page to avoid BUG_ON in error patch of
      f2fs_rename.
      Signed-off-by: default avatarChao Yu <chao2.yu@samsung.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      dd4d961f
    • Chao Yu's avatar
      f2fs: fix error path in init_inode_metadata · 90d72459
      Chao Yu authored
      If we fail in this path:
      ->init_inode_metadata
        ->make_empty_dir
          ->get_new_data_page
            ->grab_cache_page return -ENOMEM
      
      We will bug on in error path of init_inode_metadata when call remove_inode_page
      because i_block = 2 (one inode block will be released later & one dentry block).
      
      We should release the dentry block in init_inode_metadata to avoid this BUG_ON,
      and avoid leak of dentry block resource, because we never have second chance to
      release that block in ->evict_inode as in upper error path we make this inode
      'bad'.
      Signed-off-by: default avatarChao Yu <chao2.yu@samsung.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      90d72459
    • Chao Yu's avatar
      f2fs: check lower bound nid value in check_nid_range · d6b7d4b3
      Chao Yu authored
      This patch add lower bound verification for nid in check_nid_range, so nids
      reserved like 0, node, meta passed by caller could be checked there.
      
      And then check_nid_range could be used in f2fs_nfs_get_inode for simplifying
      code.
      Signed-off-by: default avatarChao Yu <chao2.yu@samsung.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      d6b7d4b3
    • Chao Yu's avatar
      f2fs: remove unused variables in f2fs_sm_info · 8bc6f60e
      Chao Yu authored
      Remove unused variables in struct f2fs_sm_info.
      Signed-off-by: default avatarChao Yu <chao2.yu@samsung.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      8bc6f60e
  2. 08 Jul, 2014 1 commit
  3. 07 Jul, 2014 7 commits
  4. 06 Jul, 2014 4 commits
    • Linus Torvalds's avatar
      Linux 3.16-rc4 · cd3de83f
      Linus Torvalds authored
      cd3de83f
    • Linus Torvalds's avatar
      Merge tag 'dt-for-linus' of git://git.secretlab.ca/git/linux · 100193f5
      Linus Torvalds authored
      Pull devicetree bugfix from Grant Likely:
       "Important bug fix for parsing 64-bit addresses on 32-bit platforms.
        Without this patch the kernel will try to use memory ranges that
        cannot be reached"
      
      * tag 'dt-for-linus' of git://git.secretlab.ca/git/linux:
        of: Check for phys_addr_t overflows in early_init_dt_add_memory_arch
      100193f5
    • Linus Torvalds's avatar
      Merge tag 'scsi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · 8addf0c7
      Linus Torvalds authored
      Pull SCSI fixes from James Bottomley:
       "This is a set of 13 fixes, a MAINTAINERS update and a sparse update.
        The fixes are mostly correct value initialisations, avoiding NULL
        derefs and some uninitialised pointer avoidance.
      
        All the patches have been incubated in -next for a few days.  The
        final patch (use the scsi data buffer length to extract transfer size)
        has been rebased to add a cc to stable, but only the commit message
        has changed"
      
      * tag 'scsi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        [SCSI] use the scsi data buffer length to extract transfer size
        virtio-scsi: fix various bad behavior on aborted requests
        virtio-scsi: avoid cancelling uninitialized work items
        ibmvscsi: Add memory barriers for send / receive
        ibmvscsi: Abort init sequence during error recovery
        qla2xxx: Fix sparse warning in qla_target.c.
        bnx2fc: Improve stats update mechanism
        bnx2fc: do not scan uninitialized lists in case of error.
        fc: ensure scan_work isn't active when freeing fc_rport
        pm8001: Fix potential null pointer dereference and memory leak.
        MAINTAINERS: Update LSILOGIC MPT FUSION DRIVERS (FC/SAS/SPI) maintainers Email IDs
        be2iscsi: remove potential junk pointer free
        be2iscsi: add an missing goto in error path
        scsi_error: set DID_TIME_OUT correctly
        scsi_error: fix invalid setting of host byte
      8addf0c7
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux · 110e4308
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "i915, tda998x and vmwgfx fixes,
      
        The main one is i915 fix for missing VGA connectors, along with some
        fixes for the tda998x from Russell fixing some modesetting problems.
      
        (still on holidays, but got a spare moment to find these)"
      
      * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
        drm/vmwgfx: Fix incorrect write to read-only register v2:
        drm/i915: Drop early VLV WA to fix Voltage not getting dropped to Vmin
        drm/i915: only apply crt_present check on VLV
        drm/i915: Wait for vblank after enabling the primary plane on BDW
        drm/i2c: tda998x: add some basic mode validation
        drm/i2c: tda998x: faster polling for edid
        drm/i2c: tda998x: move drm_i2c_encoder_destroy call
      110e4308
  5. 05 Jul, 2014 12 commits
  6. 04 Jul, 2014 8 commits