18 Apr, 2011

10 commits


17 Apr, 2011

5 commits

  • Apparently some distros set i2c-algo-bit.bit_test to 1 by
    default. In some cases this causes i2c_bit_add_bus
    to fail and prevents the i2c bus from being added. In the
    radeon case, we fail to add the ddc i2c buses which prevents
    the driver from being able to detect attached monitors.
    The i2c bus works fine even if bit_test fails. This is likely
    due to gpio switching that is required and handled in the
    pre/post_xfer hooks, so call the pre/post_xfer hooks in the
    bit test as well.

    Fixes:
    https://bugs.freedesktop.org/show_bug.cgi?id=36221

    Signed-off-by: Alex Deucher
    Signed-off-by: Jean Delvare
    Cc: stable@kernel.org [.38 down to .34]

    Alex Deucher
     
  • When warning on the use of deprecated i2c_driver methods
    attach_adapter and detach_adapter, mention the name of the driver
    which needs to be updated.

    Signed-off-by: Jean Delvare
    Cc: Benjamin Herrenschmidt

    Jean Delvare
     
  • * 'for-linus' of git://git.kernel.dk/linux-2.6-block:
    block: make unplug timer trace event correspond to the schedule() unplug
    block: let io_schedule() flush the plug inline

    Linus Torvalds
     
  • * 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (43 commits)
    Revert "USB: isp1760-hcd: move imask clear after pending work is done"
    xHCI: Implement AMD PLL quirk
    xhci: Tell USB core both roothubs lost power.
    usbcore: Bug fix: system can't suspend with USB3.0 device connected to USB3.0 hub
    USB: Fix unplug of device with active streams
    USB: xhci - also free streams when resetting devices
    xhci: Fix NULL pointer deref in handle_port_status()
    USB: xhci - fix math in xhci_get_endpoint_interval()
    USB: xhci: simplify logic of skipping missed isoc TDs
    USB: xhci - remove excessive 'inline' markings
    USB: xhci: unsigned char never equals -1
    USB: xhci - fix unsafe macro definitions
    USB: fix formatting of SuperSpeed endpoints in /proc/bus/usb/devices
    USB: isp1760-hcd: move imask clear after pending work is done
    USB: fsl_qe_udc: send ZLP when zero flag and length % maxpacket == 0
    usb: qcserial add missing errorpath kfrees
    usb: qcserial avoid pointing to freed memory
    usb: Fix qcserial memory leak on rmmod
    USB: ftdi_sio: add ids for Hameg HO720 and HO730
    USB: option: Added support for Samsung GT-B3730/GT-B3710 LTE USB modem.
    ...

    Linus Torvalds
     
  • …linus', 'timer-fixes-for-linus' and 'x86-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:
    futex: Set FLAGS_HAS_TIMEOUT during futex_wait restart setup

    * 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    perf_event: Fix cgrp event scheduling bug in perf_enable_on_exec()
    perf: Fix a build error with some GCC versions

    * 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    sched: Fix erroneous all_pinned logic
    sched: Fix sched-domain avg_load calculation

    * 'timer-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    RTC: rtc-mrst: follow on to the change of rtc_device_register()
    RTC: add missing "return 0" in new alarm func for rtc-bfin.c
    RTC: Fix s3c compile error due to missing s3c_rtc_setpie
    RTC: Fix early irqs caused by calling rtc_set_alarm too early

    * 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    x86, amd: Disable GartTlbWlkErr when BIOS forgets it
    x86, NUMA: Fix fakenuma boot failure
    x86/mrst: Fix boot crash caused by incorrect pin to irq mapping
    x86/ce4100: Add reg property to bridges

    Linus Torvalds
     

16 Apr, 2011

