1. 17 Apr, 2015 40 commits
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile · 6b6e177d
      Linus Torvalds authored
      Pull arch/tile updates from Chris Metcalf:
       "These are mostly nohz_full changes, plus a smattering of minor fixes
        (notably a couple for ftrace)"
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile:
        tile: nohz: warn if nohz_full uses hypervisor shared cores
        tile: ftrace: fix function_graph tracer issues
        tile: map data region shadow of kernel as R/W
        tile: support CONTEXT_TRACKING and thus NOHZ_FULL
        tile: support arch_irq_work_raise
        arch: tile: fix null pointer dereference on pt_regs pointer
        tile/elf: reorganize notify_exec()
        tile: use si_int instead of si_ptr for compat_siginfo
      6b6e177d
    • Linus Torvalds's avatar
      Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus · bfaf2450
      Linus Torvalds authored
      Pull MIPS updates from Ralf Baechle:
       "This is the main pull request for MIPS for Linux 4.1.  Most
        noteworthy:
      
         - Add more Octeon-optimized crypto functions
         - Octeon crypto preemption and locking fixes
         - Little endian support for Octeon
         - Use correct CSR to soft reset Octeons
         - Support LEDs on the Octeon-based DSR-1000N
         - Fix PCI interrupt mapping for the Octeon-based DSR-1000N
         - Mark prom_free_prom_memory() as __init for a number of systems
         - Support for Imagination's Pistachio SOC.  This includes arch and
           CLK bits.  I'd like to merge pinctrl bits later
         - Improve parallelism of csum_partial for certain pipelines
         - Organize DTB files in subdirs like other architectures
         - Implement read_sched_clock for all MIPS platforms other than
           Octeon
         - Massive series of 38 fixes and cleanups for the FPU emulator /
           kernel
         - Further FPU remulator work to support new features.  This sits on a
           separate branch which also has been pulled into the 4.1 KVM branch
         - Clean up and fixes for the SEAD3 eval board; remove unused file
         - Various updates for Netlogic platforms
         - A number of small updates for Loongson 3 platforms
         - Increase the memory limit for ATH79 platforms to 256MB
         - A fair number of fixes and updates for BCM47xx platforms
         - Finish the implementation of XPA support
         - MIPS FDC support.  No, not floppy controller but Fast Debug Channel :)
         - Detect the R16000 used in SGI legacy platforms
         - Fix Kconfig dependencies for the SSB bus support"
      
      * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (265 commits)
        MIPS: Makefile: Fix MIPS ASE detection code
        MIPS: asm: elf: Set O32 default FPU flags
        MIPS: BCM47XX: Fix detecting Microsoft MN-700 & Asus WL500G
        MIPS: Kconfig: Disable SMP/CPS for 64-bit
        MIPS: Hibernate: flush TLB entries earlier
        MIPS: smp-cps: cpu_set FPU mask if FPU present
        MIPS: lose_fpu(): Disable FPU when MSA enabled
        MIPS: ralink: add missing symbol for RALINK_ILL_ACC
        MIPS: ralink: Fix bad config symbol in PCI makefile.
        SSB: fix Kconfig dependencies
        MIPS: Malta: Detect and fix bad memsize values
        Revert "MIPS: Avoid pipeline stalls on some MIPS32R2 cores."
        MIPS: Octeon: Delete override of cpu_has_mips_r2_exec_hazard.
        MIPS: Fix cpu_has_mips_r2_exec_hazard.
        MIPS: kernel: entry.S: Set correct ISA level for mips_ihb
        MIPS: asm: spinlock: Fix addiu instruction for R10000_LLSC_WAR case
        MIPS: r4kcache: Use correct base register for MIPS R6 cache flushes
        MIPS: Kconfig: Fix typo for the r2-to-r6 emulator kernel parameter
        MIPS: unaligned: Fix regular load/store instruction emulation for EVA
        MIPS: unaligned: Surround load/store macros in do {} while statements
        ...
      bfaf2450
    • Linus Torvalds's avatar
      Merge tag 'xtensa-20150416' of git://github.com/czankel/xtensa-linux · 96d928ed
      Linus Torvalds authored
      Pull Xtensa updates from Chris Zankel:
      
       - fix linker script transformation for .text / .text.fixup
      
       - wire bpf and execveat syscalls
      
       - provide __NR_sync_file_range2 instead of __NR_sync_file_range, as
         that's what xtensa uses.
      
       - make xtfpgs LCD driver functional and configurable.  This fixes
         hardware lockup on KC705/ML605 boot
      
       - add audio subsystem bits to xtfpga DTS and provide sample KC705
         config with audio features enabled
      
       - add CY7C67300 USB controller support to XTFPGA
      
       - fix locking issues in ISS network driver
      
       - document PIC and MX interrupt distributor device tree bindings
      
      * tag 'xtensa-20150416' of git://github.com/czankel/xtensa-linux:
        xtensa: xtfpga: add CY7C67300 USB controller support
        irqchip: xtensa-pic: xtensa-mx: document DT bindings
        xtensa: ISS: fix locking in TAP network adapter
        xtensa: Fix fix linker script transformation for .text / .text.fixup
        xtensa: provide __NR_sync_file_range2 instead of __NR_sync_file_range
        xtensa: wire bpf and execveat syscalls
        xtensa: xtfpga: fix hardware lockup caused by LCD driver
        xtensa: xtfpga: provide defconfig with audio subsystem
        xtensa: xtfpga: add audio card to xtfpga DTS
      96d928ed
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.dk/linux-block · e076b7c1
      Linus Torvalds authored
      Pull block core fix from Jens Axboe:
       "A commit in the previous pull request introduce a regression.  So far
        only observed on qemu-sparc64, but it's a general bug.  Please pull
        this single fix to rectify that, thanks"
      
      [ And it turns out that it's been seen outside of that qemu-sparc64
        case, and is easy to trigger with small number of CPUs and blk-mq
        enabled by default - Linus ]
      
      * 'for-linus' of git://git.kernel.dk/linux-block:
        blk-mq: fix iteration of busy bitmap
      e076b7c1
    • Linus Torvalds's avatar
      Merge tag 'acpica-4.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 0f5abd40
      Linus Torvalds authored
      Pull ACPICA updates from Rafael Wysocki:
       "This updates the kernel's ACPICA code to upstream revision 20150410
        and adds a fix for a GPE handling regression introduced during the
        3.19 cycle on top of that.
      
        Included are two stable-candidate bug fixes (one of them fixing a 3.16
        regression), multiple other fixes and a bunch of cleanups.
      
        Specifics:
      
         - Fix for a GPE handling regression on Dell Latitude D600 that caused
           GPE signaling to stop working on that machine, which appears to be
           due to a hardware glitch, but it used to work and it can be made
           work again in a relativly straightforward way (Rafael J Wysocki).
      
         - Fix for a mutex unlock regression related to the handling of ACPI
           tables introduced during the 3.16 development cycle (Octavian
           Purdila).
      
         - _REV modification to always return 2 which has been done by all
           versions of Windows since NT and the firmware people started to use
           it to distinguish between OSes in their AML and do some silly and
           wrong things on that basis (Bob Moore).
      
         - Fixes and cleanups related to the acpi_physicall_address data type
           including one stable-candidate fix for an issue occasionally
           occuring on 64-bit machines running 32-bit kernels where using
           offsets provided by the firmware may lead to address overflows (Lv
           Zheng).
      
         - External() opcode support infrastructure needed for recompiling
           disassembled ACPI tables in some cases including interpreter
           modification to ignore that opcode (Bob Moore).
      
         - Support for the "Windows 2015" string in _OSI (Bob Moore).
      
         - GPE debug interface change to return values read from hardware
           registers (Lv Zheng).
      
         - Removal of the __DATE__ macro usage in tools (Rasmus Villemoes).
      
         - Assorted minor fixes and cleanups (Lv Zheng, Rickard Strandqvist,
           Bob Moore)"
      
      * tag 'acpica-4.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (32 commits)
        ACPICA: Store GPE register enable masks upfront
        ACPICA: Update version to 20150410.
        ACPICA: Fix a couple issues with the local printf module.
        ACPICA: Disassembler: Some cleanup of the table dump module.
        ACPICA: iASL: Add support for MSDM ACPI table.
        ACPICA: Update for SLIC ACPI table.
        ACPICA: Add "//" before ascii output of buffers.
        ACPICA: Remove unused internal AML opcode.
        ACPICA: Permanently set _REV to the value '2'.
        ACPICA: Add "Windows 2015" string to _OSI support.
        ACPICA: Add infrastructure for External() opcode.
        ACPICA: iASL: Enhancement for constant folding.
        ACPICA: iASL/Disassembler: Add option to assume table contains valid AML.
        ACPICA: Update AML Debugger global variables.
        ACPICA: Update Resource descriptor dump module.
        ACPICA: Fix a sscanf format string.
        ACPICA: Casting changes around acpi_physical_address/acpi_size.
        ACPICA: Resources: Correct conditional compilation definitions.
        ACPICA: Utilities: Correct conditional compilation definitions.
        ACPICA: Tables: Move an iasl specific table function to iasl source file.
        ...
      0f5abd40
    • Chris Metcalf's avatar
      tile: nohz: warn if nohz_full uses hypervisor shared cores · 128f3cb9
      Chris Metcalf authored
      The "hypervisor shared" cores are ones that the Tilera hypervisor
      uses to receive interrupts to manage hypervisor-owned devices.
      It's a bad idea to try to use those cores with nohz_full, since
      they will get interrupted unpredictably -- and invisibly to Linux
      tracing tools, since the interrupts are delivered at a higher
      privilege level to the Tilera hypervisor.
      
      Generate a clear warning at boot up that this doesn't end well
      for the nohz_full cores in question.
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      128f3cb9
    • Tony Lu's avatar
      tile: ftrace: fix function_graph tracer issues · 437d3e12
      Tony Lu authored
      - Add support for ARCH_SUPPORTS_FTRACE_OPS
      - Replace the instruction in ftrace_call with the bundle {move r10, lr;
      jal ftrace_stub}, so that the lr contains the right value after returning
      from ftrace_stub.  An alternative fix might be to leave the instruction
      in ftrace_call alone when it is being updated with ftrace_stub.
      Signed-off-by: default avatarTony Lu <zlu@ezchip.com>
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      437d3e12
    • Chris Metcalf's avatar
      tile: map data region shadow of kernel as R/W · a84f2423
      Chris Metcalf authored
      This is necessary for things like reading /proc/kcore, doing ftrace,
      etc.  It happens by default when using huge pages to map the kernel
      data, but not when using small pages.
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      a84f2423
    • Chris Metcalf's avatar
      tile: support CONTEXT_TRACKING and thus NOHZ_FULL · 49e4e156
      Chris Metcalf authored
      Add the TIF_NOHZ flag appropriately.
      
      Add call to user_exit() on entry to do_work_pending() and on entry
      to syscalls via do_syscall_trace_enter(), and also the top of
      do_syscall_trace_exit() just because it's done in x86.
      
      Add call to user_enter() at the bottom of do_work_pending() once we
      have no more work to do before returning to userspace.
      
      Wrap all the trap code in exception_enter() / exception_exit().
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      Acked-by: default avatarFrederic Weisbecker <fweisbec@gmail.com>
      49e4e156
    • Chris Metcalf's avatar
      tile: support arch_irq_work_raise · b340c656
      Chris Metcalf authored
      Tile includes a hypervisor hook to deliver messages to arbitrary
      tiles, so we can use that to raise an interrupt as soon as
      possible on our own core.  Unfortunately the Tilera hypervisor
      disabled that support on principle in previous releases, but
      it will be available in MDE 4.3.4 and later.
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      Acked-by: default avatarFrederic Weisbecker <fweisbec@gmail.com>
      b340c656
    • Colin Ian King's avatar
      arch: tile: fix null pointer dereference on pt_regs pointer · 9088616f
      Colin Ian King authored
      Cppcheck reports the following issue:
      [arch/tile/kernel/stack.c:116]: (error) Possible null
        pointer dereference: p
      
      In this case, on reporting on an odd fault, p is set to NULL
      and immediately afterwords p is dereferenced iff
      !kbt->profile is false.  Rather than doing this check just
      return NULL rather than falling through to the potential
      null pointer dereference (since the original intentional
      outcome would be to return NULL anyhow) for this odd fault
      case.
      Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
      Signed-off-by: Chris Metcalf <cmetcalf@ezchip.com> [tweaked lightly]
      9088616f
    • Davidlohr Bueso's avatar
      tile/elf: reorganize notify_exec() · 5a3b4e80
      Davidlohr Bueso authored
      In the future mm->exe_file will be done without mmap_sem
      serialization, thus isolate and reorganize the tile elf
      code to make the transition easier. Good users will, make
      use of the more standard get_mm_exe_file(), requiring only
      holding the mmap_sem to read the value, and relying on reference
      counting to make sure that the exe file won't dissappear
      underneath us.
      
      The visible effects of this patch are:
      
         o We now take and drop the mmap_sem more often. Instead of
           just in arch_setup_additional_pages(), we also do it in:
      
           1) get_mm_exe_file()
           2) to get the mm->vm_file and notify the simulator.
      
          [Note that 1) will disappear once we change the locking
           rules for exe_file.]
      
         o We avoid getting a free page and doing d_path() while
           holding the mmap_sem. This requires reordering the checks.
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      5a3b4e80
    • Chris Metcalf's avatar
      tile: use si_int instead of si_ptr for compat_siginfo · 89067c2d
      Chris Metcalf authored
      To be compatible with the generic get_compat_sigevent(), the
      copy_siginfo_to_user32() and thus copy_siginfo_from_user32()
      have to use si_int instead of si_ptr.  Using si_ptr means that
      for the case of ILP32 compat code running in big-endian mode,
      we would end up copying the high 32 bits of the pointer value
      into si_int instead of the desired low 32 bits.
      Signed-off-by: default avatarChris Metcalf <cmetcalf@ezchip.com>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      89067c2d
    • Jens Axboe's avatar
      blk-mq: fix iteration of busy bitmap · 569fd0ce
      Jens Axboe authored
      Commit 889fa31f was a bit too eager in reducing the loop count,
      so we ended up missing queues in some configurations. Ensure that
      our division rounds up, so that's not the case.
      Reported-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Fixes: 889fa31f ("blk-mq: reduce unnecessary software queue looping")
      Signed-off-by: default avatarJens Axboe <axboe@fb.com>
      569fd0ce
    • Linus Torvalds's avatar
      Merge branch 'akpm' (patches from Andrew) · 54e514b9
      Linus Torvalds authored
      Merge third patchbomb from Andrew Morton:
      
       - various misc things
      
       - a couple of lib/ optimisations
      
       - provide DIV_ROUND_CLOSEST_ULL()
      
       - checkpatch updates
      
       - rtc tree
      
       - befs, nilfs2, hfs, hfsplus, fatfs, adfs, affs, bfs
      
       - ptrace fixes
      
       - fork() fixes
      
       - seccomp cleanups
      
       - more mmap_sem hold time reductions from Davidlohr
      
      * emailed patches from Andrew Morton <akpm@linux-foundation.org>: (138 commits)
        proc: show locks in /proc/pid/fdinfo/X
        docs: add missing and new /proc/PID/status file entries, fix typos
        drivers/rtc/rtc-at91rm9200.c: make IO endian agnostic
        Documentation/spi/spidev_test.c: fix warning
        drivers/rtc/rtc-s5m.c: allow usage on device type different than main MFD type
        .gitignore: ignore *.tar
        MAINTAINERS: add Mediatek SoC mailing list
        tomoyo: reduce mmap_sem hold for mm->exe_file
        powerpc/oprofile: reduce mmap_sem hold for exe_file
        oprofile: reduce mmap_sem hold for mm->exe_file
        mips: ip32: add platform data hooks to use DS1685 driver
        lib/Kconfig: fix up HAVE_ARCH_BITREVERSE help text
        x86: switch to using asm-generic for seccomp.h
        sparc: switch to using asm-generic for seccomp.h
        powerpc: switch to using asm-generic for seccomp.h
        parisc: switch to using asm-generic for seccomp.h
        mips: switch to using asm-generic for seccomp.h
        microblaze: use asm-generic for seccomp.h
        arm: use asm-generic for seccomp.h
        seccomp: allow COMPAT sigreturn overrides
        ...
      54e514b9
    • Andrey Vagin's avatar
      proc: show locks in /proc/pid/fdinfo/X · 6c8c9031
      Andrey Vagin authored
      Let's show locks which are associated with a file descriptor in
      its fdinfo file.
      
      Currently we don't have a reliable way to determine who holds a lock.  We
      can find some information in /proc/locks, but PID which is reported there
      can be wrong.  For example, a process takes a lock, then forks a child and
      dies.  In this case /proc/locks contains the parent pid, which can be
      reused by another process.
      
      $ cat /proc/locks
      ...
      6: FLOCK  ADVISORY  WRITE 324 00:13:13431 0 EOF
      ...
      
      $ ps -C rpcbind
        PID TTY          TIME CMD
        332 ?        00:00:00 rpcbind
      
      $ cat /proc/332/fdinfo/4
      pos:	0
      flags:	0100000
      mnt_id:	22
      lock:	1: FLOCK  ADVISORY  WRITE 324 00:13:13431 0 EOF
      
      $ ls -l /proc/332/fd/4
      lr-x------ 1 root root 64 Mar  5 14:43 /proc/332/fd/4 -> /run/rpcbind.lock
      
      $ ls -l /proc/324/fd/
      total 0
      lrwx------ 1 root root 64 Feb 27 14:50 0 -> /dev/pts/0
      lrwx------ 1 root root 64 Feb 27 14:50 1 -> /dev/pts/0
      lrwx------ 1 root root 64 Feb 27 14:49 2 -> /dev/pts/0
      
      You can see that the process with the 324 pid doesn't hold the lock.
      
      This information is required for proper dumping and restoring file
      locks.
      Signed-off-by: default avatarAndrey Vagin <avagin@openvz.org>
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: Alexander Viro <viro@zeniv.linux.org.uk>
      Acked-by: default avatarJeff Layton <jlayton@poochiereds.net>
      Acked-by: default avatar"J. Bruce Fields" <bfields@fieldses.org>
      Acked-by: default avatarCyrill Gorcunov <gorcunov@openvz.org>
      Cc: Pavel Emelyanov <xemul@parallels.com>
      Cc: Joe Perches <joe@perches.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6c8c9031
    • Nathan Scott's avatar
      docs: add missing and new /proc/PID/status file entries, fix typos · 15eb42d6
      Nathan Scott authored
      docs: add missing and new /proc/PID/status file entries, fix typos
      Signed-off-by: default avatarNathan Scott <nathans@redhat.com>
      Signed-off-by: default avatarChen Hanxiao <chenhanxiao@cn.fujitsu.com>
      Cc: Serge Hallyn <serge.hallyn@canonical.com>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      15eb42d6
    • Ben Dooks's avatar
      drivers/rtc/rtc-at91rm9200.c: make IO endian agnostic · 6da7bb1e
      Ben Dooks authored
      Change the __raw IO calls to readl/write_relaxed which makes the driver
      endian agnostic to run properly on big endian systems.
      Signed-off-by: default avatarBen Dooks <ben.dooks@codethink.co.uk>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Cc: Andrew Victor <linux@maxim.org.za>
      Acked-by: default avatarNicolas Ferre <nicolas.ferre@atmel.com>
      Acked-by: default avatarJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6da7bb1e
    • Andrew Morton's avatar
      Documentation/spi/spidev_test.c: fix warning · 07eec628
      Andrew Morton authored
      Documentation/spi/spidev_test.c:83:5: warning: no previous prototype for 'unespcape' [-Wmissing-prototypes]
      
      fix spelling too.
      Acked-by: default avatarMark Brown <broonie@kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      07eec628
    • Krzysztof Kozlowski's avatar
      drivers/rtc/rtc-s5m.c: allow usage on device type different than main MFD type · 94f91922
      Krzysztof Kozlowski authored
      The RTC driver supports two flavors of S5M devices: S5M8767-like and
      S2MPS14-like.
      
      On S2MPS13 and S2MPS14 devices the RTC module is the same so we want to
      re-use the existing support of S2MPS14.  However device type was passed
      from parent MFD driver in platform data structure.  This way for the
      S2MPS13 device the main MFD driver passed device type of 'S2MPS13X'.
      
      Instead decouple detecting of device type between main MFD and RTC driver.
       This allows adding support for other S2MPS14 variations (like S2MPS11 and
      S2MPS13) easily by adding to mfd/sec-core.c:
      
      static const struct mfd_cell s2mps13_devs[] = {
      	{ .name = "s2mps14-rtc", }
      };
      Signed-off-by: default avatarKrzysztof Kozlowski <k.kozlowski@samsung.com>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Cc: Kyungmin Park <kyungmin.park@samsung.com>
      Cc: Marek Szyprowski <m.szyprowski@samsung.com>
      Cc: Chanwoo Choi <cw00.choi@samsung.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      94f91922
    • Andrey Skvortsov's avatar
      .gitignore: ignore *.tar · f4ae9497
      Andrey Skvortsov authored
      Running make tar-pkg results in following:
      
       # Untracked files:
       #   (use "git add <file>..." to include in what will be committed)
       #
       #       linux-4.0.0-rc3-next-20150313-150225--x86.tar
      
      This patch makes git ignore *.tar files.
      Running 'git ls-files -i --exclude-standard' does not show any
      tar files excluded from tracking after the change.
      Signed-off-by: default avatarAndrey Skvortsov <andrej.skvortzov@gmail.com>
      Cc: Michal Marek <mmarek@suse.cz>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: Boaz Harrosh <boaz@plexistor.com>
      Cc: Andi Kleen <ak@linux.intel.com>
      Cc: Benjamin Romer <benjamin.romer@unisys.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      f4ae9497
    • Matthias Brugger's avatar
      MAINTAINERS: add Mediatek SoC mailing list · 17b199d6
      Matthias Brugger authored
      Add the new list that Mediatek specific patches should also be
      directed to.
      Signed-off-by: default avatarMatthias Brugger <matthias.bgg@gmail.com>
      Cc: Olof Johansson <olof@lixom.net>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      17b199d6
    • Davidlohr Bueso's avatar
      tomoyo: reduce mmap_sem hold for mm->exe_file · d4144ea6
      Davidlohr Bueso authored
      The mm->exe_file is currently serialized with mmap_sem (shared) in order
      to both safely (1) read the file and (2) compute the realpath by calling
      tomoyo_realpath_from_path, making it an absolute overkill.  Good users
      will, on the other hand, make use of the more standard get_mm_exe_file(),
      requiring only holding the mmap_sem to read the value, and relying on
      reference
      
      [akpm@linux-foundation.org: coding-style fixes]
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Acked-by: default avatarTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
      Cc: James Morris <jmorris@namei.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      d4144ea6
    • Davidlohr Bueso's avatar
      powerpc/oprofile: reduce mmap_sem hold for exe_file · fd89a65f
      Davidlohr Bueso authored
      In the future mm->exe_file will be done without mmap_sem serialization,
      thus isolate and reorganize the related code to make the transition
      easier.  Good users will, make use of the more standard get_mm_exe_file(),
      requiring only holding the mmap_sem to read the value, and relying on
      reference counting to make sure that the exe file won't dissappear
      underneath us while getting the dcookie.
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Robert Richter <rric@kernel.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      fd89a65f
    • Davidlohr Bueso's avatar
      oprofile: reduce mmap_sem hold for mm->exe_file · 11163348
      Davidlohr Bueso authored
      sync_buffer() needs the mmap_sem for two distinct operations, both only
      occurring upon user context switch handling:
      
       1) Dealing with the exe_file.
      
       2) Adding the dcookie data as we need to lookup the vma that
         backs it. This is done via add_sample() and add_data().
      
      This patch isolates 1), for it will no longer need the mmap_sem for
      serialization.  However, for now, make of the more standard
      get_mm_exe_file(), requiring only holding the mmap_sem to read the value,
      and relying on reference counting to make sure that the exe file won't
      dissappear underneath us while doing the get dcookie.
      
      As a consequence, for 2) we move the mmap_sem locking into where we really
      need it, in lookup_dcookie().  The benefits are twofold: reduce mmap_sem
      hold times, and cleaner code.
      
      [akpm@linux-foundation.org: export get_mm_exe_file for arch/x86/oprofile/oprofile.ko]
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Cc: Robert Richter <rric@kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      11163348
    • Joshua Kinard's avatar
      mips: ip32: add platform data hooks to use DS1685 driver · 15beb694
      Joshua Kinard authored
      This modifies the IP32 (SGI O2) platform and reset code to utilize the new
      rtc-ds1685 driver.  The old mc146818rtc.h header is removed and ip32_defconfig
      is updated as well.
      Signed-off-by: default avatarJoshua Kinard <kumba@gentoo.org>
      Acked-by: default avatarRalf Baechle <ralf@linux-mips.org>
      Cc: Alessandro Zummo <a.zummo@towertech.it>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      15beb694
    • Andrew Morton's avatar
      lib/Kconfig: fix up HAVE_ARCH_BITREVERSE help text · 9e522c0d
      Andrew Morton authored
      Cc: Yalin Wang <yalin.wang@sonymobile.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      9e522c0d
    • Kees Cook's avatar
      x86: switch to using asm-generic for seccomp.h · 8eb68bf7
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions. The obsolete sigreturn syscall override
      is retained in 32-bit mode, and the ia32 syscall overrides are used in
      the compat case. Remaining definitions were identical.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      8eb68bf7
    • Kees Cook's avatar
      sparc: switch to using asm-generic for seccomp.h · d0f138b0
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions. The obsolete sigreturn in COMPAT mode
      is retained as an override. Remaining definitions are identical. Also
      corrected missing #define for header reinclusion protection.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      d0f138b0
    • Kees Cook's avatar
      powerpc: switch to using asm-generic for seccomp.h · 1a3aff9e
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions.  The obsolete sigreturn in COMPAT mode is
      retained as an override.  Remaining definitions are identical, though they
      incorrectly appeared in uapi, which has been corrected.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1a3aff9e
    • Kees Cook's avatar
      parisc: switch to using asm-generic for seccomp.h · cf7a71b6
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions. Definitions were identical.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
      Cc: Helge Deller <deller@gmx.de>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      cf7a71b6
    • Kees Cook's avatar
      mips: switch to using asm-generic for seccomp.h · 97247fd9
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions.  COMPAT definitions retain their
      overrides and the remaining definitions were identical.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      97247fd9
    • Kees Cook's avatar
      microblaze: use asm-generic for seccomp.h · cc2d316f
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions. Since microblaze is 32-bit, the COMPAT
      seccomp defines are unused and can be dropped. The obsolete sigreturn
      for seccomp strict mode is retained as an override. Remaining definitions
      are identical.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Michal Simek <monstr@monstr.eu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      cc2d316f
    • Kees Cook's avatar
      arm: use asm-generic for seccomp.h · 6bcf4e9a
      Kees Cook authored
      Switch to using the newly created asm-generic/seccomp.h for the seccomp
      strict mode syscall definitions. Definitions were identical.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Laura Abbott <lauraa@codeaurora.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6bcf4e9a
    • Kees Cook's avatar
      seccomp: allow COMPAT sigreturn overrides · ddaa27ee
      Kees Cook authored
      Most architectures don't need to do much special for the strict-mode
      seccomp syscall entries.  Remove the redundant headers and reduce the
      others.
      
      This patch (of 8):
      
      Some architectures may need to override the compat sigreturn definition,
      as is already possible in the non-compat case.
      Signed-off-by: default avatarKees Cook <keescook@chromium.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Daniel Borkmann <dborkman@redhat.com>
      Cc: Laura Abbott <lauraa@codeaurora.org>
      Cc: James Hogan <james.hogan@imgtec.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      ddaa27ee
    • Davidlohr Bueso's avatar
      arc: do not export symbols in troubleshoot.c · be2a7fce
      Davidlohr Bueso authored
      print_task_path_n_nm() is local to this file, its only user being
      show_regs().  Mark the function static and avoid the EXPORT_SYMBOL.
      Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
      Acked-by: default avatarVineet Gupta <vgupta@synoipsys.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      be2a7fce
    • Michal Simek's avatar
      include/linux/kconfig.h: ese macros which are already defined · 02d699f1
      Michal Simek authored
      It is better to use macros which are already available because then there
      is just one location which needs to be change.
      
      [akpm@linux-foundation.org: move IS_ENABLED definition to after the IS_BUILTIN and IS_MODULE definitions]
      Signed-off-by: default avatarMichal Simek <michal.simek@xilinx.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      02d699f1
    • Dan Carpenter's avatar
      memstick: mspro_block: add missing curly braces · 13f6b191
      Dan Carpenter authored
      Using the indenting we can see the curly braces were obviously intended.
      This is a static checker fix, but my guess is that we don't read enough
      bytes, because we don't calculate "t_len" correctly.
      
      Fixes: f1d82698 ('memstick: use fully asynchronous request processing')
      Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Cc: Alex Dubov <oakad@yahoo.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      13f6b191
    • Sanidhya Kashyap's avatar
      bfs: correct return values · c3fe5872
      Sanidhya Kashyap authored
      In case of failed memory allocation, the return should be ENOMEM instead
      of ENOSPC.
      
      Return -EIO when sb_bread() fails.
      Signed-off-by: default avatarSanidhya Kashyap <sanidhya.gatech@gmail.com>
      Cc: Tigran Aivazian <tigran@aivazian.fsnet.co.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      c3fe5872
    • Jiri Slaby's avatar
      bfs: bfad_worker cleanup · 8f7d3f0f
      Jiri Slaby authored
      This kthread is not loop at all due to break at the end of the loop.  Make
      that function linear, with no while loop.
      
      And remove an unnecessary cast.
      Signed-off-by: default avatarJiri Slaby <jslaby@suse.cz>
      Cc: Anil Gurumurthy <anil.gurumurthy@qlogic.com>
      Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      8f7d3f0f