1. 16 Dec, 2010 1 commit
  2. 08 Dec, 2010 10 commits
    • Heiko Carstens's avatar
      nohz: Fix get_next_timer_interrupt() vs cpu hotplug · dbd87b5a
      Heiko Carstens authored
      This fixes a bug as seen on 2.6.32 based kernels where timers got
      enqueued on offline cpus.
      
      If a cpu goes offline it might still have pending timers. These will
      be migrated during CPU_DEAD handling after the cpu is offline.
      However while the cpu is going offline it will schedule the idle task
      which will then call tick_nohz_stop_sched_tick().
      
      That function in turn will call get_next_timer_intterupt() to figure
      out if the tick of the cpu can be stopped or not. If it turns out that
      the next tick is just one jiffy off (delta_jiffies == 1)
      tick_nohz_stop_sched_tick() incorrectly assumes that the tick should
      not stop and takes an early exit and thus it won't update the load
      balancer cpu.
      
      Just afterwards the cpu will be killed and the load balancer cpu could
      be the offline cpu.
      
      On 2.6.32 based kernel get_nohz_load_balancer() gets called to decide
      on which cpu a timer should be enqueued (see __mod_timer()). Which
      leads to the possibility that timers get enqueued on an offline cpu.
      These will never expire and can cause a system hang.
      
      This has been observed 2.6.32 kernels. On current kernels
      __mod_timer() uses get_nohz_timer_target() which doesn't have that
      problem. However there might be other problems because of the too
      early exit tick_nohz_stop_sched_tick() in case a cpu goes offline.
      
      The easiest and probably safest fix seems to be to let
      get_next_timer_interrupt() just lie and let it say there isn't any
      pending timer if the current cpu is offline.
      
      I also thought of moving migrate_[hr]timers() from CPU_DEAD to
      CPU_DYING, but seeing that there already have been fixes at least in
      the hrtimer code in this area I'm afraid that this could add new
      subtle bugs.
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      Signed-off-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
      LKML-Reference: <20101201091109.GA8984@osiris.boeblingen.de.ibm.com>
      Cc: stable@kernel.org
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      dbd87b5a
    • Mike Galbraith's avatar
      Sched: fix skip_clock_update optimization · f26f9aff
      Mike Galbraith authored
      idle_balance() drops/retakes rq->lock, leaving the previous task
      vulnerable to set_tsk_need_resched().  Clear it after we return
      from balancing instead, and in setup_thread_stack() as well, so
      no successfully descheduled or never scheduled task has it set.
      
      Need resched confused the skip_clock_update logic, which assumes
      that the next call to update_rq_clock() will come nearly immediately
      after being set.  Make the optimization robust against the waking
      a sleeper before it sucessfully deschedules case by checking that
      the current task has not been dequeued before setting the flag,
      since it is that useless clock update we're trying to save, and
      clear unconditionally in schedule() proper instead of conditionally
      in put_prev_task().
      Signed-off-by: default avatarMike Galbraith <efault@gmx.de>
      Reported-by: default avatarBjoern B. Brandenburg <bbb.lst@gmail.com>
      Tested-by: default avatarYong Zhang <yong.zhang0@gmail.com>
      Signed-off-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: stable@kernel.org
      LKML-Reference: <1291802742.1417.9.camel@marge.simson.net>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      f26f9aff
    • Peter Zijlstra's avatar
      sched: Cure more NO_HZ load average woes · 0f004f5a
      Peter Zijlstra authored
      There's a long-running regression that proved difficult to fix and
      which is hitting certain people and is rather annoying in its effects.
      
      Damien reported that after 74f5187a (sched: Cure load average vs
      NO_HZ woes) his load average is unnaturally high, he also noted that
      even with that patch reverted the load avgerage numbers are not
      correct.
      
      The problem is that the previous patch only solved half the NO_HZ
      problem, it addressed the part of going into NO_HZ mode, not of
      comming out of NO_HZ mode. This patch implements that missing half.
      
      When comming out of NO_HZ mode there are two important things to take
      care of:
      
       - Folding the pending idle delta into the global active count.
       - Correctly aging the averages for the idle-duration.
      
      So with this patch the NO_HZ interaction should be complete and
      behaviour between CONFIG_NO_HZ=[yn] should be equivalent.
      
      Furthermore, this patch slightly changes the load average computation
      by adding a rounding term to the fixed point multiplication.
      Reported-by: default avatarDamien Wyart <damien.wyart@free.fr>
      Reported-by: default avatarTim McGrath <tmhikaru@gmail.com>
      Tested-by: default avatarDamien Wyart <damien.wyart@free.fr>
      Tested-by: default avatarOrion Poplawski <orion@cora.nwra.com>
      Tested-by: default avatarKyle McMartin <kyle@mcmartin.ca>
      Signed-off-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: stable@kernel.org
      Cc: Chase Douglas <chase.douglas@canonical.com>
      LKML-Reference: <1291129145.32004.874.camel@laptop>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      0f004f5a
    • Linus Torvalds's avatar
      Merge branches 'x86-fixes-for-linus', 'perf-fixes-for-linus' and... · 6313e3c2
      Linus Torvalds authored
      Merge branches 'x86-fixes-for-linus', 'perf-fixes-for-linus' and 'sched-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/pvclock: Zero last_value on resume
      
      * 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        perf record: Fix eternal wait for stillborn child
        perf header: Don't assume there's no attr info if no sample ids is provided
        perf symbols: Figure out start address of kernel map from kallsyms
        perf symbols: Fix kallsyms kernel/module map splitting
      
      * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
        nohz: Fix printk_needs_cpu() return value on offline cpus
        printk: Fix wake_up_klogd() vs cpu hotplug
      6313e3c2
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 · 6dde39be
      Linus Torvalds authored
      * 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
        drm/i915: i915 cannot provide switcher services.
        drm/radeon/kms: fix vram base calculation on rs780/rs880
        drm/radeon/kms: fix formatting of vram and gtt info
        drm/radeon/kms: forbid big bo allocation (fdo 31708) v3
        drm: Don't try and disable an encoder that was never enabled
        drm: Add missing drm_vblank_put() along queue vblank error path
        drm/i915/dp: Only apply the workaround if the select is still active
        drm/i915: Emit a request to clear a flushed and idle ring for unbusy bo
        drm/i915/lvds: Always restore panel-fitter when enabling the LVDS
        drm/i915/ringbuffer: Only print an error on the second attempt to reset head
        drm/i915: announce to userspace that the bsd ring is coherent
        agp/intel: Fix wrong kunmap in i830_cleanup()
        drm/i915: Factor in pixel-repeat in FDI M/N calculation
        drm/i915: Death to the unnecessary 64bit divide
        drm/i915: Clean conflicting modesetting registers upon init
        drm/i915: Apply a workaround for transitioning from DP on pipe B to HDMI.
        drm/i915: Always set the DP transcoder config to 8BPC.
      6dde39be
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input · f8f5d4f1
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
        Input: wacom - add new Bamboo PT (0xdb)
        Input: add input driver for polled GPIO buttons
        Input: turbografx - fix reference counting
        Input: synaptics - fix handling of 2-button ClickPads
        Input: wacom - add IDs for two new Bamboo PTs
        Input: document struct input_absinfo
        Input: add keycodes for touchpad on/off keys
        Input: usbtouchscreen - add support for LG Flatron T1710B
      f8f5d4f1
    • Dave Airlie's avatar
      drm/i915: i915 cannot provide switcher services. · 599bbb9d
      Dave Airlie authored
      it has a DSM but the switcher is done via WMI.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      599bbb9d
    • David Foley's avatar
      Input: wacom - add new Bamboo PT (0xdb) · 47d09235
      David Foley authored
      Adds new Bamboo Pen & Touch model - Bamboo P & T Special Edition
      Medium (CTH661/L; Product ID = 0xdb).
      Tested-by: default avatarTobias Verbeke <tobias.verbeke@gmail.com>
      Signed-off-by: default avatarDavid Foley <favux.is@gmail.com>
      Acked-by: default avatarPing Cheng <pingc@wacom.com>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      47d09235
    • Linus Torvalds's avatar
      Merge branch 'fixes/2637-rc5/s3c24xx' of git://git.fluff.org/bjdooks/linux · 2cedcc4f
      Linus Torvalds authored
      * 'fixes/2637-rc5/s3c24xx' of git://git.fluff.org/bjdooks/linux:
        ARM: S3C24XX: Fix mess with gpio {set,get}_pull callbacks
        ARM: mini2440: Fix Kconfig to allow kernel to build
        ARM: S3C2412: Fix typo in CONFIG_CPU_S3C2412_ONLY definition
        ARM: S3C2443: Select properly ARM core type
        ARM: SMDK2416: Select MACH_SMDK, S3C_DEV_NAND, S3C_DEV_USB_HOST
      2cedcc4f
    • Vasily Khoruzhick's avatar
      ARM: S3C24XX: Fix mess with gpio {set,get}_pull callbacks · 812c4e40
      Vasily Khoruzhick authored
      Currently the {set,get}_pull callbacks of the s3c24xx_gpiocfg_default structure
      are initalized via s3c_gpio_{get,set}pull_1up. This results in a linker
      error when only CONFIG_CPU_S3C2442 is selected:
      
      arch/arm/plat-s3c24xx/built-in.o:(.data+0x13f4): undefined reference to
      `s3c_gpio_getpull_1up'
      arch/arm/plat-s3c24xx/built-in.o:(.data+0x13f8): undefined reference to
      `s3c_gpio_setpull_1up'
      
      The s3c2442 has pulldowns instead of pullups compared to the s3c2440.
      The method of controlling them is the same though.
      So this patch modifies the existing s3c_gpio_{get,set}pull_1up helper functions
      to take an additional parameter deciding whether the pin has a pullup or pulldown.
      The s3c_gpio_{get,set}pull_1{down,up} functions then wrap that functions passing
      either S3C_GPIO_PULL_UP or S3C_GPIO_PULL_DOWN.
      
      Furthermore this patch sets up the s3c24xx_gpiocfg_default.{get,set}_pull fields
      in the s3c244{0,2}_map_io function to the new pulldown helper functions.
      
      Based on patch from "Lars-Peter Clausen" <lars@metafoo.de>
      Signed-off-by: default avatarVasily Khoruzhick <anarsoul@gmail.com>
      Signed-off-by: default avatarBen Dooks <ben-linux@fluff.org>
      812c4e40
  3. 07 Dec, 2010 17 commits
  4. 06 Dec, 2010 12 commits