25 Sep, 2010

1 commit


16 Sep, 2010

1 commit


15 Sep, 2010

2 commits

  • I'm reposting this patch series as v4 since there have been no additional
    comments, and I cleaned up one extra bit of unneeded code (in 3/3). The patches
    are against Linus's tree: 2bfc96a127bc1cc94d26bfaa40159966064f9c8c
    (2.6.36-rc3).

    Would this patchset be suitable for inclusion in an mm branch?

    This changes adds a partition_meta_info struct which itself contains a
    union of structures that provide partition table specific metadata.

    This change leaves the union empty. The subsequent patch includes an
    implementation for CONFIG_EFI_PARTITION-based metadata.

    Signed-off-by: Will Drewry
    Signed-off-by: Jens Axboe

    Will Drewry
     
  • Change type of 2nd parameter of blk_rq_aligned() into unsigned long
    and remove unnecessary casting. Now we can call it with 'uaddr'
    instead of 'ubuf' in __blk_rq_map_user() so that it can remove
    following warnings from sparse:

    block/blk-map.c:57:31: warning: incorrect type in argument 2 (different address spaces)
    block/blk-map.c:57:31: expected void *addr
    block/blk-map.c:57:31: got void [noderef] *ubuf

    However blk_rq_map_kern() needs one more local variable to handle it.

    Signed-off-by: Namhyung Kim
    Signed-off-by: Jens Axboe

    Namhyung Kim
     

11 Sep, 2010

2 commits

  • Some controllers have a hardware limit on the number of protection
    information scatter-gather list segments they can handle.

    Introduce a max_integrity_segments limit in the block layer and provide
    a new scsi_host_template setting that allows HBA drivers to provide a
    value suitable for the hardware.

    Add support for honoring the integrity segment limit when merging both
    bios and requests.

    Signed-off-by: Martin K. Petersen
    Signed-off-by: Jens Axboe

    Martin K. Petersen
     
  • We have several users of min_not_zero, each of them using their own
    definition. Move the define to kernel.h.

    Signed-off-by: Martin K. Petersen
    Signed-off-by: Jens Axboe

    Martin K. Petersen
     

23 Aug, 2010

1 commit


22 Aug, 2010

1 commit

  • With the introduction of the new unified work queue thread pools,
    we lost one feature: It's no longer possible to know which worker
    is causing the CPU to wake out of idle. The result is that PowerTOP
    now reports a lot of "kworker/a:b" instead of more readable results.

    This patch adds a pair of tracepoints to the new workqueue code,
    similar in style to the timer/hrtimer tracepoints.

    With this pair of tracepoints, the next PowerTOP can correctly
    report which work item caused the wakeup (and how long it took):

    Interrupt (43) i915 time 3.51ms wakeups 141
    Work ieee80211_iface_work time 0.81ms wakeups 29
    Work do_dbs_timer time 0.55ms wakeups 24
    Process Xorg time 21.36ms wakeups 4
    Timer sched_rt_period_timer time 0.01ms wakeups 1

    Signed-off-by: Arjan van de Ven
    Signed-off-by: Linus Torvalds

    Arjan van de Ven
     

21 Aug, 2010

2 commits

  • It's a really simple list, and several of the users want to go backwards
    in it to find the previous vma. So rather than have to look up the
    previous entry with 'find_vma_prev()' or something similar, just make it
    doubly linked instead.

    Tested-by: Ian Campbell
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • kfifo_skip() is currently broken, due to the missing of the internal
    helper function. Add it.

    Signed-off-by: Andrea Righi
    Cc: Greg KH
    Acked-by: Stefani Seibold
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrea Righi
     

19 Aug, 2010

