1. 22 9月, 2009 12 次提交
    • D
      futex: Fix wakeup race by setting TASK_INTERRUPTIBLE before queue_me() · 0729e196
      Darren Hart 提交于
      PI futexes do not use the same plist_node_empty() test for wakeup.
      It was possible for the waiter (in futex_wait_requeue_pi()) to set
      TASK_INTERRUPTIBLE after the waker assigned the rtmutex to the
      waiter. The waiter would then note the plist was not empty and call
      schedule(). The task would not be found by any subsequeuent futex
      wakeups, resulting in a userspace hang.
      
      By moving the setting of TASK_INTERRUPTIBLE to before the call to
      queue_me(), the race with the waker is eliminated. Since we no
      longer call get_user() from within queue_me(), there is no need to
      delay the setting of TASK_INTERRUPTIBLE until after the call to
      queue_me().
      
      The FUTEX_LOCK_PI operation is not affected as futex_lock_pi()
      relies entirely on the rtmutex code to handle schedule() and
      wakeup.  The requeue PI code is affected because the waiter starts
      as a non-PI waiter and is woken on a PI futex.
      
      Remove the crusty old comment about holding spinlocks() across
      get_user() as we no longer do that. Correct the locking statement
      with a description of why the test is performed.
      Signed-off-by: NDarren Hart <dvhltc@us.ibm.com>
      Acked-by: NPeter Zijlstra <peterz@infradead.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: Dinakar Guniguntala <dino@in.ibm.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      LKML-Reference: <20090922053038.8717.97838.stgit@Aeon>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      0729e196
    • D
      futex: Correct futex_q woken state commentary · d8d88fbb
      Darren Hart 提交于
      Use kernel-doc format to describe struct futex_q.
      
      Correct the wakeup definition to eliminate the statement about
      waking the waiter between the plist_del() and the q->lock_ptr = 0.
      
      Note in the comment that PI futexes have a different definition of
      the woken state.
      Signed-off-by: NDarren Hart <dvhltc@us.ibm.com>
      Acked-by: NPeter Zijlstra <peterz@infradead.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: Dinakar Guniguntala <dino@in.ibm.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      LKML-Reference: <20090922053029.8717.62798.stgit@Aeon>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      d8d88fbb
    • D
      futex: Make function kernel-doc commentary consistent · d96ee56c
      Darren Hart 提交于
      Make the existing function kernel-doc consistent throughout
      futex.c, following Documentation/kernel-doc-nano-howto.txt as
      closely as possible.
      
      When unsure, at least be consistent within futex.c.
      Signed-off-by: NDarren Hart <dvhltc@us.ibm.com>
      Acked-by: NPeter Zijlstra <peterz@infradead.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: Dinakar Guniguntala <dino@in.ibm.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      LKML-Reference: <20090922053022.8717.13339.stgit@Aeon>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      d96ee56c
    • D
      futex: Correct queue_me and unqueue_me commentary · d40d65c8
      Darren Hart 提交于
      The queue_me/unqueue_me commentary is oddly placed and out of date.
      Clean it up and correct the inaccurate bits.
      Signed-off-by: NDarren Hart <dvhltc@us.ibm.com>
      Acked-by: NPeter Zijlstra <peterz@infradead.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: Dinakar Guniguntala <dino@in.ibm.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      LKML-Reference: <20090922053015.8717.71713.stgit@Aeon>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      d40d65c8
    • D
      futex: Correct futex_wait_requeue_pi() commentary · 56ec1607
      Darren Hart 提交于
      Correct various typos and formatting inconsistencies in the
      commentary of futex_wait_requeue_pi().
      Signed-off-by: NDarren Hart <dvhltc@us.ibm.com>
      Acked-by: NPeter Zijlstra <peterz@infradead.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: Dinakar Guniguntala <dino@in.ibm.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      LKML-Reference: <20090922052958.8717.21932.stgit@Aeon>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      56ec1607
    • L
      Merge branch 'core-fixes-for-linus' of... · b8c7f1dc
      Linus Torvalds 提交于
      Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
      
      * 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        rcu: Fix whitespace inconsistencies
        rcu: Fix thinko, actually initialize full tree
        rcu: Apply results of code inspection of kernel/rcutree_plugin.h
        rcu: Add WARN_ON_ONCE() consistency checks covering state transitions
        rcu: Fix synchronize_rcu() for TREE_PREEMPT_RCU
        rcu: Simplify rcu_read_unlock_special() quiescent-state accounting
        rcu: Add debug checks to TREE_PREEMPT_RCU for premature grace periods
        rcu: Kconfig help needs to say that TREE_PREEMPT_RCU scales down
        rcutorture: Occasionally delay readers enough to make RCU force_quiescent_state
        rcu: Initialize multi-level RCU grace periods holding locks
        rcu: Need to update rnp->gpnum if preemptable RCU is to be reliable
      b8c7f1dc
    • L
      Merge branch 'perfcounters-fixes-for-linus' of... · f4eccb6d
      Linus Torvalds 提交于
      Merge branch 'perfcounters-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
      
      * 'perfcounters-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        perf_counter, powerpc, sparc: Fix compilation after perf_counter_overflow() change
        perf_counter: x86: Fix PMU resource leak
        perf util: SVG performance improvements
        perf util: Make the timechart SVG width dynamic
        perf timechart: Show the duration of scheduler delays in the SVG
        perf timechart: Show the name of the waker/wakee in timechart
      f4eccb6d
    • L
      Merge branch 'sched-fixes-for-linus' of... · 8e4bc3dd
      Linus Torvalds 提交于
      Merge branch 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
      
      * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        sched: Simplify sys_sched_rr_get_interval() system call
        sched: Fix potential NULL derference of doms_cur
        sched: Fix raciness in runqueue_is_locked()
        sched: Re-add lost cpu_allowed check to sched_fair.c::select_task_rq_fair()
        sched: Remove unneeded indentation in sched_fair.c::place_entity()
      8e4bc3dd
    • L
      Merge branch 'tracing-fixes-for-linus' of... · bd4c3a34
      Linus Torvalds 提交于
      Merge branch 'tracing-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
      
      * 'tracing-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        kernel/profile.c: Switch /proc/irq/prof_cpu_mask to seq_file
        tracing: Export trace_profile_buf symbols
        tracing/events: use list_for_entry_continue
        tracing: remove max_tracer_type_len
        function-graph: use ftrace_graph_funcs directly
        tracing: Remove markers
        tracing: Allocate the ftrace event profile buffer dynamically
        tracing: Factorize the events profile accounting
      bd4c3a34
    • L
      Merge branch 'x86-fixes-for-linus' of... · b3727c24
      Linus Torvalds 提交于
      Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
      
      * 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        x86: Print the hypervisor returned tsc_khz during boot
        x86: Correct segment permission flags in 64-bit linker script
        x86: cpuinit-annotate SMP boot trampolines properly
        x86: Increase timeout for EHCI debug port reset completion in early printk
        x86: Fix uaccess_32.h typo
        x86: Trivial whitespace cleanups
        x86, apic: Fix missed handling of discrete apics
        x86/i386: Remove duplicated #include
        x86, mtrr: Convert loop to a while based construct, avoid naked semicolon
        Revert 'x86: Fix system crash when loading with "reservetop" parameter'
        x86, mce: Fix compile warning in case of CONFIG_SMP=n
        x86, apic: Use logical flat on intel with <= 8 logical cpus
        x86: SGI UV: Map MMIO-High memory range
        x86: SGI UV: Add volatile semantics to macros that access chipset registers
        x86: SGI UV: Fix IPI macros
        x86: apic: Convert BUG() to BUG_ON()
        x86: Remove final bits of CONFIG_X86_OLD_MCE
      b3727c24
    • L
      Merge branch 'writeback' of git://git.kernel.dk/linux-2.6-block · 58e75a09
      Linus Torvalds 提交于
      * 'writeback' of git://git.kernel.dk/linux-2.6-block:
        nfs: initialize the backing_dev_info when creating the server
        writeback: make balance_dirty_pages() gradually back more off
        writeback: don't use schedule_timeout() without setting runstate
        nfs: nfs_kill_super() should call bdi_unregister() after killing super
      58e75a09
    • L
      Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6 · c720f565
      Linus Torvalds 提交于
      * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (222 commits)
        V4L/DVB (13033): pt1: Don't use a deprecated DMA_BIT_MASK macro
        V4L/DVB (13029): radio-si4713: remove #include <linux/version.h>
        V4L/DVB (13027): go7007: convert printks to v4l2_info
        V4L/DVB (13026): s2250-board: Implement brightness and contrast controls
        V4L/DVB (13025): s2250-board: Fix memory leaks
        V4L/DVB (13024): go7007: Implement vidioc_g_std and vidioc_querystd
        V4L/DVB (13023): go7007: Merge struct gofh and go declarations
        V4L/DVB (13022): go7007: Fix mpeg controls
        V4L/DVB (13021): go7007: Fix whitespace and line lengths
        V4L/DVB (13020): go7007: Updates to Kconfig and Makefile
        V4L/DVB (13019): video: initial support for ADV7180
        V4L/DVB (13018): kzalloc failure ignored in au8522_probe()
        V4L/DVB (13017): gspca: kmalloc failure ignored in sd_start()
        V4L/DVB (13016): kmalloc failure ignored in lgdt3304_attach() and s921_attach()
        V4L/DVB (13015): kmalloc failure ignored in m920x_firmware_download()
        V4L/DVB (13014): Add support for Compro VideoMate E800 (DVB-T part only)
        V4L/DVB (13013): FM TX: si4713: Kconfig: Fixed two typos.
        V4L/DVB (13012): uvc: introduce missing kfree
        V4L/DVB (13011): Change tuner type of BeholdTV cards
        V4L/DVB (13009): gspca - stv06xx-hdcs: Reduce exposure range
        ...
      c720f565
  2. 21 9月, 2009 28 次提交