09 Jun, 2015

1 commit

  • ASoC: Updates for v4.2

    The big thing this release has been Liam's addition of topology support
    to the core. We've also seen quite a bit of driver work and the
    continuation of Lars' refactoring for component support.

    - Support for loading ASoC topology maps from firmware, intended to be
    used to allow self-describing DSP firmware images to be built which
    can map controls added by the DSP to userspace without the kernel
    needing to know about individual DSP firmwares.
    - Lots of refactoring to avoid direct access to snd_soc_codec where
    it's not needed supporting future refactoring.
    - Big refactoring and cleanup serieses for the Wolfson ADSP and TI
    TAS2552 drivers.
    - Support for TI TAS571x power amplifiers.
    - Support for Qualcomm APQ8016 and ZTE ZX296702 SoCs.
    - Support for x86 systems with RT5650 and Qualcomm Storm.

    Takashi Iwai
     

25 May, 2015

1 commit

  • Allow for the desc field to be pre-filled when adding gpios to a jack.
    This allows drivers to get the gpios and decide if they should be added
    to the list or not. Specifically this will allow the gpio jack driver
    to add gpios based on device property specifications.

    Signed-off-by: Dylan Reid
    Signed-off-by: Mark Brown

    Dylan Reid
     

28 Apr, 2015

2 commits


05 Mar, 2015

1 commit

  • Jacks are typically card level elements, but are currently registered with a
    CODEC. When it was originally introduced snd_soc_jack_new() took a
    snd_soc_card as its parameter, but at that time DAPM was only implemented at
    the CODEC level and there was only one CODEC per card. This made it clear
    which CODEC to use for the jack DAPM operations. But the multi-component
    patchset added support for having multiple CODECs per card and with it the
    API was updated to register jacks with a specific CODEC instance instead.
    Subsequently DAPM support at the card level has been introduced, but the
    snd_soc_jack_new() API has so remained unchanged.

    This leaves us with the issue that the DAPM pins that are managed by the
    jack detection logic usually are part of the card DAPM context but are
    accessed through a CODEC DAPM context. Currently this works fine, but might
    break in the future if we take a more hierarchical approach to DAPM
    contexts.

    Furthermore with componentization progressing systems that do not register
    a snd_soc_codec might appear, while these system may still want to able to
    register a jack.

    This patch addresses these issues by adding a new function called
    snd_soc_card_jack_new() that can be used to register jacks with the card
    rather than a CODEC.

    This new function is mostly identical to snd_soc_jack_new() except that it
    additionally allows to directly specify the DAPM pins associated with the
    jack. This was done since most users of snd_soc_jack_new() typically call
    snd_soc_jack_add_pins() right after it, which is not necessary with the new
    API and allows to reduce the amount of boiler plate code.

    The old snd_soc_jack_new() is re-implemented as a wrapper around
    snd_soc_card_jack_new().

    Signed-off-by: Lars-Peter Clausen
    Signed-off-by: Mark Brown

    Lars-Peter Clausen
     

08 Dec, 2014

1 commit


18 Nov, 2014

1 commit


23 Oct, 2014

1 commit

  • Add the new flags argument to calls of (devm_)gpiod_get*() and
    remove any direction setting code afterwards.

    Currently both forms (with or without the flags argument)
    are valid thanks to transitional macros in
    . These macros will be removed once
    all consumers are updated and the flags argument will become
    compulsary.

    Signed-off-by: Alexandre Courbot
    Signed-off-by: Mark Brown

    Alexandre Courbot
     

23 Jul, 2014