4 commits

  • Fix the declaration of sys_execve() in asm-generic/syscalls.h to have
    various consts applied to its pointers.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
    fs: brlock vfsmount_lock
    fs: scale files_lock
    lglock: introduce special lglock and brlock spin locks
    tty: fix fu_list abuse
    fs: cleanup files_lock locking
    fs: remove extra lookup in __lookup_hash
    fs: fs_struct rwlock to spinlock
    apparmor: use task path helpers
    fs: dentry allocation consolidation
    fs: fix do_lookup false negative
    mbcache: Limit the maximum number of cache entries
    hostfs ->follow_link() braino
    hostfs: dumb (and usually harmless) tpyo - strncpy instead of strlcpy
    remove SWRITE* I/O types
    kill BH_Ordered flag
    vfs: update ctime when changing the file's permission by setfacl
    cramfs: only unlock new inodes
    fix reiserfs_evict_inode end_writeback second call

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
    ALSA: emu10k1 - delay the PCM interrupts (add pcm_irq_delay parameter)
    ALSA: hda - Fix ALC680 base model capture
    ASoC: Remove DSP mode support for WM8776
    ALSA: hda - Add quirk for Dell Vostro 1220
    ALSA: riptide - Fix detection / load of firmware files

    Linus Torvalds
     
  • * 'merge-devicetree' of git://git.secretlab.ca/git/linux-2.6:
    spi.h: missing kernel-doc notation, please fix
    of: fix missing headers for of_address_to_resource() in MTD and SysACE drivers
    of: Fix missing includes
    ata: update for of_device to platform_device replacement
    microblaze: Fix of: eliminate of_device->node and dev_archdata->{of,prom}_node
    microblaze: Fix of/address: Merge all of the bus translation code
    booting-without-of: Remove nonexistent chapters from TOC, fix numbering

    Linus Torvalds
     

18 Aug, 2010

