Skip to content
  1. Jun 23, 2015
    • Linus Torvalds's avatar
      Merge branch 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 1bf7067c
      Linus Torvalds authored
      Pull locking updates from Ingo Molnar:
       "The main changes are:
      
         - 'qspinlock' support, enabled on x86: queued spinlocks - these are
           now the spinlock variant used by x86 as they outperform ticket
           spinlocks in every category.  (Waiman Long)
      
         - 'pvqspinlock' support on x86: paravirtualized variant of queued
           spinlocks.  (Waiman Long, Peter Zijlstra)
      
         - 'qrwlock' support, enabled on x86: queued rwlocks.  Similar to
           queued spinlocks, they are now the variant used by x86:
      
             CONFIG_ARCH_USE_QUEUED_SPINLOCKS=y
             CONFIG_QUEUED_SPINLOCKS=y
             CONFIG_ARCH_USE_QUEUED_RWLOCKS=y
             CONFIG_QUEUED_RWLOCKS=y
      
         - various lockdep fixlets
      
         - various locking primitives cleanups, further WRITE_ONCE()
           propagation"
      
      * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (24 commits)
        locking/lockdep: Remove hard coded array size dependency
        locking/qrwlock: Don't contend with readers when setting _QW_WAITING
        lockdep: Do not break user-visible string
        locking/arch: Rename set_mb() to smp_store_mb()
        locking/arch: Add WRITE_ONCE() to set_mb()
        rtmutex: Warn if trylock is called from hard/softirq context
        arch: Remove __ARCH_HAVE_CMPXCHG
        locking/rtmutex: Drop usage of __HAVE_ARCH_CMPXCHG
        locking/qrwlock: Rename QUEUE_RWLOCK to QUEUED_RWLOCKS
        locking/pvqspinlock: Rename QUEUED_SPINLOCK to QUEUED_SPINLOCKS
        locking/pvqspinlock: Replace xchg() by the more descriptive set_mb()
        locking/pvqspinlock, x86: Enable PV qspinlock for Xen
        locking/pvqspinlock, x86: Enable PV qspinlock for KVM
        locking/pvqspinlock, x86: Implement the paravirt qspinlock call patching
        locking/pvqspinlock: Implement simple paravirt support for the qspinlock
        locking/qspinlock: Revert to test-and-set on hypervisors
        locking/qspinlock: Use a simple write to grab the lock
        locking/qspinlock: Optimize for smaller NR_CPUS
        locking/qspinlock: Extract out code snippets for the next patch
        locking/qspinlock: Add pending bit
        ...
      1bf7067c
    • Linus Torvalds's avatar
      Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · fc934d40
      Linus Torvalds authored
      Pull RCU updates from Ingo Molnar:
      
       - Continued initialization/Kconfig updates: hide most Kconfig options
         from unsuspecting users.
      
         There's now a single high level configuration option:
      
              *
              * RCU Subsystem
              *
              Make expert-level adjustments to RCU configuration (RCU_EXPERT) [N/y/?] (NEW)
      
         Which if answered in the negative, leaves us with a single
         interactive configuration option:
      
              Offload RCU callback processing from boot-selected CPUs (RCU_NOCB_CPU) [N/y/?] (NEW)
      
         All the rest of the RCU options are configured automatically.  Later
         on we'll remove this single leftover configuration option as well.
      
       - Remove all uses of RCU-protected array indexes: replace the
         rcu_[access|dereference]_index_check() APIs with READ_ONCE() and
         rcu_lockdep_assert()
      
       - RCU CPU-hotplug cleanups
      
       - Updates to Tiny RCU: a race fix and further code shrinkage.
      
       - RCU torture-testing updates: fixes, speedups, cleanups and
         documentation updates.
      
       - Miscellaneous fixes
      
       - Documentation updates
      
      * 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (60 commits)
        rcutorture: Allow repetition factors in Kconfig-fragment lists
        rcutorture: Display "make oldconfig" errors
        rcutorture: Update TREE_RCU-kconfig.txt
        rcutorture: Make rcutorture scripts force RCU_EXPERT
        rcutorture: Update configuration fragments for rcutree.rcu_fanout_exact
        rcutorture: TASKS_RCU set directly, so don't explicitly set it
        rcutorture: Test SRCU cleanup code path
        rcutorture: Replace barriers with smp_store_release() and smp_load_acquire()
        locktorture: Change longdelay_us to longdelay_ms
        rcutorture: Allow negative values of nreaders to oversubscribe
        rcutorture: Exchange TREE03 and TREE08 NR_CPUS, speed up CPU hotplug
        rcutorture: Exchange TREE03 and TREE04 geometries
        locktorture: fix deadlock in 'rw_lock_irq' type
        rcu: Correctly handle non-empty Tiny RCU callback list with none ready
        rcutorture: Test both RCU-sched and RCU-bh for Tiny RCU
        rcu: Further shrink Tiny RCU by making empty functions static inlines
        rcu: Conditionally compile RCU's eqs warnings
        rcu: Remove prompt for RCU implementation
        rcu: Make RCU able to tolerate undefined CONFIG_RCU_KTHREAD_PRIO
        rcu: Make RCU able to tolerate undefined CONFIG_RCU_FANOUT_LEAF
        ...
      fc934d40
    • Linus Torvalds's avatar
      Merge branch 'for-linus-1' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 052b398a
      Linus Torvalds authored
      Pull vfs updates from Al Viro:
       "In this pile: pathname resolution rewrite.
      
         - recursion in link_path_walk() is gone.
      
         - nesting limits on symlinks are gone (the only limit remaining is
           that the total amount of symlinks is no more than 40, no matter how
           nested).
      
         - "fast" (inline) symlinks are handled without leaving rcuwalk mode.
      
         - stack footprint (independent of the nesting) is below kilobyte now,
           about on par with what it used to be with one level of nested
           symlinks and ~2.8 times lower than it used to be in the worst case.
      
         - struct nameidata is entirely private to fs/namei.c now (not even
           opaque pointers are being passed around).
      
         - ->follow_link() and ->put_link() calling conventions had been
           changed; all in-tree filesystems converted, out-of-tree should be
           able to follow reasonably easily.
      
           For out-of-tree conversions, see Documentation/filesystems/porting
           for details (and in-tree filesystems for examples of conversion).
      
        That has sat in -next since mid-May, seems to survive all testing
        without regressions and merges clean with v4.1"
      
      * 'for-linus-1' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (131 commits)
        turn user_{path_at,path,lpath,path_dir}() into static inlines
        namei: move saved_nd pointer into struct nameidata
        inline user_path_create()
        inline user_path_parent()
        namei: trim do_last() arguments
        namei: stash dfd and name into nameidata
        namei: fold path_cleanup() into terminate_walk()
        namei: saner calling conventions for filename_parentat()
        namei: saner calling conventions for filename_create()
        namei: shift nameidata down into filename_parentat()
        namei: make filename_lookup() reject ERR_PTR() passed as name
        namei: shift nameidata inside filename_lookup()
        namei: move putname() call into filename_lookup()
        namei: pass the struct path to store the result down into path_lookupat()
        namei: uninline set_root{,_rcu}()
        namei: be careful with mountpoint crossings in follow_dotdot_rcu()
        Documentation: remove outdated information from automount-support.txt
        get rid of assorted nameidata-related debris
        lustre: kill unused helper
        lustre: kill unused macro (LOOKUP_CONTINUE)
        ...
      052b398a
  2. Jun 22, 2015
  3. Jun 21, 2015
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending · d2228e43
      Linus Torvalds authored
      Pull scsi target fixes from Nicholas Bellinger:
       "Apologies for the late pull request.
      
        Here are the outstanding target-pending fixes for v4.1 code.
      
        The series contains three patches from Sagi + Co that address a few
        iser-target issues that have been uncovered during recent testing at
        Mellanox.
      
        Patch #1 has a v3.16+ stable tag, and #2-3 have v3.10+ stable tags"
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending:
        iser-target: Fix possible use-after-free
        iser-target: release stale iser connections
        iser-target: Fix variable-length response error completion
      d2228e43
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux · 8f4ce072
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "A smattering of fixes,
      
        mgag200:
            don't accept modes that aren't aligned properly as hw can't do it
      
        i915:
            two regression fixes
      
        radeon:
            one query to allow userspace fixes
            one oops fixer for older hw with new options enabled"
      
      * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
        drm/radeon: don't probe MST on hw we don't support it on
        drm/radeon: Add RADEON_INFO_VA_UNMAP_WORKING query
        drm/mgag200: Reject non-character-cell-aligned mode widths
        Revert "drm/i915: Don't skip request retirement if the active list is empty"
        drm/i915: Always reset vma->ggtt_view.pages cache on unbinding
      8f4ce072
  4. Jun 20, 2015
  5. Jun 19, 2015
  6. Jun 18, 2015
  7. Jun 17, 2015
    • Wolfram Sang's avatar
      i2c: slave: fix the example how to instantiate from userspace · 83666102
      Wolfram Sang authored
      
      
      I copied the wrong shell code into the documentation. Sorry to all who
      tried to get sense out of this current example :/ Slight rewording while
      we are here.
      
      Reported-by: default avatarTim Bakker <bakkert@mymail.vcu.edu>
      Signed-off-by: default avatarWolfram Sang <wsa+renesas@sang-engineering.com>
      Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
      Cc: stable@kernel.org
      83666102
    • Steven Rostedt's avatar
      tracing: Have filter check for balanced ops · 2cf30dc1
      Steven Rostedt authored
      When the following filter is used it causes a warning to trigger:
      
       # cd /sys/kernel/debug/tracing
       # echo "((dev==1)blocks==2)" > events/ext4/ext4_truncate_exit/filter
      -bash: echo: write error: Invalid argument
       # cat events/ext4/ext4_truncate_exit/filter
      ((dev==1)blocks==2)
      ^
      parse_error: No error
      
       ------------[ cut here ]------------
       WARNING: CPU: 2 PID: 1223 at kernel/trace/trace_events_filter.c:1640 replace_preds+0x3c5/0x990()
       Modules linked in: bnep lockd grace bluetooth  ...
       CPU: 3 PID: 1223 Comm: bash Tainted: G        W       4.1.0-rc3-test+ #450
       Hardware name: Hewlett-Packard HP Compaq Pro 6300 SFF/339A, BIOS K01 v02.05 05/07/2012
        0000000000000668 ffff8800c106bc98 ffffffff816ed4f9 ffff88011ead0cf0
        0000000000000000 ffff8800c106bcd8 ffffffff8107fb07 ffffffff8136b46c
        ffff8800c7d81d48 ffff8800d4c2bc00 ffff8800d4d4f920 00000000ffffffea
       Call Trace:
        [<ffffffff816ed4f9>] dump_stack+0x4c/0x6e
        [<ffffffff8107fb07>] warn_slowpath_common+0x97/0xe0
        [<ffffffff8136b46c>] ? _kstrtoull+0x2c/0x80
        [<ffffffff8107fb6a>] warn_slowpath_null+0x1a/0x20
        [<ffffffff81159065>] replace_preds+0x3c5/0x990
        [<ffffffff811596b2>] create_filter+0x82/0xb0
        [<ffffffff81159944>] apply_event_filter+0xd4/0x180
        [<ffffffff81152bbf>] event_filter_write+0x8f/0x120
        [<ffffffff811db2a8>] __vfs_write+0x28/0xe0
        [<ffffffff811dda43>] ? __sb_start_write+0x53/0xf0
        [<ffffffff812e51e0>] ? security_file_permission+0x30/0xc0
        [<ffffffff811dc408>] vfs_write+0xb8/0x1b0
        [<ffffffff811dc72f>] SyS_write+0x4f/0xb0
        [<ffffffff816f5217>] system_call_fastpath+0x12/0x6a
       ---[ end trace e11028bd95818dcd ]---
      
      Worse yet, reading the error message (the filter again) it says that
      there was no error, when there clearly was. The issue is that the
      code that checks the input does not check for balanced ops. That is,
      having an op between a closed parenthesis and the next token.
      
      This would only cause a warning, and fail out before doing any real
      harm, but it should still not caues a warning, and the error reported
      should work:
      
       # cd /sys/kernel/debug/tracing
       # echo "((dev==1)blocks==2)" > events/ext4/ext4_truncate_exit/filter
      -bash: echo: write error: Invalid argument
       # cat events/ext4/ext4_truncate_exit/filter
      ((dev==1)blocks==2)
      ^
      parse_error: Meaningless filter expression
      
      And give no kernel warning.
      
      Link: http://lkml.kernel.org/r/20150615175025.7e809215@gandalf.local.home
      
      
      
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: stable@vger.kernel.org # 2.6.31+
      Reported-by: default avatarVince Weaver <vincent.weaver@maine.edu>
      Tested-by: default avatarVince Weaver <vincent.weaver@maine.edu>
      Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
      2cf30dc1
  8. Jun 16, 2015
    • Takashi Iwai's avatar
      ALSA: hda - Fix unused label skip_i915 · 145c0e91
      Takashi Iwai authored
      When CONFIG_SND_HDA_I915=n, we get a compile warning:
        sound/pci/hda/hda_intel.c: In function ‘azx_probe_continue’:
        sound/pci/hda/hda_intel.c:1882:2: warning: label ‘skip_i915’ defined but not used [-Wunused-label]
      
      Fix it by putting again ifdef to it.  Sigh.
      
      Fixes: bf06848b
      
       ('ALSA: hda - Continue probing even if i915 binding fails')
      Reported-by: default avatarBorislav Petkov <bp@suse.de>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      145c0e91
    • Steve Cornelius's avatar
      crypto: caam - fix RNG buffer cache alignment · 412c98c1
      Steve Cornelius authored
      
      
      The hwrng output buffers (2) are cast inside of a a struct (caam_rng_ctx)
      allocated in one DMA-tagged region. While the kernel's heap allocator
      should place the overall struct on a cacheline aligned boundary, the 2
      buffers contained within may not necessarily align. Consenquently, the ends
      of unaligned buffers may not fully flush, and if so, stale data will be left
      behind, resulting in small repeating patterns.
      
      This fix aligns the buffers inside the struct.
      
      Note that not all of the data inside caam_rng_ctx necessarily needs to be
      DMA-tagged, only the buffers themselves require this. However, a fix would
      incur the expense of error-handling bloat in the case of allocation failure.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSteve Cornelius <steve.cornelius@freescale.com>
      Signed-off-by: default avatarVictoria Milhoan <vicki.milhoan@freescale.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      412c98c1
    • Steve Cornelius's avatar
      crypto: caam - improve initalization for context state saves · 6fd4b156
      Steve Cornelius authored
      
      
      Multiple function in asynchronous hashing use a saved-state block,
      a.k.a. struct caam_hash_state, which holds a stash of information
      between requests (init/update/final). Certain values in this state
      block are loaded for processing using an inline-if, and when this
      is done, the potential for uninitialized data can pose conflicts.
      Therefore, this patch improves initialization of state data to
      prevent false assignments using uninitialized data in the state block.
      
      This patch addresses the following traceback, originating in
      ahash_final_ctx(), although a problem like this could certainly
      exhibit other symptoms:
      
      kernel BUG at arch/arm/mm/dma-mapping.c:465!
      Unable to handle kernel NULL pointer dereference at virtual address 00000000
      pgd = 80004000
      [00000000] *pgd=00000000
      Internal error: Oops: 805 [#1] PREEMPT SMP
      Modules linked in:
      CPU: 0    Not tainted  (3.0.15-01752-gdd441b9-dirty #40)
      PC is at __bug+0x1c/0x28
      LR is at __bug+0x18/0x28
      pc : [<80043240>]    lr : [<8004323c>]    psr: 60000013
      sp : e423fd98  ip : 60000013  fp : 0000001c
      r10: e4191b84  r9 : 00000020  r8 : 00000009
      r7 : 88005038  r6 : 00000001  r5 : 2d676572  r4 : e4191a60
      r3 : 00000000  r2 : 00000001  r1 : 60000093  r0 : 00000033
      Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
      Control: 10c53c7d  Table: 1000404a  DAC: 00000015
      Process cryptomgr_test (pid: 1306, stack limit = 0xe423e2f0)
      Stack: (0xe423fd98 to 0xe4240000)
      fd80:                                                       11807fd1 80048544
      fda0: 88005000 e4191a00 e5178040 8039dda0 00000000 00000014 2d676572 e4191008
      fdc0: 88005018 e4191a60 00100100 e4191a00 00000000 8039ce0c e423fea8 00000007
      fde0: e4191a00 e4227000 e5178000 8039ce18 e419183c 80203808 80a94a44 00000006
      fe00: 00000000 80207180 00000000 00000006 e423ff08 00000000 00000007 e5178000
      fe20: e41918a4 80a949b4 8c4844e2 00000000 00000049 74227000 8c4844e2 00000e90
      fe40: 0000000e 74227e90 ffff8c58 80ac29e0 e423fed4 8006a350 8c81625c e423ff5c
      fe60: 00008576 e4002500 00000003 00030010 e4002500 00000003 e5180000 e4002500
      fe80: e5178000 800e6d24 007fffff 00000000 00000010 e4001280 e4002500 60000013
      fea0: 000000d0 804df078 00000000 00000000 00000000 00000000 00000000 00000000
      fec0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
      fee0: 00000000 00000000 e4227000 e4226000 e4753000 e4752000 e40a5000 e40a4000
      ff00: e41e7000 e41e6000 00000000 00000000 00000000 e423ff14 e423ff14 00000000
      ff20: 00000400 804f9080 e5178000 e4db0b40 00000000 e4db0b80 0000047c 00000400
      ff40: 00000000 8020758c 00000400 ffffffff 0000008a 00000000 e4db0b40 80206e00
      ff60: e4049dbc 00000000 00000000 00000003 e423ffa4 80062978 e41a8bfc 00000000
      ff80: 00000000 e4049db4 00000013 e4049db0 00000013 00000000 00000000 00000000
      ffa0: e4db0b40 e4db0b40 80204cbc 00000013 00000000 00000000 00000000 80204cfc
      ffc0: e4049da0 80089544 80040a40 00000000 e4db0b40 00000000 00000000 00000000
      ffe0: e423ffe0 e423ffe0 e4049da0 800894c4 80040a40 80040a40 00000000 00000000
      [<80043240>] (__bug+0x1c/0x28) from [<80048544>] (___dma_single_dev_to_cpu+0x84)
      [<80048544>] (___dma_single_dev_to_cpu+0x84/0x94) from [<8039dda0>] (ahash_fina)
      [<8039dda0>] (ahash_final_ctx+0x180/0x428) from [<8039ce18>] (ahash_final+0xc/0)
      [<8039ce18>] (ahash_final+0xc/0x10) from [<80203808>] (crypto_ahash_op+0x28/0xc)
      [<80203808>] (crypto_ahash_op+0x28/0xc0) from [<80207180>] (test_hash+0x214/0x5)
      [<80207180>] (test_hash+0x214/0x5b8) from [<8020758c>] (alg_test_hash+0x68/0x8c)
      [<8020758c>] (alg_test_hash+0x68/0x8c) from [<80206e00>] (alg_test+0x7c/0x1b8)
      [<80206e00>] (alg_test+0x7c/0x1b8) from [<80204cfc>] (cryptomgr_test+0x40/0x48)
      [<80204cfc>] (cryptomgr_test+0x40/0x48) from [<80089544>] (kthread+0x80/0x88)
      [<80089544>] (kthread+0x80/0x88) from [<80040a40>] (kernel_thread_exit+0x0/0x8)
      Code: e59f0010 e1a01003 eb126a8d e3a03000 (e5833000)
      ---[ end trace d52a403a1d1eaa86 ]---
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSteve Cornelius <steve.cornelius@freescale.com>
      Signed-off-by: default avatarVictoria Milhoan <vicki.milhoan@freescale.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      6fd4b156
    • Radim Krčmář's avatar
      KVM: x86: fix lapic.timer_mode on restore · b6ac0695
      Radim Krčmář authored
      lapic.timer_mode was not properly initialized after migration, which
      broke few useful things, like login, by making every sleep eternal.
      
      Fix this by calling apic_update_lvtt in kvm_apic_post_state_restore.
      
      There are other slowpaths that update lvtt, so this patch makes sure
      something similar doesn't happen again by calling apic_update_lvtt
      after every modification.
      
      Cc: stable@vger.kernel.org
      Fixes: f30ebc31
      
       ("KVM: x86: optimize some accesses to LVTT and SPIV")
      Signed-off-by: default avatarRadim Krčmář <rkrcmar@redhat.com>
      Signed-off-by: default avatarMarcelo Tosatti <mtosatti@redhat.com>
      b6ac0695
    • Adam Jackson's avatar
      drm/mgag200: Reject non-character-cell-aligned mode widths · 25161084
      Adam Jackson authored
      
      
      Turns out 1366x768 does not in fact work on this hardware.
      
      Signed-off-by: default avatarAdam Jackson <ajax@redhat.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      25161084
    • Takashi Iwai's avatar
      ALSA: hda - Fix noisy outputs on Dell XPS13 (2015 model) · 82d6d8a4
      Takashi Iwai authored
      The new Dell XPS13 also requires the similar quirk for fixing the
      noisy outputs.  (But, as the codec was changed, now the fixup for
      Latitude is used instead.)
      
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=99851
      
      
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      82d6d8a4
  9. Jun 15, 2015