1. 18 Oct, 2016 9 commits
  2. 17 Oct, 2016 7 commits
  3. 16 Oct, 2016 7 commits
    • Dave Airlie's avatar
      Merge branch 'drm-next-4.9' of git://people.freedesktop.org/~agd5f/linux into drm-next · bc91657e
      Dave Airlie authored
      Fixes for radeon and amdgpu for 4.9:
      - allow an additional reg in the SI reg checker
      - fix thermal sensor readback on CZ/ST
      - misc bug fixes
      
      * 'drm-next-4.9' of git://people.freedesktop.org/~agd5f/linux: (21 commits)
        drm/amd/powerplay: fix bug stop dpm can't work on Vi.
        drm/amd/powerplay: notify smu no display by default.
        drm/amdgpu/dpm: implement thermal sensor for CZ/ST
        drm/amdgpu/powerplay: implement thermal sensor for CZ/ST
        drm/amdgpu: disable smu hw first on tear down
        drm/amdgpu: fix amdgpu_need_full_reset (v2)
        drm/amdgpu/si_dpm: Limit clocks on HD86xx part
        drm/amd/powerplay: fix static checker warnings in smu7_hwmgr.c
        drm/amdgpu: potential NULL dereference in debugfs code
        drm/amd/powerplay: fix static checker warnings in smu7_hwmgr.c
        drm/amd/powerplay: fix static checker warnings in iceland_smc.c
        drm/radeon: change vblank_time's calculation method to reduce computational error.
        drm/amdgpu: change vblank_time's calculation method to reduce computational error.
        drm/amdgpu: clarify UVD/VCE special handling for CG
        drm/amd/amdgpu: enable clockgating only after late init
        drm/radeon: allow TA_CS_BC_BASE_ADDR on SI
        drm/amdgpu: initialize the context reset_counter in amdgpu_ctx_init
        drm/amdgpu/gfx8: fix CGCG_CGLS handling
        drm/radeon: fix modeset tear down code
        drm/radeon: fix up dp aux tear down (v2)
        ...
      bc91657e
    • Dan Carpenter's avatar
      perf/x86/intel: Remove an inconsistent NULL check · 5c38181c
      Dan Carpenter authored
      Smatch complains that we don't check "event->ctx" consistently.  It's
      never NULL so we can just remove the check.
      Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: David Carrillo-Cisneros <davidcc@google.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Kan Liang <kan.liang@intel.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Vince Weaver <vincent.weaver@maine.edu>
      Cc: kernel-janitors@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      5c38181c
    • Joonas Lahtinen's avatar
      cpu/hotplug: Use distinct name for cpu_hotplug.dep_map · a705e07b
      Joonas Lahtinen authored
      Use distinctive name for cpu_hotplug.dep_map to avoid the actual
      cpu_hotplug.lock appearing as cpu_hotplug.lock#2 in lockdep splats.
      Signed-off-by: default avatarJoonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Acked-by: default avatarGautham R. Shenoy <ego@linux.vnet.ibm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Cc: Gautham R . Shenoy <ego@linux.vnet.ibm.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: intel-gfx@lists.freedesktop.org
      Cc: trivial@kernel.org
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      a705e07b
    • Dmitry Vyukov's avatar
      kprobes: Unpoison stack in jprobe_return() for KASAN · 9f7d416c
      Dmitry Vyukov authored
      I observed false KSAN positives in the sctp code, when
      sctp uses jprobe_return() in jsctp_sf_eat_sack().
      
      The stray 0xf4 in shadow memory are stack redzones:
      
      [     ] ==================================================================
      [     ] BUG: KASAN: stack-out-of-bounds in memcmp+0xe9/0x150 at addr ffff88005e48f480
      [     ] Read of size 1 by task syz-executor/18535
      [     ] page:ffffea00017923c0 count:0 mapcount:0 mapping:          (null) index:0x0
      [     ] flags: 0x1fffc0000000000()
      [     ] page dumped because: kasan: bad access detected
      [     ] CPU: 1 PID: 18535 Comm: syz-executor Not tainted 4.8.0+ #28
      [     ] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
      [     ]  ffff88005e48f2d0 ffffffff82d2b849 ffffffff0bc91e90 fffffbfff10971e8
      [     ]  ffffed000bc91e90 ffffed000bc91e90 0000000000000001 0000000000000000
      [     ]  ffff88005e48f480 ffff88005e48f350 ffffffff817d3169 ffff88005e48f370
      [     ] Call Trace:
      [     ]  [<ffffffff82d2b849>] dump_stack+0x12e/0x185
      [     ]  [<ffffffff817d3169>] kasan_report+0x489/0x4b0
      [     ]  [<ffffffff817d31a9>] __asan_report_load1_noabort+0x19/0x20
      [     ]  [<ffffffff82d49529>] memcmp+0xe9/0x150
      [     ]  [<ffffffff82df7486>] depot_save_stack+0x176/0x5c0
      [     ]  [<ffffffff817d2031>] save_stack+0xb1/0xd0
      [     ]  [<ffffffff817d27f2>] kasan_slab_free+0x72/0xc0
      [     ]  [<ffffffff817d05b8>] kfree+0xc8/0x2a0
      [     ]  [<ffffffff85b03f19>] skb_free_head+0x79/0xb0
      [     ]  [<ffffffff85b0900a>] skb_release_data+0x37a/0x420
      [     ]  [<ffffffff85b090ff>] skb_release_all+0x4f/0x60
      [     ]  [<ffffffff85b11348>] consume_skb+0x138/0x370
      [     ]  [<ffffffff8676ad7b>] sctp_chunk_put+0xcb/0x180
      [     ]  [<ffffffff8676ae88>] sctp_chunk_free+0x58/0x70
      [     ]  [<ffffffff8677fa5f>] sctp_inq_pop+0x68f/0xef0
      [     ]  [<ffffffff8675ee36>] sctp_assoc_bh_rcv+0xd6/0x4b0
      [     ]  [<ffffffff8677f2c1>] sctp_inq_push+0x131/0x190
      [     ]  [<ffffffff867bad69>] sctp_backlog_rcv+0xe9/0xa20
      [ ... ]
      [     ] Memory state around the buggy address:
      [     ]  ffff88005e48f380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      [     ]  ffff88005e48f400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      [     ] >ffff88005e48f480: f4 f4 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      [     ]                    ^
      [     ]  ffff88005e48f500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      [     ]  ffff88005e48f580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
      [     ] ==================================================================
      
      KASAN stack instrumentation poisons stack redzones on function entry
      and unpoisons them on function exit. If a function exits abnormally
      (e.g. with a longjmp like jprobe_return()), stack redzones are left
      poisoned. Later this leads to random KASAN false reports.
      
      Unpoison stack redzones in the frames we are going to jump over
      before doing actual longjmp in jprobe_return().
      Signed-off-by: default avatarDmitry Vyukov <dvyukov@google.com>
      Acked-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
      Reviewed-by: default avatarMark Rutland <mark.rutland@arm.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Alexander Potapenko <glider@google.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com>
      Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Masami Hiramatsu <mhiramat@kernel.org>
      Cc: kasan-dev@googlegroups.com
      Cc: surovegin@google.com
      Cc: rostedt@goodmis.org
      Link: http://lkml.kernel.org/r/1476454043-101898-1-git-send-email-dvyukov@google.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
      9f7d416c
    • Dmitry Vyukov's avatar
      kprobes: Avoid false KASAN reports during stack copy · 9254139a
      Dmitry Vyukov authored
      Kprobes save and restore raw stack chunks with memcpy().
      With KASAN these chunks can contain poisoned stack redzones,
      as the result memcpy() interceptor produces false
      stack out-of-bounds reports.
      
      Use __memcpy() instead of memcpy() for stack copying.
      __memcpy() is not instrumented by KASAN and does not lead
      to the false reports.
      
      Currently there is a spew of KASAN reports during boot
      if CONFIG_KPROBES_SANITY_TEST is enabled:
      
      [   ] Kprobe smoke test: started
      [   ] ==================================================================
      [   ] BUG: KASAN: stack-out-of-bounds in setjmp_pre_handler+0x17c/0x280 at addr ffff88085259fba8
      [   ] Read of size 64 by task swapper/0/1
      [   ] page:ffffea00214967c0 count:0 mapcount:0 mapping:          (null) index:0x0
      [   ] flags: 0x2fffff80000000()
      [   ] page dumped because: kasan: bad access detected
      [...]
      Reported-by: default avatarCAI Qian <caiqian@redhat.com>
      Tested-by: default avatarCAI Qian <caiqian@redhat.com>
      Signed-off-by: default avatarDmitry Vyukov <dvyukov@google.com>
      Acked-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
      Cc: Alexander Potapenko <glider@google.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com>
      Cc: Andy Lutomirski <luto@kernel.org>
      Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Brian Gerst <brgerst@gmail.com>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Denys Vlasenko <dvlasenk@redhat.com>
      Cc: H. Peter Anvin <hpa@zytor.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Josh Poimboeuf <jpoimboe@redhat.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: kasan-dev@googlegroups.com
      [ Improved various details. ]
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      9254139a
    • Josh Poimboeuf's avatar
      objtool: Skip all "unreachable instruction" warnings for gcov kernels · 9cfffb11
      Josh Poimboeuf authored
      Recently objtool has started reporting a few "unreachable instruction"
      warnings when CONFIG_GCOV is enabled for newer versions of GCC.  Usually
      this warning means there's some new control flow that objtool doesn't
      understand.  But in this case, objtool is correct and the instructions
      really are inaccessible.  It's an annoying quirk of gcov, but it's
      harmless, so it's ok to just silence the warnings.
      
      With older versions of GCC, it was relatively easy to detect
      gcov-specific instructions and to skip any unreachable warnings produced
      by them.  But GCC 6 has gotten craftier.
      
      Instead of continuing to play whack-a-mole with gcov, just use a bigger,
      more permanent hammer and disable unreachable warnings for the whole
      file when gcov is enabled.  This is fine to do because a) unreachable
      warnings are usually of questionable value; and b) gcov isn't used for
      production kernels and we can relax the checks a bit there.
      Reported-by: default avatarkbuild test robot <fengguang.wu@intel.com>
      Signed-off-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      Cc: Andy Lutomirski <luto@kernel.org>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Brian Gerst <brgerst@gmail.com>
      Cc: Denys Vlasenko <dvlasenk@redhat.com>
      Cc: H. Peter Anvin <hpa@zytor.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Link: http://lkml.kernel.org/r/38d5c87d61d9cd46486dd2c86f46603dff0df86f.1476393584.git.jpoimboe@redhat.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
      9cfffb11
    • Josh Poimboeuf's avatar
      objtool: Improve rare switch jump table pattern detection · 3732710f
      Josh Poimboeuf authored
      GCC 6 added a new switch statement jump table optimization which makes
      objtool's life harder.  It looks like:
      
        mov [rodata addr],%reg1
        ... some instructions ...
        jmpq *(%reg1,%reg2,8)
      
      The optimization is quite rare, but objtool still needs to be able to
      identify the pattern so that it can follow all possible control flow
      paths related to the switch statement.
      
      In order to detect the pattern, objtool starts from the indirect jump
      and scans backwards through the function until it finds the first
      instruction in the pattern.  If it encounters an unconditional jump
      along the way, it stops and considers the pattern to be not found.
      
      As it turns out, unconditional jumps can happen, as long as they are
      small forward jumps within the range being scanned.
      
      This fixes the following warnings:
      
        drivers/infiniband/sw/rxe/rxe_comp.o: warning: objtool: rxe_completer()+0x2f4: sibling call from callable instruction with changed frame pointer
        drivers/infiniband/sw/rxe/rxe_resp.o: warning: objtool: rxe_responder()+0x10f: sibling call from callable instruction with changed frame pointer
      Reported-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      Cc: Andy Lutomirski <luto@kernel.org>
      Cc: Borislav Petkov <bp@alien8.de>
      Cc: Brian Gerst <brgerst@gmail.com>
      Cc: Denys Vlasenko <dvlasenk@redhat.com>
      Cc: H. Peter Anvin <hpa@zytor.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Link: http://lkml.kernel.org/r/8a9ed68ae1780e8d3963e4ee13f2f257fe3a3c33.1476393584.git.jpoimboe@redhat.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
      3732710f
  4. 15 Oct, 2016 15 commits
    • Linus Torvalds's avatar
      Linux 4.9-rc1 · 1001354c
      Linus Torvalds authored
      1001354c
    • Linus Torvalds's avatar
      Merge tag 'befs-v4.9-rc1' of git://github.com/luisbg/linux-befs · df34d04a
      Linus Torvalds authored
      Pull befs fixes from Luis de Bethencourt:
       "I recently took maintainership of the befs file system [0]. This is
        the first time I send you a git pull request, so please let me know if
        all the below is OK.
      
        Salah Triki and myself have been cleaning the code and fixing a few
        small bugs.
      
        Sorry I couldn't send this sooner in the merge window, I was waiting
        to have my GPG key signed by kernel members at ELCE in Berlin a few
        days ago."
      
      [0] https://lkml.org/lkml/2016/7/27/502
      
      * tag 'befs-v4.9-rc1' of git://github.com/luisbg/linux-befs: (39 commits)
        befs: befs: fix style issues in datastream.c
        befs: improve documentation in datastream.c
        befs: fix typos in datastream.c
        befs: fix typos in btree.c
        befs: fix style issues in super.c
        befs: fix comment style
        befs: add check for ag_shift in superblock
        befs: dump inode_size superblock information
        befs: remove unnecessary initialization
        befs: fix typo in befs_sb_info
        befs: add flags field to validate superblock state
        befs: fix typo in befs_find_key
        befs: remove unused BEFS_BT_PARMATCH
        fs: befs: remove ret variable
        fs: befs: remove in vain variable assignment
        fs: befs: remove unnecessary *befs_sb variable
        fs: befs: remove useless initialization to zero
        fs: befs: remove in vain variable assignment
        fs: befs: Insert NULL inode to dentry
        fs: befs: Remove useless calls to brelse in befs_find_brun_dblindirect
        ...
      df34d04a
    • Linus Torvalds's avatar
      Merge tag 'gcc-plugins-v4.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux · 9ffc6694
      Linus Torvalds authored
      Pull gcc plugins update from Kees Cook:
       "This adds a new gcc plugin named "latent_entropy". It is designed to
        extract as much possible uncertainty from a running system at boot
        time as possible, hoping to capitalize on any possible variation in
        CPU operation (due to runtime data differences, hardware differences,
        SMP ordering, thermal timing variation, cache behavior, etc).
      
        At the very least, this plugin is a much more comprehensive example
        for how to manipulate kernel code using the gcc plugin internals"
      
      * tag 'gcc-plugins-v4.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux:
        latent_entropy: Mark functions with __latent_entropy
        gcc-plugins: Add latent_entropy plugin
      9ffc6694
    • Linus Torvalds's avatar
      Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus · 133d970e
      Linus Torvalds authored
      Pull MIPS updates from Ralf Baechle:
       "This is the main MIPS pull request for 4.9:
      
        MIPS core arch code:
         - traps: 64bit kernels should read CP0_EBase 64bit
         - traps: Convert ebase to KSEG0
         - c-r4k: Drop bc_wback_inv() from icache flush
         - c-r4k: Split user/kernel flush_icache_range()
         - cacheflush: Use __flush_icache_user_range()
         - uprobes: Flush icache via kernel address
         - KVM: Use __local_flush_icache_user_range()
         - c-r4k: Fix flush_icache_range() for EVA
         - Fix -mabi=64 build of vdso.lds
         - VDSO: Drop duplicated -I*/-E* aflags
         - tracing: move insn_has_delay_slot to a shared header
         - tracing: disable uprobe/kprobe on compact branch instructions
         - ptrace: Fix regs_return_value for kernel context
         - Squash lines for simple wrapper functions
         - Move identification of VP(E) into proc.c from smp-mt.c
         - Add definitions of SYNC barrierstype values
         - traps: Ensure full EBase is written
         - tlb-r4k: If there are wired entries, don't use TLBINVF
         - Sanitise coherentio semantics
         - dma-default: Don't check hw_coherentio if device is non-coherent
         - Support per-device DMA coherence
         - Adjust MIPS64 CAC_BASE to reflect Config.K0
         - Support generating Flattened Image Trees (.itb)
         - generic: Introduce generic DT-based board support
         - generic: Convert SEAD-3 to a generic board
         - Enable hardened usercopy
         - Don't specify STACKPROTECTOR in defconfigs
      
        Octeon:
         - Delete dead code and files across the platform.
         - Change to use all memory into use by default.
         - Rename upper case variables in setup code to lowercase.
         - Delete legacy hack for broken bootloaders.
         - Leave maintaining the link state to the actual ethernet/PHY drivers.
         - Add DTS for D-Link DSR-500N.
         - Fix PCI interrupt routing on D-Link DSR-500N.
      
        Pistachio:
         - Remove ANDROID_TIMED_OUTPUT from defconfig
      
        TX39xx:
         - Move GPIO setup from .mem_setup() to .arch_init()
         - Convert to Common Clock Framework
      
        TX49xx:
         - Move GPIO setup from .mem_setup() to .arch_init()
         - Convert to Common Clock Framework
      
        txx9wdt:
         - Add missing clock (un)prepare calls for CCF
      
        BMIPS:
         - Add PW, GPIO SDHCI and NAND device node names
         - Support APPENDED_DTB
         - Add missing bcm97435svmb to DT_NONE
         - Rename bcm96358nb4ser to bcm6358-neufbox4-sercom
         - Add DT examples for BCM63268, BCM3368 and BCM6362
         - Add support for BCM3368 and BCM6362
      
        PCI
         - Reduce stack frame usage
         - Use struct list_head lists
         - Support for CONFIG_PCI_DOMAINS_GENERIC
         - Make pcibios_set_cache_line_size an initcall
         - Inline pcibios_assign_all_busses
         - Split pci.c into pci.c & pci-legacy.c
         - Introduce CONFIG_PCI_DRIVERS_LEGACY
         - Support generic drivers
      
        CPC
         - Convert bare 'unsigned' to 'unsigned int'
         - Avoid lock when MIPS CM >= 3 is present
      
        GIC:
         - Delete unused file smp-gic.c
      
        mt7620:
         - Delete unnecessary assignment for the field "owner" from PCI
      
        BCM63xx:
         - Let clk_disable() return immediately if clk is NULL
      
        pm-cps:
         - Change FSB workaround to CPU blacklist
         - Update comments on barrier instructions
         - Use MIPS standard lightweight ordering barrier
         - Use MIPS standard completion barrier
         - Remove selection of sync types
         - Add MIPSr6 CPU support
         - Support CM3 changes to Coherence Enable Register
      
        SMP:
         - Wrap call to mips_cpc_lock_other in mips_cm_lock_other
         - Introduce mechanism for freeing and allocating IPIs
      
        cpuidle:
         - cpuidle-cps: Enable use with MIPSr6 CPUs.
      
        SEAD3:
         - Rewrite to use DT and generic kernel feature.
      
        USB:
         - host: ehci-sead3: Remove SEAD-3 EHCI code
      
        FBDEV:
         - cobalt_lcdfb: Drop SEAD3 support
      
        dt-bindings:
         -  Document a binding for simple ASCII LCDs
      
        auxdisplay:
         - img-ascii-lcd: driver for simple ASCII LCD displays
      
        irqchip i8259:
         - i8259: Add domain before mapping parent irq
         - i8259: Allow platforms to override poll function
         - i8259: Remove unused i8259A_irq_pending
      
        Malta:
         - Rewrite to use DT
      
        of/platform:
         - Probe "isa" busses by default
      
        CM:
         - Print CM error reports upon bus errors
      
        Module:
         - Migrate exception table users off module.h and onto extable.h
         - Make various drivers explicitly non-modular:
         - Audit and remove any unnecessary uses of module.h
      
        mailmap:
         - Canonicalize to Qais' current email address.
      
        Documentation:
         - MIPS supports HAVE_REGS_AND_STACK_ACCESS_API
      
        Loongson1C:
         - Add CPU support for Loongson1C
         - Add board support
         - Add defconfig
         - Add RTC support for Loongson1C board
      
        All this except one Documentation fix has sat in linux-next and has
        survived Imagination's automated build test system"
      
      * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (127 commits)
        Documentation: MIPS supports HAVE_REGS_AND_STACK_ACCESS_API
        MIPS: ptrace: Fix regs_return_value for kernel context
        MIPS: VDSO: Drop duplicated -I*/-E* aflags
        MIPS: Fix -mabi=64 build of vdso.lds
        MIPS: Enable hardened usercopy
        MIPS: generic: Convert SEAD-3 to a generic board
        MIPS: generic: Introduce generic DT-based board support
        MIPS: Support generating Flattened Image Trees (.itb)
        MIPS: Adjust MIPS64 CAC_BASE to reflect Config.K0
        MIPS: Print CM error reports upon bus errors
        MIPS: Support per-device DMA coherence
        MIPS: dma-default: Don't check hw_coherentio if device is non-coherent
        MIPS: Sanitise coherentio semantics
        MIPS: PCI: Support generic drivers
        MIPS: PCI: Introduce CONFIG_PCI_DRIVERS_LEGACY
        MIPS: PCI: Split pci.c into pci.c & pci-legacy.c
        MIPS: PCI: Inline pcibios_assign_all_busses
        MIPS: PCI: Make pcibios_set_cache_line_size an initcall
        MIPS: PCI: Support for CONFIG_PCI_DOMAINS_GENERIC
        MIPS: PCI: Use struct list_head lists
        ...
      133d970e
    • Linus Torvalds's avatar
      Merge tag 'sound-fix-4.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound · 050aaeab
      Linus Torvalds authored
      Pull sound fixes from Takashi Iwai:
       "Just a few trivial small fixes"
      
      * tag 'sound-fix-4.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
        ALSA: line6: fix a crash in line6_hwdep_write()
        ALSA: seq: fix passing wrong pointer in function call of compatibility layer
        ALSA: hda - Fix a failure of micmute led when having multi adcs
        ALSA: line6: Fix POD X3 Live audio input
      050aaeab
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · b26b5ef5
      Linus Torvalds authored
      Pull more misc uaccess and vfs updates from Al Viro:
       "The rest of the stuff from -next (more uaccess work) + assorted fixes"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        score: traps: Add missing include file to fix build error
        fs/super.c: don't fool lockdep in freeze_super() and thaw_super() paths
        fs/super.c: fix race between freeze_super() and thaw_super()
        overlayfs: Fix setting IOP_XATTR flag
        iov_iter: kernel-doc import_iovec() and rw_copy_check_uvector()
        blackfin: no access_ok() for __copy_{to,from}_user()
        arm64: don't zero in __copy_from_user{,_inatomic}
        arm: don't zero in __copy_from_user_inatomic()/__copy_from_user()
        arc: don't leak bits of kernel stack into coredump
        alpha: get rid of tail-zeroing in __copy_user()
      b26b5ef5
    • Linus Torvalds's avatar
      Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6 · 87dbe42a
      Linus Torvalds authored
      Pull cifs fixes from Steve French:
       "Including:
      
         - nine bug fixes for stable. Some of these we found at the recent two
           weeks of SMB3 test events/plugfests.
      
         - significant improvements in reconnection (e.g. if server or network
           crashes) especially when mounted with "persistenthandles" or to
           server which advertises Continuous Availability on the share.
      
         - a new mount option "idsfromsid" which improves POSIX compatibility
           in some cases (when winbind not configured e.g.) by better (and
           faster) fetching uid/gid from acl (when "cifsacl" mount option is
           enabled). NB: we are almost complete work on "cifsacl" (querying
           mode/uid/gid from ACL) for SMB3, but SMB3 support for cifsacl is
           not included in this set.
      
         - improved handling for SMB3 "credits" (even if server is buggy)
      
        Still working on two sets of changes:
      
         - cifsacl enablement for SMB3
      
         - cleanup of RFC1001 length calculation (so we can handle encryption
           and multichannel and RDMA)
      
        And a couple of new bugs were reported recently (unrelated to above)
        so will probably have another merge request next week"
      
      * 'for-next' of git://git.samba.org/sfrench/cifs-2.6: (21 commits)
        CIFS: Retrieve uid and gid from special sid if enabled
        CIFS: Add new mount option to set owner uid and gid from special sids in acl
        CIFS: Reset read oplock to NONE if we have mandatory locks after reopen
        CIFS: Fix persistent handles re-opening on reconnect
        SMB2: Separate RawNTLMSSP authentication from SMB2_sess_setup
        SMB2: Separate Kerberos authentication from SMB2_sess_setup
        Expose cifs module parameters in sysfs
        Cleanup missing frees on some ioctls
        Enable previous version support
        Do not send SMB3 SET_INFO request if nothing is changing
        SMB3: Add mount parameter to allow user to override max credits
        fs/cifs: reopen persistent handles on reconnect
        Clarify locking of cifs file and tcon structures and make more granular
        Fix regression which breaks DFS mounting
        fs/cifs: keep guid when assigning fid to fileinfo
        SMB3: GUIDs should be constructed as random but valid uuids
        Set previous session id correctly on SMB3 reconnect
        cifs: Limit the overall credit acquired
        Display number of credits available
        Add way to query creation time of file via cifs xattr
        ...
      87dbe42a
    • Linus Torvalds's avatar
      Merge branch 'for-linus-4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · d3304cad
      Linus Torvalds authored
      Pull btrfs fixes from Chris Mason:
       "Some fixes from Omar and Dave Sterba for our new free space tree.
      
        This isn't heavily used yet, but as we move toward making it the new
        default we wanted to nail down an endian bug"
      
      * 'for-linus-4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        btrfs: tests: uninline member definitions in free_space_extent
        btrfs: tests: constify free space extent specs
        Btrfs: expand free space tree sanity tests to catch endianness bug
        Btrfs: fix extent buffer bitmap tests on big-endian systems
        Btrfs: catch invalid free space trees
        Btrfs: fix mount -o clear_cache,space_cache=v2
        Btrfs: fix free space tree bitmaps on big-endian systems
      d3304cad
    • Al Viro's avatar
      Merge branch 'work.uaccess' into for-linus · 2692a71b
      Al Viro authored
      2692a71b
    • Guenter Roeck's avatar
      score: traps: Add missing include file to fix build error · 7041c577
      Guenter Roeck authored
      score images fail to build as follows.
      
      arch/score/kernel/traps.c: In function 'show_stack':
      arch/score/kernel/traps.c:55:3: error:
      	implicit declaration of function '__get_user'
      
      __get_user() is declared in asm/uaccess.h, which was previously included
      through asm/module.h.
      
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Fixes: 88dd4a74 ("score: separate extable.h, switch module.h to it")
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      7041c577
    • Oleg Nesterov's avatar
      fs/super.c: don't fool lockdep in freeze_super() and thaw_super() paths · f1a96220
      Oleg Nesterov authored
      sb_wait_write()->percpu_rwsem_release() fools lockdep to avoid the
      false-positives. Now that xfs was fixed by Dave's commit dbad7c99
      ("xfs: stop holding ILOCK over filldir callbacks") we can remove it and
      change freeze_super() and thaw_super() to run with s_writers.rw_sem locks
      held; we add two trivial helpers for that, lockdep_sb_freeze_release()
      and lockdep_sb_freeze_acquire().
      
      xfstests-dev/check `grep -il freeze tests/*/???` does not trigger any
      warning from lockdep.
      Signed-off-by: default avatarOleg Nesterov <oleg@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      f1a96220
    • Linus Torvalds's avatar
      Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs · 1a892b48
      Linus Torvalds authored
      Pull overlayfs updates from Miklos Szeredi:
       "This update contains fixes to the "use mounter's permission to access
        underlying layers" area, and miscellaneous other fixes and cleanups.
      
        No new features this time"
      
      * 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs:
        ovl: use vfs_get_link()
        vfs: add vfs_get_link() helper
        ovl: use generic_readlink
        ovl: explain error values when removing acl from workdir
        ovl: Fix info leak in ovl_lookup_temp()
        ovl: during copy up, switch to mounter's creds early
        ovl: lookup: do getxattr with mounter's permission
        ovl: copy_up_xattr(): use strnlen
      1a892b48
    • Oleg Nesterov's avatar
      fs/super.c: fix race between freeze_super() and thaw_super() · 89f39af1
      Oleg Nesterov authored
      Change thaw_super() to check frozen != SB_FREEZE_COMPLETE rather than
      frozen == SB_UNFROZEN, otherwise it can race with freeze_super() which
      drops sb->s_umount after SB_FREEZE_WRITE to preserve the lock ordering.
      
      In this case thaw_super() will wrongly call s_op->unfreeze_fs() before
      it was actually frozen, and call sb_freeze_unlock() which leads to the
      unbalanced percpu_up_write(). Unfortunately lockdep can't detect this,
      so this triggers misc BUG_ON()'s in kernel/rcu/sync.c.
      Reported-and-tested-by: default avatarNikolay Borisov <kernel@kyup.com>
      Signed-off-by: default avatarOleg Nesterov <oleg@redhat.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      89f39af1
    • Vivek Goyal's avatar
      overlayfs: Fix setting IOP_XATTR flag · 655042cc
      Vivek Goyal authored
      ovl_fill_super calls ovl_new_inode to create a root inode for the new
      superblock before initializing sb->s_xattr.  This wrongly causes
      IOP_XATTR to be cleared in i_opflags of the new inode, causing SELinux
      to log the following message:
      
        SELinux: (dev overlay, type overlay) has no xattr support
      
      Fix this by initializing sb->s_xattr and similar fields before calling
      ovl_new_inode.
      Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      655042cc
    • Vegard Nossum's avatar
      iov_iter: kernel-doc import_iovec() and rw_copy_check_uvector() · ffecee4f
      Vegard Nossum authored
      Both import_iovec() and rw_copy_check_uvector() take an array
      (typically small and on-stack) which is used to hold an iovec array copy
      from userspace. This is to avoid an expensive memory allocation in the
      fast path (i.e. few iovec elements).
      
      The caller may have to check whether these functions actually used
      the provided buffer or allocated a new one -- but this differs between
      the too. Let's just add a kernel doc to clarify what the semantics are
      for each function.
      Signed-off-by: default avatarVegard Nossum <vegard.nossum@oracle.com>
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      ffecee4f
  5. 14 Oct, 2016 2 commits
    • Linus Torvalds's avatar
      Merge tag 'linux-kselftest-4.9-rc1-update' of... · 5d89d9f5
      Linus Torvalds authored
      Merge tag 'linux-kselftest-4.9-rc1-update' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest
      
      Pull kselftest updates from Shuah Khan:
       "This update consists of:
      
         - Fixes and improvements to existing tests
      
         - Moving code from Documentation to selftests, samples, and tools:
      
           * Moves dnotify_test, prctl, ptp, vDSO, ia64, watchdog, and
             networking tests from Documentation to selftests.
      
           * Moves mic/mpssd, misc-devices/mei, timers, watchdog, auxdisplay,
             and blackfin examples from Documentation to samples.
      
           * Moves accounting, laptops/dslm, and pcmcia/crc32hash tools from
             Documentation to tools.
      
           * Deletes BUILD_DOCSRC and its dependencies"
      
      * tag 'linux-kselftest-4.9-rc1-update' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest: (21 commits)
        selftests/futex: Check ANSI terminal color support
        Doc: update 00-INDEX files to reflect the runnable code move
        samples: move blackfin gptimers-example from Documentation
        tools: move pcmcia crc32hash tool from Documentation
        tools: move laptops dslm tool from Documentation
        tools: move accounting tool from Documentation
        samples: move auxdisplay example code from Documentation
        samples: move watchdog example code from Documentation
        samples: move timers example code from Documentation
        samples: move misc-devices/mei example code from Documentation
        samples: move mic/mpssd example code from Documentation
        selftests: Move networking/timestamping from Documentation
        selftests: move watchdog tests from Documentation/watchdog
        selftests: move ia64 tests from Documentation/ia64
        selftests: move vDSO tests from Documentation/vDSO
        selftests: move ptp tests from Documentation/ptp
        selftests: move prctl tests from Documentation/prctl
        selftests: move dnotify_test from Documentation/filesystems
        selftests/timers: Add missing error code assignment before test
        selftests/zram: replace ZRAM_LZ4_COMPRESS
        ...
      5d89d9f5
    • Linus Torvalds's avatar
      Merge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild · 50cff898
      Linus Torvalds authored
      Pull misc kbuild changes from Michal Marek:
       "Just a few patches on the kbuild.git#misc branch this time:
      
         - New Coccinelle patch by Nicholas Mc Guire
         - Existing patch fixes by Julia Lawall
         - Minor comment fix by Markus Elfring"
      
      * 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
        Coccinelle: flag conditions with no effect
        scripts/coccicheck: Update reference for the corresponding documentation
        Coccinelle: pm_runtime: ensure relevance of pm_runtime reports
        Coccinelle: limit memdup_user transformation to GFP_KERNEL case
      50cff898