12 commits

  • With some hardware combinations, the PCM interrupts are acknowledged
    before the period boundary from the emu10k1 chip. The midlevel PCM code
    gets confused and the playback stream is interrupted.

    It seems that the interrupt processing shift by 2 samples is enough
    to fix this issue. This default value does not harm other,
    non-affected hardware.

    More information: Kernel bugzilla bug#16300

    [A copmile warning fixed by tiwai]

    Signed-off-by: Jaroslav Kysela
    Cc:
    Signed-off-by: Takashi Iwai

    Jaroslav Kysela
     
  • fs: scale files_lock

    Improve scalability of files_lock by adding per-cpu, per-sb files lists,
    protected with an lglock. The lglock provides fast access to the per-cpu lists
    to add and remove files. It also provides a snapshot of all the per-cpu lists
    (although this is very slow).

    One difficulty with this approach is that a file can be removed from the list
    by another CPU. We must track which per-cpu list the file is on with a new
    variale in the file struct (packed into a hole on 64-bit archs). Scalability
    could suffer if files are frequently removed from different cpu's list.

    However loads with frequent removal of files imply short interval between
    adding and removing the files, and the scheduler attempts to avoid moving
    processes too far away. Also, even in the case of cross-CPU removal, the
    hardware has much more opportunity to parallelise cacheline transfers with N
    cachelines than with 1.

    A worst-case test of 1 CPU allocating files subsequently being freed by N CPUs
    degenerates to contending on a single lock, which is no worse than before. When
    more than one CPU are allocating files, even if they are always freed by
    different CPUs, there will be more parallelism than the single-lock case.

    Testing results:

    On a 2 socket, 8 core opteron, I measure the number of times the lock is taken
    to remove the file, the number of times it is removed by the same CPU that
    added it, and the number of times it is removed by the same node that added it.

    Booting: locks= 25049 cpu-hits= 23174 (92.5%) node-hits= 23945 (95.6%)
    kbuild -j16 locks=2281913 cpu-hits=2208126 (96.8%) node-hits=2252674 (98.7%)
    dbench 64 locks=4306582 cpu-hits=4287247 (99.6%) node-hits=4299527 (99.8%)

    So a file is removed from the same CPU it was added by over 90% of the time.
    It remains within the same node 95% of the time.

    Tim Chen ran some numbers for a 64 thread Nehalem system performing a compile.

    throughput
    2.6.34-rc2 24.5
    +patch 24.9

    us sys idle IO wait (in %)
    2.6.34-rc2 51.25 28.25 17.25 3.25
    +patch 53.75 18.5 19 8.75

    So significantly less CPU time spent in kernel code, higher idle time and
    slightly higher throughput.

    Single threaded performance difference was within the noise of microbenchmarks.
    That is not to say penalty does not exist, the code is larger and more memory
    accesses required so it will be slightly slower.

    Cc: linux-kernel@vger.kernel.org
    Cc: Tim Chen
    Cc: Andi Kleen
    Signed-off-by: Nick Piggin
    Signed-off-by: Al Viro

    Nick Piggin
     
  • lglock: introduce special lglock and brlock spin locks

    This patch introduces "local-global" locks (lglocks). These can be used to:

    - Provide fast exclusive access to per-CPU data, with exclusive access to
    another CPU's data allowed but possibly subject to contention, and to provide
    very slow exclusive access to all per-CPU data.
    - Or to provide very fast and scalable read serialisation, and to provide
    very slow exclusive serialisation of data (not necessarily per-CPU data).

    Brlocks are also implemented as a short-hand notation for the latter use
    case.

    Thanks to Paul for local/global naming convention.

    Cc: linux-kernel@vger.kernel.org
    Cc: Al Viro
    Cc: "Paul E. McKenney"
    Signed-off-by: Nick Piggin
    Signed-off-by: Al Viro

    Nick Piggin
     
  • tty: fix fu_list abuse

    tty code abuses fu_list, which causes a bug in remount,ro handling.

    If a tty device node is opened on a filesystem, then the last link to the inode
    removed, the filesystem will be allowed to be remounted readonly. This is
    because fs_may_remount_ro does not find the 0 link tty inode on the file sb
    list (because the tty code incorrectly removed it to use for its own purpose).
    This can result in a filesystem with errors after it is marked "clean".

    Taking idea from Christoph's initial patch, allocate a tty private struct
    at file->private_data and put our required list fields in there, linking
    file and tty. This makes tty nodes behave the same way as other device nodes
    and avoid meddling with the vfs, and avoids this bug.

    The error handling is not trivial in the tty code, so for this bugfix, I take
    the simple approach of using __GFP_NOFAIL and don't worry about memory errors.
    This is not a problem because our allocator doesn't fail small allocs as a rule
    anyway. So proper error handling is left as an exercise for tty hackers.

    [ Arguably filesystem's device inode would ideally be divorced from the
    driver's pseudo inode when it is opened, but in practice it's not clear whether
    that will ever be worth implementing. ]

    Cc: linux-kernel@vger.kernel.org
    Cc: Christoph Hellwig
    Cc: Alan Cox
    Cc: Greg Kroah-Hartman
    Signed-off-by: Nick Piggin
    Signed-off-by: Al Viro

    Nick Piggin
     
  • fs: cleanup files_lock locking

    Lock tty_files with a new spinlock, tty_files_lock; provide helpers to
    manipulate the per-sb files list; unexport the files_lock spinlock.

    Cc: linux-kernel@vger.kernel.org
    Cc: Christoph Hellwig
    Cc: Alan Cox
    Acked-by: Andi Kleen
    Acked-by: Greg Kroah-Hartman
    Signed-off-by: Nick Piggin
    Signed-off-by: Al Viro

    Nick Piggin
     
  • fs: fs_struct rwlock to spinlock

    struct fs_struct.lock is an rwlock with the read-side used to protect root and
    pwd members while taking references to them. Taking a reference to a path
    typically requires just 2 atomic ops, so the critical section is very small.
    Parallel read-side operations would have cacheline contention on the lock, the
    dentry, and the vfsmount cachelines, so the rwlock is unlikely to ever give a
    real parallelism increase.

    Replace it with a spinlock to avoid one or two atomic operations in typical
    path lookup fastpath.

    Signed-off-by: Nick Piggin
    Signed-off-by: Al Viro

    Nick Piggin
     
  • These flags aren't real I/O types, but tell ll_rw_block to always
    lock the buffer instead of giving up on a failed trylock.

    Instead add a new write_dirty_buffer helper that implements this semantic
    and use it from the existing SWRITE* callers. Note that the ll_rw_block
    code had a bug where it didn't promote WRITE_SYNC_PLUG properly, which
    this patch fixes.

    In the ufs code clean up the helper that used to call ll_rw_block
    to mirror sync_dirty_buffer, which is the function it implements for
    compound buffers.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Al Viro

    Christoph Hellwig
     
  • Instead of abusing a buffer_head flag just add a variant of
    sync_dirty_buffer which allows passing the exact type of write
    flag required.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Al Viro

    Christoph Hellwig
     
  • Added comments in kernel-doc notation for previously added struct fields.

    Signed-off-by: Ernst Schwab
    Acked-by: Randy Dunlap
    Signed-off-by: Grant Likely

    Ernst Schwab
     
  • * master.kernel.org:/home/rmk/linux-2.6-arm:
    VIDEO: amba clcd: don't disable an already disabled clock
    ARM: Tighten check for allowable CPSR values
    ARM: 6329/1: wire up sys_accept4() on ARM
    ARM: 6328/1: Build with -fno-dwarf2-cfi-asm
    ARM: 6326/1: kgdb: fix GDB_MAX_REGS no longer used

    Linus Torvalds
     
  • Make do_execve() take a const filename pointer so that kernel_execve() compiles
    correctly on ARM:

    arch/arm/kernel/sys_arm.c:88: warning: passing argument 1 of 'do_execve' discards qualifiers from pointer target type

    This also requires the argv and envp arguments to be consted twice, once for
    the pointer array and once for the strings the array points to. This is
    because do_execve() passes a pointer to the filename (now const) to
    copy_strings_kernel(). A simpler alternative would be to cast the filename
    pointer in do_execve() when it's passed to copy_strings_kernel().

    do_execve() may not change any of the strings it is passed as part of the argv
    or envp lists as they are some of them in .rodata, so marking these strings as
    const should be fine.

    Further kernel_execve() and sys_execve() need to be changed to match.

    This has been test built on x86_64, frv, arm and mips.

    Signed-off-by: David Howells
    Tested-by: Ralf Baechle
    Acked-by: Russell King
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Fix the clock enable/disable tracking in the AMBA CLCD driver so
    that the driver doesn't try to disable an already disabled clock,
    thereby causing the clock (if shared) to become unbalanced.

    This resolves a problem with CLCD on LPC32xx ARM platforms.

    Reported-by: Kevin Wells
    Signed-off-by: Russell King

    Russell King
     