1 commit

  • Both the snd_soc_codec and snd_soc_platform struct do have a pointer to the
    parent card and both handle this pointer in mostly the same way. This patch
    moves the card field to the component level which will allow further code
    consolidation between platforms and CODECS.

    Since there are only a handful of users of the snd_soc_codec struct's card field
    (and none of the snd_soc_platform's) these are update in this patch as well,
    which allows it to be removed from the snd_soc_codec struct.

    Signed-off-by: Lars-Peter Clausen
    Signed-off-by: Mark Brown

    Lars-Peter Clausen
     

26 May, 2014

2 commits

  • Allow jack GPIO pins be defined also using GPIO descriptor-based interface
    in addition to legacy GPIO numbers. This is done by adding two new fields to
    struct snd_soc_jack_gpio: idx and gpiod_dev.

    Legacy GPIO numbers are used only when GPIO consumer device gpiod_dev is
    NULL and otherwise idx is the descriptor index within the GPIO consumer
    device.

    New function snd_soc_jack_add_gpiods() is added for typical cases where all
    GPIO descriptor jack pins belong to same GPIO consumer device. For other
    cases the caller must set the gpiod_dev in struct snd_soc_jack_gpio before
    calling snd_soc_jack_add_gpios().

    Signed-off-by: Jarkko Nikula
    Signed-off-by: Mark Brown

    Jarkko Nikula
     
  • This patch does basic GPIO descriptor conversion to soc-jack. Even the GPIOs
    are still passed and requested using legacy GPIO numbers the driver
    internals are converted to use GPIO descriptor API.

    Motivation for this is to prepare soc-jack so that it will allow registering
    jack GPIO pins using both GPIO descriptors and legacy GPIO numbers.

    Signed-off-by: Jarkko Nikula
    Signed-off-by: Mark Brown

    Jarkko Nikula
     

24 Feb, 2014

2 commits


22 Oct, 2013

1 commit


27 Aug, 2013

1 commit


19 Jul, 2013

1 commit

  • The accessory detect debounce work is not performance sensitive so let
    the scheduler run it wherever is most efficient rather than in a per CPU
    workqueue by using the system power efficient workqueue.

    Signed-off-by: Mark Brown
    Acked-by: Viresh Kumar

    Mark Brown
     

02 Dec, 2012

1 commit


21 Nov, 2012

1 commit

  • Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
    or none and message types e.g. pr_debug or dev_dbg.

    Make sure all ASoC core messages use the same "ASoC" prefix and
    convert any component device specific messages to use dev_dbg
    instead of pr_debug.

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

    Liam Girdwood
     

22 Oct, 2012

1 commit


09 Oct, 2012

1 commit


05 Sep, 2012

1 commit


14 Aug, 2012

1 commit


04 Aug, 2012

1 commit

  • Now that DAPM is very cheap for most updates we've no need to avoid trying
    to run it so always notify even if we don't think there are any changes.
    This avoids potential issues with bootstrapping state like the pin state
    or other notifiers when there's nothing in the jack.

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

    Mark Brown
     

01 Apr, 2012

1 commit

  • Currently operations on jack reporting take the CODEC mutex both to protect
    the current jack status and also to protect the DAPM run which is triggered
    on status updates. Since the addition of a DAPM-specific lock we no longer
    need to worry about locking DAPM as it has its own finer grained lock so
    create a per jack lock to take care of the jack status.

    This is both cleaner where the jack isn't specifically associated with a
    CODEC and clearer as it's much more obvious what the lock is protecting.

    Signed-off-by: Mark Brown

    Mark Brown
     

21 Dec, 2011

1 commit


01 Nov, 2011

1 commit


06 Oct, 2011

1 commit


06 Sep, 2011

1 commit

  • We need to report the entire jack state to the core jack code, not just
    the bits that were being updated by the caller, otherwise the status
    reported by other detection methods will be omitted from the state seen
    by userspace.

    Signed-off-by: Mark Brown
    Acked-by: Liam Girdwood
    Cc: stable@kernel.org

    Mark Brown
     

15 Aug, 2011

1 commit


19 Apr, 2011

1 commit


03 Apr, 2011

1 commit


30 Mar, 2011

1 commit


24 Feb, 2011

1 commit


19 Feb, 2011

1 commit


11 Feb, 2011

1 commit

  • It is safe to use sleeping gpio in snd_soc_jack_gpio_detect as it is not
    called from interrupt context. This avoids WARN_ON from __gpio_get_value
    if sleeping gpio is registered for jack.

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

    Jarkko Nikula
     

10 Feb, 2011

1 commit


06 Dec, 2010

1 commit

  • As jack detection can trigger DAPM and the latency in debouncing can create
    confusing windows in operation provide some trace events which will hopefully
    help in diagnostics. The soc-jack core traces all reports that it gets and
    the resulting notifications to upper layers. An event for jack IRQs is also
    provided for instrumentation of debounce, and used in the GPIO jack code.

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

    Mark Brown
     

22 Nov, 2010

1 commit


15 Nov, 2010

1 commit

  • If the device associated with a GPIO jack is wakeup capable then disable
    suspend while we're debouncing the jack so that we skip suspends that race
    with the jack.

    Note that currently the GPIO based jack has a CODEC associated with it
    which we're using right now. These jacks should be reparented against the
    card itself and this code adjusted.

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

    Mark Brown
     

06 Nov, 2010

1 commit

  • Decoupling Dynamic Audio Power Management (DAPM) from codec devices is
    required when developing ASoC further. Such as for other ASoC components to
    have DAPM widgets or when extending DAPM to handle cross-device paths.

    This patch decouples DAPM related variables from struct snd_soc_codec and
    moves them to new struct snd_soc_dapm_context that is used to encapsulate
    DAPM context of a device. ASoC core and API of DAPM functions are modified
    to use DAPM context instead of codec.

    This patch does not change current functionality and a large part of changes
    come because of structure and internal API changes.

    Core implementation is from Liam Girdwood with some
    minor core changes, codecs and machine driver conversions from
    Jarkko Nikula .

    Signed-off-by: Liam Girdwood
    Signed-off-by: Jarkko Nikula
    Cc: Nicolas Ferre
    Cc: Manuel Lauss
    Cc: Mike Frysinger
    Cc: Cliff Cai
    Cc: Kevin Hilman
    Cc: Ryan Mallon
    Cc: Timur Tabi
    Cc: Sascha Hauer
    Cc: Lars-Peter Clausen
    Cc: Arnaud Patard (Rtp)
    Cc: Wan ZongShun
    Cc: Eric Miao
    Cc: Jassi Brar
    Cc: Daniel Gloeckner
    Cc: Kuninori Morimoto
    Signed-off-by: Mark Brown

    Liam Girdwood