08 Feb, 2010

6 commits

  • Conflicts:
    arch/sh/drivers/dma/dma-sh.c

    Paul Mundt
     
  • Tested to work with a SIU ASoC driver on sh7722 (migor).

    Signed-off-by: Guennadi Liakhovetski
    Acked-by: Dan Williams
    Signed-off-by: Paul Mundt

    Guennadi Liakhovetski
     
  • Both the original arch/sh/drivers/dma/dma-sh.c and the new SH dmaengine drivers
    do not take into account bits 3:2 of the Transfer Size field in the CHCR
    register, besides, bit-field defines set bit 2, but the mask only passes bits
    1:0 through. TS_16BLK and TS_32BLK macros are bogus too. This patch fixes all
    these issues for sh7722 and sh7724, other CPUs stay unchanged and might need to
    be fixed too.

    Signed-off-by: Guennadi Liakhovetski
    Acked-by: Dan Williams
    Signed-off-by: Paul Mundt

    Guennadi Liakhovetski
     
  • Slave DMA functionality uses scatter-gather arrays for data transfers,
    whereas memcpy just uses a single data buffer. This patch converts the
    current memcpy implementation in shdma.c to use scatter-gather, making it
    just a special case with one SG-element. This allows us to isolate
    descriptor list manipulations and locking into one function, thus reducing
    error chances.

    Signed-off-by: Guennadi Liakhovetski
    Acked-by: Dan Williams
    Signed-off-by: Paul Mundt

    Guennadi Liakhovetski
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
    Take ima_file_free() to proper place.
    ima: rename PATH_CHECK to FILE_CHECK
    ima: rename ima_path_check to ima_file_check
    ima: initialize ima before inodes can be allocated
    fix ima breakage
    Take ima_path_check() in nfsd past dentry_open() in nfsd_open()
    freeze_bdev: don't deactivate successfully frozen MS_RDONLY sb
    befs: fix leak

    Linus Torvalds
     
  • This reverts commit 703625118069 ("tty: fix race in tty_fasync") and
    commit b04da8bfdfbb ("fnctl: f_modown should call write_lock_irqsave/
    restore") that tried to fix up some of the fallout but was incomplete.

    It turns out that we really cannot hold 'tty->ctrl_lock' over calling
    __f_setown, because not only did that cause problems with interrupt
    disables (which the second commit fixed), it also causes a potential
    ABBA deadlock due to lock ordering.

    Thanks to Tetsuo Handa for following up on the issue, and running
    lockdep to show the problem. It goes roughly like this:

    - f_getown gets filp->f_owner.lock for reading without interrupts
    disabled, so an interrupt that happens while that lock is held can
    cause a lockdep chain from f_owner.lock -> sighand->siglock.

    - at the same time, the tty->ctrl_lock -> f_owner.lock chain that
    commit 703625118069 introduced, together with the pre-existing
    sighand->siglock -> tty->ctrl_lock chain means that we have a lock
    dependency the other way too.

    So instead of extending tty->ctrl_lock over the whole __f_setown() call,
    we now just take a reference to the 'pid' structure while holding the
    lock, and then release it after having done the __f_setown. That still
    guarantees that 'struct pid' won't go away from under us, which is all
    we really ever needed.

    Reported-and-tested-by: Tetsuo Handa
    Acked-by: Greg Kroah-Hartman
    Acked-by: Américo Wang
    Cc: stable@kernel.org
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

07 Feb, 2010

12 commits

  • Hooks: Just Say No.

    Signed-off-by: Al Viro

    Al Viro
     
  • With the movement of the ima hooks functions were renamed from *path* to
    *file* since they always deal with struct file. This patch renames some of
    the ima internal flags to make them consistent with the rest of the code.

    Signed-off-by: Mimi Zohar
    Signed-off-by: Eric Paris
    Signed-off-by: Al Viro

    Mimi Zohar
     
  • ima_path_check actually deals with files! call it ima_file_check instead.

    Signed-off-by: Eric Paris
    Acked-by: Mimi Zohar
    Signed-off-by: Al Viro

    Mimi Zohar
     
  • ima wants to create an inode information struct (iint) when inodes are
    allocated. This means that at least the part of ima which does this
    allocation (the allocation is filled with information later) should
    before any inodes are created. To accomplish this we split the ima
    initialization routine placing the kmem cache allocator inside a
    security_initcall() function. Since this makes use of radix trees we also
    need to make sure that is initialized before security_initcall().

    Signed-off-by: Eric Paris
    Acked-by: Mimi Zohar
    Signed-off-by: Al Viro

    Eric Paris
     
  • The "Untangling ima mess, part 2 with counters" patch messed
    up the counters. Based on conversations with Al Viro, this patch
    streamlines ima_path_check() by removing the counter maintaince.
    The counters are now updated independently, from measuring the file,
    in __dentry_open() and alloc_file() by calling ima_counts_get().
    ima_path_check() is called from nfsd and do_filp_open().
    It also did not measure all files that should have been measured.
    Reason: ima_path_check() got bogus value passed as mask.
    [AV: mea culpa]
    [AV: add missing nfsd bits]

    Signed-off-by: Mimi Zohar
    Signed-off-by: Al Viro

    Mimi Zohar
     
  • Signed-off-by: Al Viro

    Al Viro
     
  • Thanks Thomas and Christoph for testing and review.
    I removed 'smp_wmb()' before up_write from the previous patch,
    since up_write() should have necessary ordering constraints.
    (I.e. the change of s_frozen is visible to others after up_write)
    I'm quite sure the change is harmless but if you are uncomfortable
    with Tested-by/Reviewed-by on the modified patch, please remove them.

    If MS_RDONLY, freeze_bdev should just up_write(s_umount) instead of
    deactivate_locked_super().
    Also, keep sb->s_frozen consistent so that remount can check the frozen state.

    Otherwise a crash reported here can happen:
    http://lkml.org/lkml/2010/1/16/37
    http://lkml.org/lkml/2010/1/28/53

    This patch should be applied for 2.6.32 stable series, too.

    Reviewed-by: Christoph Hellwig
    Tested-by: Thomas Backlund
    Signed-off-by: Jun'ichi Nomura
    Cc: stable@kernel.org
    Signed-off-by: Al Viro

    Jun'ichi Nomura
     
  • Signed-off-by: Al Viro

    Al Viro
     
  • Linus Torvalds
     
  • * 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
    hwmon: (w83781d) Request I/O ports individually for probing
    hwmon: (lm78) Request I/O ports individually for probing
    hwmon: (adt7462) Wrong ADT7462_VOLT_COUNT

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/anholt/drm-intel:
    drm/i915: Fix leak of relocs along do_execbuffer error path
    drm/i915: slow acpi_lid_open() causes flickering - V2
    drm/i915: Disable SR when more than one pipe is enabled
    drm/i915: page flip support for Ironlake
    drm/i915: Fix the incorrect DMI string for Samsung SX20S laptop
    drm/i915: Add support for SDVO composite TV
    drm/i915: don't trigger ironlake vblank interrupt at irq install
    drm/i915: handle non-flip pending case when unpinning the scanout buffer
    drm/i915: Fix the device info of Pineview
    drm/i915: enable vblank interrupt on ironlake
    drm/i915: Prevent use of uninitialized pointers along error path.
    drm/i915: disable hotplug detect before Ironlake CRT detect

    Linus Torvalds
     
  • We incorrectly depended on the 'node_state/node_isset()' functions
    testing the node range, rather than checking it explicitly. That's not
    reliable, even if it might often happen to work. So do the proper
    explicit test.

    Reported-by: Marcus Meissner
    Acked-and-tested-by: Brice Goglin
    Acked-by: Hugh Dickins
    Cc: stable@kernel.org
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

06 Feb, 2010

7 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
    ASoC: pandora: Add APLL supply to fix audio output
    ALSA: ice1724 - aureon - fix wm8770 volume offset
    ALSA: cosmetic: make hda intel interrupt name consistent with others
    ALSA: hda - Delay switching to polling mode if an interrupt was missing
    ALSA: ctxfi - fix PTP address initialization

    Linus Torvalds
     
  • Different motherboards have different PNP declarations for
    W83781D/W83782D chips. Some declare the whole range of I/O ports (8
    ports), some declare only the useful ports (2 ports at offset 5) and
    some declare fancy ranges, for example 4 ports at offset 4. To
    properly handle all cases, request all ports individually for probing.
    After we have determined that we really have a W83781D or W83782D
    chip, the useful port range will be requested again, as a single
    block.

    I did not see a board which needs this yet, but I know of one for lm78
    driver and I'd like to keep the logic of these two drivers in sync.

    Signed-off-by: Jean Delvare
    Cc: stable@kernel.org

    Jean Delvare
     
  • Different motherboards have different PNP declarations for LM78/LM79
    chips. Some declare the whole range of I/O ports (8 ports), some
    declare only the useful ports (2 ports at offset 5) and some declare
    fancy ranges, for example 4 ports at offset 4. To properly handle all
    cases, request all ports individually for probing. After we have
    determined that we really have an LM78 or LM79 chip, the useful port
    range will be requested again, as a single block.

    This fixes the driver on the Olivetti M3000 DT 540, at least.

    Signed-off-by: Jean Delvare
    Cc: stable@kernel.org

    Jean Delvare
     
  • The #define ADT7462_VOLT_COUNT is wrong, it should be 13 not 12. All the
    for loops that use this as a limit count are of the typical form, "for
    (n = 0; n < ADT7462_VOLT_COUNT; n++)", so to loop through all voltages
    w/o missing the last one it is necessary for the count to be one greater
    than it is. (Specifically, you will miss the +1.5V 3GPIO input with count
    = 12 vs. 13.)

    Signed-off-by: Ray Copeland
    Acked-by: "Darrick J. Wong"
    Signed-off-by: Jean Delvare
    Cc: stable@kernel.org

    Ray Copeland
     
  • Takashi Iwai
     
  • Takashi Iwai
     
  • Takashi Iwai
     

05 Feb, 2010

15 commits