14 commits

  • It's a pretty close match to what we had before - the timer triggering
    would mean that nobody unplugged the plug in due time, in the new
    scheme this matches very closely what the schedule() unplug now is.
    It's essentially the difference between an explicit unplug (IO unplug)
    or an implicit unplug (timer unplug, we scheduled with pending IO
    queued).

    Signed-off-by: Jens Axboe

    Jens Axboe
     
  • Linus correctly observes that the most important dispatch cases
    are now done from kblockd, this isn't ideal for latency reasons.
    The original reason for switching dispatches out-of-line was to
    avoid too deep a stack, so by _only_ letting the "accidental"
    flush directly in schedule() be guarded by offload to kblockd,
    we should be able to get the best of both worlds.

    So add a blk_schedule_flush_plug() that offloads to kblockd,
    and only use that from the schedule() path.

    Signed-off-by: Jens Axboe

    Jens Axboe
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs:
    net/9p: nwname should be an unsigned int
    9p: Fix sparse error
    fs/9p: Fix error reported by coccicheck
    9p: revert tsyncfs related changes
    fs/9p: Use write_inode for data sync on server
    fs/9p: Fix revalidate to return correct value

    Linus Torvalds
     
  • * 'for-linus' of git://android.git.kernel.org/kernel/tegra:
    arm: tegra: fix error check in tegra2_clocks.c
    ARM: tegra: gpio: Fix unused variable warnings

    Linus Torvalds
     
  • * 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm:
    ARM: 6879/1: fix personality test wrt usage of domain handlers
    ARM: 6878/1: fix personality flag propagation across an exec
    ARM: 6877/1: the ADDR_NO_RANDOMIZE personality flag should be honored with mmap()
    ARM: 6876/1: Kconfig.debug: Remove unused CONFIG_DEBUG_ERRORS
    ARM: pxa: convert incorrect IRQ_TO_IRQ() to irq_to_gpio()
    ARM: mmp: align NR_BUILTIN_GPIO with gpio interrupt number
    ARM: pxa: align NR_BUILTIN_GPIO with GPIO interrupt number
    ARM: pxa: always clear LPM bits for PXA168 MFPR
    pcmcia: limit pxa2xx_trizeps4 subdriver to trizeps4 platform
    pcmcia: limit pxa2xx_balloon3 subdriver to balloon3 platform
    ARM: pxafb: Fix access to nonexistent member of pxafb_info
    ARM: 6872/1: arch:common:Makefile Remove unused config in the Makefile.
    ARM: 6868/1: Preserve the VFP state during fork
    ARM: 6867/1: Introduce THREAD_NOTIFY_COPY for copy_thread() hooks
    ARM: 6866/1: Do not restrict HIGHPTE to !OUTER_CACHE
    ARM: 6865/1: perf: ensure pass through zero is counted on overflow
    ARM: 6864/1: hw_breakpoint: clear DBGVCR out of reset
    ARM: Only allow PM_SLEEP with CPUs which support suspend
    ARM: Make consolidated PM sleep code depend on PM_SLEEP

    Linus Torvalds
     
  • This patch disables GartTlbWlk errors on AMD Fam10h CPUs if
    the BIOS forgets to do is (or is just too old). Letting
    these errors enabled can cause a sync-flood on the CPU
    causing a reboot.

    The AMD BKDG recommends disabling GART TLB Wlk Error completely.

    This patch is the fix for

    https://bugzilla.kernel.org/show_bug.cgi?id=33012

    on my machine.

    Signed-off-by: Joerg Roedel
    Link: http://lkml.kernel.org/r/20110415131152.GJ18463@8bytes.org
    Tested-by: Alexandre Demers
    Cc:
    Signed-off-by: H. Peter Anvin

    Joerg Roedel
     
  • During RCU walk in path_lookupat and path_openat, the rcu lookup
    frequently failed if looking up an absolute path, because when root
    directory was looked up, seq number was not properly set in nameidata.

    We dropped out of RCU walk in nameidata_drop_rcu due to mismatch in
    directory entry's seq number. We reverted to slow path walk that need
    to take references.

    With the following patch, I saw a 50% increase in an exim mail server
    benchmark throughput on a 4-socket Nehalem-EX system.

    Signed-off-by: Tim Chen
    Reviewed-by: Andi Kleen
    Cc: stable@kernel.org (v2.6.38)
    Signed-off-by: Linus Torvalds

    Tim Chen
     
  • Signed-off-by: Harsh Prateek Bora
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric VAn Hensbergen

    Harsh Prateek Bora
     
  • Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric Van Hensbergen

    Aneesh Kumar K.V
     
  • Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric Van Hensbergen

    Aneesh Kumar K.V
     
  • Now that we use write_inode to flush server
    cache related to fid, we don't need tsyncfs either fort dotl or dotu
    protocols. For dotu this helps to do a more efficient server flush.

    Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric Van Hensbergen

    Aneesh Kumar K.V
     
  • Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric Van Hensbergen

    Aneesh Kumar K.V
     
  • revalidate should return > 0 on success. Also return 0 on ENOENT
    to force do_revalidate to return NULL dentry;

    Signed-off-by: Aneesh Kumar K.V
    Signed-off-by: Venkateswararao Jujjuri
    Signed-off-by: Eric Van Hensbergen

    Aneesh Kumar K.V
     
  • Currently, numa=fake boot parameter is broken. If it's used,
    kernel may panic due to devide by zero error depending on CPU
    configuration

    Call Trace:
    [] find_busiest_group+0x38c/0xd30
    [] ? local_clock+0x6f/0x80
    [] load_balance+0xa3/0x600
    [] idle_balance+0xf3/0x180
    [] schedule+0x722/0x7d0
    [] ? wait_for_common+0x128/0x190
    [] schedule_timeout+0x265/0x320
    [] ? lock_release_holdtime+0x35/0x1a0
    [] ? wait_for_common+0x128/0x190
    [] ? __lock_release+0x9c/0x1d0
    [] ? _raw_spin_unlock_irq+0x30/0x40
    [] ? _raw_spin_unlock_irq+0x30/0x40
    [] wait_for_common+0x130/0x190
    [] ? try_to_wake_up+0x510/0x510
    [] wait_for_completion+0x1d/0x20
    [] kthread_create_on_node+0xac/0x150
    [] ? process_scheduled_works+0x40/0x40
    [] ? wait_for_common+0x4f/0x190
    [] __alloc_workqueue_key+0x1a3/0x590
    [] cpuset_init_smp+0x6b/0x7b
    [] kernel_init+0xc3/0x182
    [] kernel_thread_helper+0x4/0x10
    [] ? retint_restore_args+0x13/0x13
    [] ? start_kernel+0x400/0x400
    [] ? gs_change+0x13/0x13

    The divede by zero is caused by the following line,
    group->cpu_power==0:

    kernel/sched_fair.c::update_sg_lb_stats()
    /* Adjust by relative CPU power of the group */
    sgs->avg_load = (sgs->group_load * SCHED_LOAD_SCALE) / group->cpu_power;

    This regression was caused by commit e23bba6044 ("x86-64, NUMA: Unify
    emulated distance mapping") because it changes cpu -> node
    mapping in the process of dropping fake_physnodes().

    old) all cpus are assinged node 0
    now) cpus are assigned round robin
    (the logic is implemented by numa_init_array())

    Note: The change in behavior only happens if the system doesn't
    have neither ACPI SRAT table nor AMD northbridge NUMA
    information.

    Round robin assignment doesn't work because init_numa_sched_groups_power()
    assumes all logical cpus in the same physical cpu share the same node
    (then it only accounts for group_first_cpu()), and the simple round robin
    breaks the above assumption.

    Thus, this patch implements a reassignment of node-ids if buggy firmware
    or numa emulation makes wrong cpu node map. Tt enforce all logical cpus
    in the same physical cpu share the same node.

    Signed-off-by: KOSAKI Motohiro
    Acked-by: Tejun Heo
    Cc: Yinghai Lu
    Cc: Brian Gerst
    Cc: Cyrill Gorcunov
    Cc: Shaohui Zheng
    Cc: David Rientjes
    Cc: H. Peter Anvin
    Link: http://lkml.kernel.org/r/20110415203928.1303.A69D9226@jp.fujitsu.com
    Signed-off-by: Ingo Molnar

    KOSAKI Motohiro
     