16 Aug, 2010

2 commits

  • * 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
    gcc-4.6: ACPI: fix unused but set variables in ACPI
    ACPI thermal: make procfs I/F depend on CONFIG_ACPI_PROCFS
    ACPI video: make procfs I/F depend on CONFIG_ACPI_PROCFS
    ACPI processor: remove deprecated ACPI procfs I/F
    ACPI power_resource: remove unused procfs I/F
    ACPI: remove deprecated ACPI procfs I/F
    ACPI: introduce drivers/acpi/sysfs.c
    ACPI: introduce module parameter acpi.aml_debug_output
    ACPI: introduce drivers/acpi/debugfs.c
    ACPI, APEI, ERST debug support
    ACPI, APEI, Manage GHES as platform devices
    ACPI, APEI, Rename CPER and GHES severity constants
    ACPI, APEI, Fix a typo of error path of apei_resources_request
    ACPI / ACPICA: Fix reference counting problems with GPE handlers
    ACPI: Add the check of ADR flag in course of finding ACPI handle for PCI device
    ACPI / Sleep: Drop acpi_suspend_finish()
    ACPI / Sleep: Consolidate suspend and hibernation routines
    ACPI / Wakeup: Simplify enabling of wakeup devices
    ACPI / Sleep: Rework enabling wakeup devices
    ACPI / Sleep: Free NVS copy if suspending of devices fails

    Fixed up totally buggered "ACPI: fix unused but set variables in ACPI"
    patch that doesn't even compile in the merge.

    Thanks to Sedat Dilek for noticing the
    breakage before I even pulled. And a big "Grrr.." at Len for not even
    bothering to compile the tree before asking me to pull.

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile:
    arch/tile: don't validate CROSS_COMPILE needlessly
    arch/tile: export only COMMAND_LINE_SIZE to userspace.
    arch/tile: rename ARCH_KMALLOC_MINALIGN to ARCH_DMA_MINALIGN
    arch/tile: Rename the hweight() implementations to __arch_hweight()
    arch/tile: extend syscall ABI to set r1 on return as well.
    arch/tile: Various cleanups.
    arch/tile: support backtracing on TILE-Gx
    arch/tile: Fix a couple of issues with the COMPAT code for TILE-Gx.
    arch/tile: Use separate, better minsec values for clocksource and sched_clock.
    arch/tile: correct a bug in freeing bootmem by VA for the optional second initrd.
    arch: tile: mm: pgtable.c: Removed duplicated #include
    arch: tile: kernel/proc.c Removed duplicated #include
    Add fanotify syscalls to .
    arch/tile: support new kunmap_atomic() naming convention.
    tile: remove unused ISA_DMA_THRESHOLD define

    Conflicts in arch/tile/configs/tile_defconfig (pick the mainline version
    with the reduced defconfig).

    Linus Torvalds
     

