25 Aug, 2011

1 commit


23 Aug, 2011

3 commits

  • The first change is to add an of_node_put, since codec_np has previously
    been allocated. The rest of the patch reorganizes the error handling code
    so the only code executed is that which is needed.

    A simplified version of the semantic match that finds this problem is as
    follows: (http://coccinelle.lip6.fr/)

    //
    @@
    identifier x;
    expression E1!=0,E2,E3,E4;
    statement S;
    iterator I;
    @@

    (
    if (...) { ... when != of_node_put(x)
    when != x = E3
    when != E3 = x
    * return ...;
    }
    ... when != x = E2
    when != I(...,x,...) S
    if (...) { ... when != x = E4
    of_node_put(x); ... return ...; }
    )
    //

    Signed-off-by: Julia Lawall
    Acked-by: Timur Tabi
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Julia Lawall
     
  • dma_channel_np has been accessed at this point, so decrease its reference
    count before leaving the function.

    A simplified version of the semantic match that finds this problem is as
    follows: (http://coccinelle.lip6.fr/)

    //
    @@
    identifier x;
    expression E1!=0,E2,E3,E4;
    statement S;
    iterator I;
    @@

    (
    if (...) { ... when != of_node_put(x)
    when != x = E3
    when != E3 = x
    * return ...;
    }
    ... when != x = E2
    when != I(...,x,...) S
    if (...) { ... when != x = E4
    of_node_put(x); ... return ...; }
    )
    //

    Signed-off-by: Julia Lawall
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Julia Lawall
     
  • of_parse_phandle increments the reference count of np, so this should be
    decremented before trying the next possibility.

    Since we don't actually use np, we can decrement the reference count
    immediately.

    Reported-by: Julia Lawall
    Signed-off-by: Timur Tabi
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Timur Tabi
     

26 Jul, 2011

1 commit

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (43 commits)
    fs: Merge split strings
    treewide: fix potentially dangerous trailing ';' in #defined values/expressions
    uwb: Fix misspelling of neighbourhood in comment
    net, netfilter: Remove redundant goto in ebt_ulog_packet
    trivial: don't touch files that are removed in the staging tree
    lib/vsprintf: replace link to Draft by final RFC number
    doc: Kconfig: `to be' -> `be'
    doc: Kconfig: Typo: square -> squared
    doc: Konfig: Documentation/power/{pm => apm-acpi}.txt
    drivers/net: static should be at beginning of declaration
    drivers/media: static should be at beginning of declaration
    drivers/i2c: static should be at beginning of declaration
    XTENSA: static should be at beginning of declaration
    SH: static should be at beginning of declaration
    MIPS: static should be at beginning of declaration
    ARM: static should be at beginning of declaration
    rcu: treewide: Do not use rcu_read_lock_held when calling rcu_dereference_check
    Update my e-mail address
    PCIe ASPM: forcedly -> forcibly
    gma500: push through device driver tree
    ...

    Fix up trivial conflicts:
    - arch/arm/mach-ep93xx/dma-m2p.c (deleted)
    - drivers/gpio/gpio-ep93xx.c (renamed and context nearby)
    - drivers/net/r8169.c (just context changes)

    Linus Torvalds
     

11 Jul, 2011

1 commit


14 Jun, 2011

1 commit


10 Jun, 2011

1 commit


09 Jun, 2011

3 commits

  • Mark Brown
     
  • Device tree integer properties are encoded in big-endian format, but some of
    the Freescale ASoC drivers were assuming that the host is in big-endian format
    as well. Although this is true, it's better to use endian-safe accessors.

    Also add a check for a failed ioremap() call in the SSI driver.

    Signed-off-by: Timur Tabi
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Timur Tabi
     
  • The DMA (PCM) driver used by some Freescale PowerPC supports separate DAIs
    for playback and capture, so DMA buffers should be allocated only for the
    initialized streams. Instead of checking for the number of active channels,
    which apparently is not reliable, check to see if the actual stream object
    exists.

    Also provide a better name for the DMA interrupt.

    Signed-off-by: Timur Tabi
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Timur Tabi
     

08 Jun, 2011

1 commit


19 Mar, 2011

1 commit

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (308 commits)
    ALSA: sound/pci/asihpi: check adapter index in hpi_ioctl
    ALSA: aloop - Fix possible IRQ lock inversion
    ALSA: sound/core: merge list_del()/list_add_tail() to list_move_tail()
    ALSA: ctxfi - use list_move() instead of list_del()/list_add() combination
    ALSA: firewire - msleep needs delay.h
    ALSA: firewire-lib, firewire-speakers: handle packet queueing errors
    ALSA: firewire-lib: allocate DMA buffer separately
    ALSA: firewire-lib: use no-info SYT for packets without SYT sample
    ALSA: add LaCie FireWire Speakers/Griffin FireWave Surround driver
    ALSA: hda - Remove an unused variable in patch_realtek.c
    ALSA: hda - pin-adc-mux-dmic auto-configuration of 92HD8X codecs
    ALSA: hda - fix digital mic selection in mixer on 92HD8X codecs
    ALSA: hda - Move default input-src selection to init part
    ALSA: hda - Initialize special cases for input src in init phase
    ALSA: ctxfi - Clear input settings before initialization
    ALSA: ctxfi - Fix SPDIF status retrieval
    ALSA: ctxfi - Fix incorrect SPDIF status bit mask
    ALSA: ctxfi - Fix microphone boost codes/comments
    ALSA: atiixp - Fix wrong time-out checks during ac-link reset
    ALSA: intel8x0m: append 'm' to "r_intel8x0"
    ...

    Linus Torvalds
     

01 Mar, 2011

1 commit


27 Jan, 2011

1 commit


30 Nov, 2010

2 commits


25 Nov, 2010

2 commits


23 Nov, 2010

1 commit


09 Nov, 2010

1 commit


27 Oct, 2010

1 commit


02 Sep, 2010

1 commit

  • Add a call to of_node_put in the error handling code following a call to
    of_parse_phandle.

    This patch also moves the existing call to of_node_put tothe end of the
    error handling code, to make it possible to jump to of_node_put without
    doing the other cleanup operations. These appear to be disjoint
    operations, so the ordering doesn't matter.

    The semantic match that finds this problem is as follows:
    (http://coccinelle.lip6.fr/)

    //
    @r exists@
    local idexpression x;
    expression E,E1,E2;
    statement S;
    @@

    *x =
    (of_find_node_by_path
    |of_find_node_by_name
    |of_find_node_by_phandle
    |of_get_parent
    |of_get_next_parent
    |of_get_next_child
    |of_find_compatible_node
    |of_match_node
    |of_find_node_by_type
    |of_find_node_with_property
    |of_find_matching_node
    |of_parse_phandle
    )(...);
    ...
    if (x == NULL) S
    ;
    |
    * return ...;
    )
    }
    ...>
    (
    E2 = x;
    |
    of_node_put(x);
    )
    //

    Signed-off-by: Julia Lawall
    Acked-by: Timur Tabi
    Acked-by: Liam Girdwood
    Signed-off-by: Mark Brown

    Julia Lawall
     

21 Aug, 2010

2 commits


20 Aug, 2010

2 commits


19 Aug, 2010

1 commit

  • Add code that programs the DMA and SSI controllers differently based on the
    FIFO depth of the SSI.

    The SSI devices on the MPC8610 and the P1022 are identical in every way except
    one: the transmit and receive FIFO depth. On the MPC8610, the depth is eight.
    On the P1022, it's fifteen. The device tree nodes for the SSI include a
    "fsl,fifo-depth" property that specifies the FIFO depth.

    Signed-off-by: Timur Tabi
    Acked-by: Mark Brown
    Signed-off-by: Liam Girdwood

    Timur Tabi
     

17 Aug, 2010

1 commit

  • Fairly simple conflicts, the most serious ones are the i.MX ones which I
    suspect now need another rename.

    Conflicts:
    arch/arm/mach-mx2/clock_imx27.c
    arch/arm/mach-mx2/devices.c
    arch/arm/mach-omap2/board-rx51-peripherals.c
    arch/arm/mach-omap2/board-zoom2.c
    sound/soc/fsl/mpc5200_dma.c
    sound/soc/fsl/mpc5200_dma.h
    sound/soc/fsl/mpc8610_hpcd.c
    sound/soc/pxa/spitz.c

    Mark Brown
     

13 Aug, 2010

1 commit


12 Aug, 2010

5 commits

  • Add support for adding "status = disabled" to an SSI node to incidate that it
    is not wired on the board. This replaces the not-so-intuitive previous method
    of omitting a codec-handle property.

    Signed-off-by: Timur Tabi
    Acked-by: Kumar Gala
    Acked-by: Mark Brown
    Signed-off-by: Liam Girdwood

    Timur Tabi
     
  • The error handling code in the OF probe function of the SSI driver is not
    freeing all resources correctly.

    Since the machine driver no longer calls the DMA driver to provide information
    about the SSI, we don't need to keep a list of DMA objects any more. In
    addition, the fsl_soc_dma_remove() function is incorrectly removing *all*
    DMA objects when it should only remove one.

    Signed-off-by: Timur Tabi
    Signed-off-by: Liam Girdwood

    Timur Tabi
     
  • Update the DMA driver used by the Freescale MPC8610 HPCD audio driver to
    support 36-bit physical addresses, for both DMA buffers and the SSI registers.

    The DMA driver calls snd_dma_alloc_pages() to allocate the DMA buffers for
    playback and capture. This function is just a front-end for
    dma_alloc_coherent(). Currently, dma_alloc_coherent() only allocates buffers
    in low memory (it ignores GFP_HIGHMEM), so we never actually get a DMA buffer
    with a real 36-bit physical address.

    Signed-off-by: Timur Tabi
    Signed-off-by: Liam Girdwood

    Timur Tabi
     
  • The immap_86xx.h header file only defines one data structure: the "global
    utilities" register set found on Freescale PowerPC SOCs. Rename this file
    to fsl_guts.h to reflect its true purpose, and extend it to cover the "GUTS"
    register set on 85xx chips.

    Signed-off-by: Timur Tabi
    Acked-by: Mark Brown
    Acked-by: Kumar Gala
    Signed-off-by: Liam Girdwood

    Timur Tabi
     
  • This patch extends the ASoC API to allow sound cards to have more than one
    CODEC and more than one platform DMA controller. This is achieved by dividing
    some current ASoC structures that contain both driver data and device data into
    structures that only either contain device data or driver data. i.e.

    struct snd_soc_codec ---> struct snd_soc_codec (device data)
    +-> struct snd_soc_codec_driver (driver data)

    struct snd_soc_platform ---> struct snd_soc_platform (device data)
    +-> struct snd_soc_platform_driver (driver data)

    struct snd_soc_dai ---> struct snd_soc_dai (device data)
    +-> struct snd_soc_dai_driver (driver data)

    struct snd_soc_device ---> deleted

    This now allows ASoC to be more tightly aligned with the Linux driver model and
    also means that every ASoC codec, platform and (platform) DAI is a kernel
    device. ASoC component private data is now stored as device private data.

    The ASoC sound card struct snd_soc_card has also been updated to store lists
    of it's components rather than a pointer to a codec and platform. The PCM
    runtime struct soc_pcm_runtime now has pointers to all its components.

    This patch adds DAPM support for ASoC multi-component and removes struct
    snd_soc_socdev from DAPM core. All DAPM calls are now made on a card, codec
    or runtime PCM level basis rather than using snd_soc_socdev.

    Other notable multi-component changes:-

    * Stream operations now de-reference less structures.
    * close_delayed work() now runs on a DAI basis rather than looping all DAIs
    in a card.
    * PM suspend()/resume() operations can now handle N CODECs and Platforms
    per sound card.
    * Added soc_bind_dai_link() to bind the component devices to the sound card.
    * Added soc_dai_link_probe() and soc_dai_link_remove() to probe and remove
    DAI link components.
    * sysfs entries can now be registered per component per card.
    * snd_soc_new_pcms() functionailty rolled into dai_link_probe().
    * snd_soc_register_codec() now does all the codec list and mutex init.

    This patch changes the probe() and remove() of the CODEC drivers as follows:-

    o Make CODEC driver a platform driver
    o Moved all struct snd_soc_codec list, mutex, etc initialiasation to core.
    o Removed all static codec pointers (drivers now support > 1 codec dev)
    o snd_soc_register_pcms() now done by core.
    o snd_soc_register_dai() folded into snd_soc_register_codec().

    CS4270 portions:
    Acked-by: Timur Tabi

    Some TLV320aic23 and Cirrus platform fixes.
    Signed-off-by: Ryan Mallon

    TI CODEC and OMAP fixes
    Signed-off-by: Peter Ujfalusi
    Signed-off-by: Janusz Krzysztofik
    Signed-off-by: Jarkko Nikula

    Samsung platform and misc fixes :-
    Signed-off-by: Chanwoo Choi
    Signed-off-by: Joonyoung Shim
    Signed-off-by: Kyungmin Park
    Reviewed-by: Jassi Brar
    Signed-off-by: Seungwhan Youn

    MPC8610 and PPC fixes.
    Signed-off-by: Timur Tabi

    i.MX fixes and some core fixes.
    Signed-off-by: Sascha Hauer

    J4740 platform fixes:-
    Signed-off-by: Lars-Peter Clausen

    CC: Tony Lindgren
    CC: Nicolas Ferre
    CC: Kevin Hilman
    CC: Sascha Hauer
    CC: Atsushi Nemoto
    CC: Kuninori Morimoto
    CC: Daniel Gloeckner
    CC: Manuel Lauss
    CC: Mike Frysinger
    CC: Arnaud Patard
    CC: Wan ZongShun

    Acked-by: Mark Brown
    Signed-off-by: Liam Girdwood

    Liam Girdwood
     

09 Aug, 2010

1 commit


08 Aug, 2010

1 commit

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (214 commits)
    ALSA: hda - Add pin-fix for HP dc5750
    ALSA: als4000: Fix potentially invalid DMA mode setup
    ALSA: als4000: enable burst mode
    ALSA: hda - Fix initial capsrc selection in patch_alc269()
    ASoC: TWL4030: Capture route runtime DAPM ordering fix
    ALSA: hda - Add PC-beep whitelist for an Intel board
    ALSA: hda - More relax for pending period handling
    ALSA: hda - Define AC_FMT_* constants
    ALSA: hda - Fix beep frequency on IDT 92HD73xx and 92HD71Bxx codecs
    ALSA: hda - Add support for HDMI HBR passthrough
    ALSA: hda - Set Stream Type in Stream Format according to AES0
    ALSA: hda - Fix Thinkpad X300 so SPDIF is not exposed
    ALSA: hda - FIX to not expose SPDIF on Thinkpad X301, since it does not have the ability to use SPDIF
    ASoC: wm9081: fix resource reclaim in wm9081_register error path
    ASoC: wm8978: fix a memory leak if a wm8978_register fail
    ASoC: wm8974: fix a memory leak if another WM8974 is registered
    ASoC: wm8961: fix resource reclaim in wm8961_register error path
    ASoC: wm8955: fix resource reclaim in wm8955_register error path
    ASoC: wm8940: fix a memory leak if wm8940_register return error
    ASoC: wm8904: fix resource reclaim in wm8904_register error path
    ...

    Linus Torvalds
     

07 Aug, 2010

1 commit

  • Call the gpio reset platform function instead of using the flawed
    ac97 functionality of the MPC5200(b)

    From MPC5200B User's Manual:
    "Some AC97 devices goes to a test mode, if the Sync line is high
    during the Res line is low (reset phase). To avoid this behavior the
    Sync line must be also forced to zero during the reset phase. To do
    that, the pin muxing should switch to GPIO mode and the GPIO control
    register should be used to control the output lines."

    Signed-off-by: Eric Millbrandt
    Signed-off-by: Grant Likely

    Eric Millbrandt
     

06 Aug, 2010

1 commit

  • of_device is just an alias for platform_device, so remove it entirely. Also
    replace to_of_device() with to_platform_device() and update comment blocks.

    This patch was initially generated from the following semantic patch, and then
    edited by hand to pick up the bits that coccinelle didn't catch.

    @@
    @@
    -struct of_device
    +struct platform_device

    Signed-off-by: Grant Likely
    Reviewed-by: David S. Miller

    Grant Likely
     

05 Aug, 2010

1 commit