15 Apr, 2011

11 commits

  • * 'for-linus' of git://git.kernel.dk/linux-2.6-block:
    block: only force kblockd unplugging from the schedule() path
    block: cleanup the block plug helper functions
    block, blk-sysfs: Use the variable directly instead of a function call
    block: move queue run on unplug to kblockd
    block: kill queue_sync_plugs()
    block: readd plug trace event
    block: add callback function for unplug notification
    block: add comment on why we save and disable interrupts in flush_plug_list()
    block: fixup block IO unplug trace call
    block: remove block_unplug_timer() trace point
    block: splice plug list to local context

    Linus Torvalds
     
  • * 'linux-next' of git://git.infradead.org/ubifs-2.6:
    UBIFS: fix compilation warnings when compiling with gcc 4.5
    UBIFS: fix oops when R/O file-system is fsync'ed

    Linus Torvalds
     
  • The FLAGS_HAS_TIMEOUT flag was not getting set, causing the restart_block to
    restart futex_wait() without a timeout after a signal.

    Commit b41277dc7a18ee332d in 2.6.38 introduced the regression by accidentally
    removing the the FLAGS_HAS_TIMEOUT assignment from futex_wait() during the setup
    of the restart block. Restore the originaly behavior.

    Fixes: https://bugzilla.kernel.org/show_bug.cgi?id=32922

    Reported-by: Tim Smith
    Reported-by: Torsten Hilbrich
    Signed-off-by: Darren Hart
    Signed-off-by: Eric Dumazet
    Cc: Peter Zijlstra
    Cc: John Kacur
    Cc: stable@kernel.org
    Link: http://lkml.kernel.org/r/%3Cdaac0eb3af607f72b9a4d3126b2ba8fb5ed3b883.1302820917.git.dvhart%40linux.intel.com%3E
    Signed-off-by: Thomas Gleixner

    Darren Hart
     
  • The case we should be verifying when updating the dentry name is that
    the _parent_ inode (the directory) semaphore is held, not the semaphore
    for the dentry itself. It's the directory locking that rename and
    readdir() etc all care about.

    The comment just above even says so - but then the BUG_ON() still
    checked the dentry inode itself.

    Very few people noticed, because this helper function really isn't used
    for very much, so you had to be using ncpfs to ever hit it.

    I think I should just remove the BUG_ON (the function really has just
    one user), but let's run with it fixed for a while before getting rid of
    it entirely.

    Reported-and-tested-by: Bongani Hlope
    Reported-and-tested-by: Bernd Feige
    Cc: Petr Vandrovec ,
    Cc: Arnd Bergmann
    Cc: Christoph Hellwig
    Cc: Nick Piggin
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • For the explicit unplugging, we'd prefer to kick things off
    immediately and not pay the penalty of the latency to switch
    to kblockd. So let blk_finish_plug() do the run inline, while
    the implicit-on-schedule-out unplug will punt to kblockd.

    Signed-off-by: Jens Axboe

    Jens Axboe
     
  • It's a bit of a mess currently. task->plug is being cleared
    and reset in __blk_finish_plug(), and blk_finish_plug() is
    testing for a NULL plug which cannot happen even from schedule()
    anymore since it uses blk_needs_flush_plug() to determine
    whether to call into this function at all.

    So get rid of some of the cruft.

    Signed-off-by: Jens Axboe

    Christoph Hellwig
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier/blackfin:
    Blackfin: SMP: fix cache flush loop
    Blackfin: time-ts: ack gptimer sooner to avoid missing short ints
    Blackfin: gptimers: fix thinko when disabling timers
    Blackfin: SMP: make all barriers handle cache issues

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
    libceph: fix linger request requeueing

    Linus Torvalds
     
  • The conventional format for boolean attributes in sysfs is numeric ("0" or
    "1" followed by new-line). Any boolean attribute can then be read and
    written using a generic function. Using the strings "yes [no]", "[yes]
    no" (read), "yes" and "no" (write) will frustrate this.

    [akpm@linux-foundation.org: use kstrtoul()]
    [akpm@linux-foundation.org: test_bit() doesn't return 1/0, per Neil]
    Signed-off-by: Ben Hutchings
    Cc: Andrea Arcangeli
    Cc: Mel Gorman
    Cc: Johannes Weiner
    Cc: Rik van Riel
    Cc: Hugh Dickins
    Tested-by: David Rientjes
    Cc: NeilBrown
    Cc: [2.6.38.x]
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ben Hutchings
     
  • On no-mmu arch, there is a memleak during shmem test. The cause of this
    memleak is ramfs_nommu_expand_for_mapping() added page refcount to 2
    which makes iput() can't free that pages.

    The simple test file is like this:

    int main(void)
    {
    int i;
    key_t k = ftok("/etc", 42);

    for ( i=0; i free
    total used free shared buffers
    Mem: 60320 17912 42408 0 0
    -/+ buffers: 17912 42408
    root:/> shmem
    run ok...
    root:/> free
    total used free shared buffers
    Mem: 60320 19096 41224 0 0
    -/+ buffers: 19096 41224
    root:/> shmem
    run ok...
    root:/> free
    total used free shared buffers
    Mem: 60320 20296 40024 0 0
    -/+ buffers: 20296 40024
    ...

    After this patch the test result is:(no memleak anymore)

    root:/> free
    total used free shared buffers
    Mem: 60320 16668 43652 0 0
    -/+ buffers: 16668 43652
    root:/> shmem
    run ok...
    root:/> free
    total used free shared buffers
    Mem: 60320 16668 43652 0 0
    -/+ buffers: 16668 43652

    Signed-off-by: Bob Liu
    Acked-by: Hugh Dickins
    Signed-off-by: David Howells
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Bob Liu
     
  • Commit 8a5ec0ba "Lockless (and preemptless) fastpaths for slub" makes use
    of this_cpu_cmpxchg_double() which needs this_cpu_cmpxchg16b_emu() on
    x86_64. Implementing cmpxchg16b emulation for UML would introduce too
    much complexity. So just disable it.

    Signed-off-by: Richard Weinberger
    Reported-by: Sergei Trofimovich
    Acked-by: Pekka Enberg
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Richard Weinberger