1. 23 Mar, 2014 4 commits
    • Al Viro's avatar
      rcuwalk: recheck mount_lock after mountpoint crossing attempts · b37199e6
      Al Viro authored
      We can get false negative from __lookup_mnt() if an unrelated vfsmount
      gets moved.  In that case legitimize_mnt() is guaranteed to fail,
      and we will fall back to non-RCU walk... unless we end up running
      into a hard error on a filesystem object we wouldn't have reached
      if not for that false negative.  IOW, delaying that check until
      the end of pathname resolution is wrong - we should recheck right
      after we attempt to cross the mountpoint.  We don't need to recheck
      unless we see d_mountpoint() being true - in that case even if
      we have just raced with mount/umount, we can simply go on as if
      we'd come at the moment when the sucker wasn't a mountpoint; if we
      run into a hard error as the result, it was a legitimate outcome.
      __lookup_mnt() returning NULL is different in that respect, since
      it might've happened due to operation on completely unrelated
      mountpoint.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      b37199e6
    • Al Viro's avatar
      make prepend_name() work correctly when called with negative *buflen · e825196d
      Al Viro authored
      In all callchains leading to prepend_name(), the value left in *buflen
      is eventually discarded unused if prepend_name() has returned a negative.
      So we are free to do what prepend() does, and subtract from *buflen
      *before* checking for underflow (which turns into checking the sign
      of subtraction result, of course).
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      e825196d
    • Eric Biggers's avatar
      vfs: Don't let __fdget_pos() get FMODE_PATH files · 99aea681
      Eric Biggers authored
      Commit bd2a31d5 ("get rid of fget_light()") introduced the
      __fdget_pos() function, which returns the resulting file pointer and
      fdput flags combined in an 'unsigned long'.  However, it also changed the
      behavior to return files with FMODE_PATH set, which shouldn't happen
      because read(), write(), lseek(), etc. aren't allowed on such files.
      This commit restores the old behavior.
      
      This regression actually had no effect on read() and write() since
      FMODE_READ and FMODE_WRITE are not set on file descriptors opened with
      O_PATH, but it did cause lseek() on a file descriptor opened with O_PATH
      to fail with ESPIPE rather than EBADF.
      Signed-off-by: default avatarEric Biggers <ebiggers3@gmail.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      99aea681
    • Eric Biggers's avatar
      vfs: atomic f_pos access in llseek() · d7a15f8d
      Eric Biggers authored
      Commit 9c225f26 ("vfs: atomic f_pos accesses as per POSIX") changed
      several system calls to use fdget_pos() instead of fdget(), but missed
      sys_llseek().  Fix it.
      Signed-off-by: default avatarEric Biggers <ebiggers3@gmail.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      d7a15f8d
  2. 22 Mar, 2014 2 commits
  3. 21 Mar, 2014 5 commits
  4. 20 Mar, 2014 6 commits
  5. 19 Mar, 2014 11 commits
  6. 18 Mar, 2014 8 commits
  7. 17 Mar, 2014 4 commits
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.dk/linux-block · 9a15c944
      Linus Torvalds authored
      Pull final final block IO fixes from Jens Axboe:
       "Yes, the last round was final. This one is final final.
      
        The mtip32xx fix could have waited, but it's so simple and gets rid of
        two warning spewages on load.  The two block flush fixes are critical
        for blk-mq, and are the primary reason for this late pull request"
      
      * 'for-linus' of git://git.kernel.dk/linux-block:
        mtip32xx: fix bad use of smp_processor_id()
        block: change flush sequence list addition back to front add
        block: fix q->flush_rq NULL pointer crash on dm-mpath flush
      9a15c944
    • Linus Torvalds's avatar
      Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus · 8a21d9f6
      Linus Torvalds authored
      Pull MIPS updates from Ralf Baechle:
       "A fair number of fixes all across arch/mips.  Nothing really stands
        out though APRP, the FPU code and syscall tracing code received
        multiple patches those all were small"
      
      * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus:
        MIPS: mark O32+FP64 experimental for now
        MIPS: ftrace: Fix icache flush range error
        MIPS: Fix syscall tracing interface
        MIPS: asm: syscall: Fix copying system call arguments
        MIPS: Octeon: Fix fall through on bar type OCTEON_DMA_BAR_TYPE_SMALL
        MIPS: FPU: Fix conflict of register usage
        MIPS: Replace CONFIG_MIPS64 and CONFIG_MIPS32_R2
        MIPS: math-emu: Fix prefx detection and COP1X function field definition
        MIPS: APRP: Choose the correct VPE loader by fixing the linking
        MIPS: APRP: Unregister rtlx interrupt hook at module exit
        MIPS: APRP: Fix the linking of rtlx interrupt hook
        MIPS: bcm47xx: Include missing errno.h for ENXIO
        MIPS: Alchemy: Fix unchecked kstrtoul return value
        MIPS: Fix randconfig build error.
      8a21d9f6
    • Paul Burton's avatar
      MIPS: mark O32+FP64 experimental for now · 06e2e882
      Paul Burton authored
      Commit 597ce172 "MIPS: Support for 64-bit FP with O32 binaries"
      introduced support for setting Status.FR=1 for O32 binaries with the
      EF_MIPS_FP64 ELF header flag set. Whilst this flag is currently
      supported by binutils it does introduce an ABI break within userland.
      Objects built with EF_MIPS_FP64 cannot be safely linked with those built
      without it since code in either object may assume behaviour specific to
      a value of FR.
      
      More recently there has been discussion around avoiding further
      fragmentation of the O32 ABI whilst still allowing the use of FR=1 and
      features such as MSA which depend upon it. Details of the plan to allow
      this are still being worked on, and whilst the kernel will need the
      ability to handle FR=1 with O32 tasks it is unclear what else it may
      need to provide to a userland which seeks to avoid another ABI break. In
      order to prevent the proliferation of userland which may rely upon the
      current EF_MIPS_FP64 behaviour this patch marks the kernel support for
      it experimental & disables it by default. Under current proposals it is
      likely that this support can simply be enabled again later, but possibly
      after the introduction of further interfaces with userland and support
      for the MIPS R5 UFR feature.
      Signed-off-by: default avatarPaul Burton <paul.burton@imgtec.com>
      Cc: Matthew Fortune <matthew.fortune@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Cc: Paul Burton <paul.burton@imgtec.com>
      Patchwork: https://patchwork.linux-mips.org/patch/6549/Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
      06e2e882
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid · 9f8b483c
      Linus Torvalds authored
      Pull HID fixes from Jiri Kosina:
      
       - fix for ordering of device removal actions in hidraw, by Fernando
         Luis Vázquez Cao
      
       - fix for uninitialized workqueue usage in hid-sony, by Frank Praznik
      
       - device ID addition for new variant of Logitech G27, from Simon Wood
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
        HID: hid-lg4ff: Support new version of G27
        HID: hidraw: fix warning destroying hidraw device files after parent
        HID: sony: Fix work queue issues.
      9f8b483c