15 Aug, 2010

10 commits

  • Conflicts:
    drivers/acpi/debug.c

    Signed-off-by: Len Brown

    Len Brown
     
  • Remove deprecated ACPI processor procfs I/F, including:
    /proc/acpi/processor/CPUX/power
    /proc/acpi/processor/CPUX/limit
    /proc/acpi/processor/CPUX/info

    /proc/acpi/processor/CPUX/throttling still exists,
    as we don't have sysfs I/F available for now.

    Signed-off-by: Zhang Rui
    Signed-off-by: Len Brown

    Zhang Rui
     
  • Len Brown
     
  • Len Brown
     
  • Introduce module parameter acpi.aml_debug_output.

    With acpi.aml_debug_output set, we can get AML debug object output
    (Store (AAA, Debug)), even with CONFIG_ACPI_DEBUG cleared.

    Together with the runtime custom method mechanism,
    we can debug AML code problems without rebuilding the kernel.

    Signed-off-by: Zhang Rui
    Signed-off-by: Len Brown

    Zhang Rui
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/sam/cleanup:
    defconfig reduction
    kbuild: drop unifdef-y support
    archs: replace unifdef-y with header-y
    include: replace unifdef-y with header-y

    Linus Torvalds
     
  • * 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging: (22 commits)
    hwmon: (via-cputemp) Remove bogus "SHOW" global variable
    hwmon: jc42 depends on I2C
    hwmon: (pc87427) Add a maintainer
    hwmon: (pc87427) Move sysfs file removal to a separate function
    hwmon: (pc87427) Add temperature monitoring support
    hwmon: (pc87427) Add support for the second logical device
    hwmon: (pc87427) Add support for manual fan speed control
    hwmon: (pc87427) Minor style cleanups
    hwmon: (pc87427) Handle disabled fan inputs properly
    hwmon: (w83627ehf) Add support for W83667HG-B
    hwmon: (w83627ehf) Driver cleanup
    hwmon: Add driver for SMSC EMC2103 temperature monitor and fan controller
    hwmon: Remove in[0-*]_fault from sysfs-interface
    hwmon: Add 4 current alarm/beep attributes to sysfs-interface
    hwmon: Add 3 critical limit attributes to sysfs-interface
    hwmon: (asc7621) Clean up and improve detect function
    hwmon: (it87) Export labels for internal sensors
    hwmon: (lm75) Add suspend/resume feature
    hwmon: (emc1403) Add power support
    hwmon: (ltc4245) Expose all GPIO pins as analog voltages
    ...

    Linus Torvalds
     
  • unifdef-y and header-y has same semantic.
    So there is no need to have both.

    Drop the unifdef-y variant and sort all lines again

    Signed-off-by: Sam Ravnborg

    Sam Ravnborg
     
  • Add support for exposing all GPIO pins as analog voltages. Though this is
    not an ideal use of the chip, some hardware engineers may decide that the
    LTC4245 meets their design requirements when studying the datasheet.

    The GPIO pins are sampled in round-robin fashion, meaning that a slow
    reader will see stale data. A userspace application can detect this,
    because it will get -EAGAIN when reading from a sysfs file which contains
    stale data.

    Users can choose to use this feature on a per-chip basis by using either
    platform data or the OF device tree (where applicable).

    Signed-off-by: Ira W. Snyder
    Signed-off-by: Jean Delvare

    Ira W. Snyder
     
  • * 'next-spi' of git://git.secretlab.ca/git/linux-2.6:
    spi/amba_pl022: Fix probe and remove hook section annotations.
    spi/mpc5121: change annotations for probe and remove functions
    spi/bitbang: reinitialize transfer parameters for every message
    spi/spi-gpio: add support for controllers without MISO or MOSI pin
    spi/bitbang: add support for SPI_MASTER_NO_{TX, RX} modes
    SPI100k: Fix 8-bit and RX-only transfers
    spi/mmc_spi: mmc_spi adaptations for SPI bus locking API
    spi/mmc_spi: SPI bus locking API, using mutex

    Fix trivial conflict in drivers/spi/mpc512x_psc_spi.c due to 'struct
    of_device' => 'struct platform_device' rename and __init/__exit to
    __devinit/__devexit fix.

    Linus Torvalds
     

14 Aug, 2010

2 commits