13 Nov, 2012

1 commit

  • Separate patches from Marek Szyprowski :

    Commit e9da6e9905e639b0 ("ARM: dma-mapping: remove custom consistent dma
    region") replaced custom consistent memory handling, so setting
    consistent dma memory size is not longer required. This patch series
    cleans sub-architecture platform code to remove all calls to the
    obsolated init_consistent_dma_size() function and finally removes the
    init_consistent_dma_size() stub itself.

    * cleanups/dma:
    ARM: at91: remove obsoleted init_consistent_dma_size()
    ARM: u300: remove obsoleted init_consistent_dma_size()
    ARM: dma-mapping: remove init_consistent_dma_size() stub
    ARM: shmobile: remove obsoleted init_consistent_dma_size()
    ARM: davinci: remove obsoleted init_consistent_dma_size()
    ARM: samsung: remove obsoleted init_consistent_dma_size()

    Signed-off-by: Arnd Bergmann

    Arnd Bergmann
     

08 Nov, 2012

5 commits

  • There are uncovered cases whether the card refcount introduced by the
    commit a0830dbd isn't properly increased or decreased:
    - OSS PCM and mixer success paths
    - When lookup function gets NULL

    This patch fixes these places.

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

    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Signed-off-by: Kailang Yang
    Cc:
    Signed-off-by: Takashi Iwai

    Kailang Yang
     
  • alc269_toggle_power_output() was only use in ALC269VB. I rename it to
    alc269vb_toggle_power_output().

    Signed-off-by: Kailang Yang
    Cc:
    Signed-off-by: Takashi Iwai

    Kailang Yang
     
  • There are bug reports of a crash with USB-audio devices when PCM
    prepare is performed immediately after the stream is stopped via
    trigger callback. It turned out that the problem is that we don't
    wait until all URBs are killed.

    This patch adds a new function to synchronize the pending stop
    operation on an endpoint, and calls in the prepare callback for
    avoiding the crash above.

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

    Reported-and-tested-by: Artem S. Tashkinov
    Cc: [v3.6]
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • The RayDAT reports the sync status of its inputs in consecutive bit
    positions, so all we do in hdspm_s1_sync_check is to iterate over idx:

    status = hdspm_read(hdspm, HDSPM_RD_STATUS_1);

    lock = (status & (0x1<<private_value:

    HDSPM_SYNC_CHECK("WC SyncCheck", 0),
    HDSPM_SYNC_CHECK("AES SyncCheck", 1),
    HDSPM_SYNC_CHECK("SPDIF SyncCheck", 2),
    HDSPM_SYNC_CHECK("ADAT1 SyncCheck", 3),
    HDSPM_SYNC_CHECK("ADAT2 SyncCheck", 4),
    HDSPM_SYNC_CHECK("ADAT3 SyncCheck", 5),
    HDSPM_SYNC_CHECK("ADAT4 SyncCheck", 6),
    HDSPM_SYNC_CHECK("TCO SyncCheck", 7),
    HDSPM_SYNC_CHECK("SYNC IN SyncCheck", 8),

    The patch corrects the indicated sync flags by passing the proper index
    value to hdspm_s1_sync_check().

    Signed-off-by: Adrian Knoth
    Signed-off-by: Takashi Iwai

    Adrian Knoth
     

07 Nov, 2012

3 commits

  • To parse properly the subwoofer outputs on ASUS G75 laptop with VT1802
    codec, correct the default configurations of speaker pins 0x24 and
    0x33.

    Reported-by: Massimo Del Fedele
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • VT1802 codec provides the invalid connection lists of NID 0x24 and
    0x33 containing the routes to a non-exist widget 0x3e. This confuses
    the auto-parser. Fix it up in the driver by overriding these
    connections.

    Reported-by: Massimo Del Fedele
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • In via_auto_fill_adc_nids(), the parser tries to fill dac_nids[] at
    the point of the current line-out (i). When no valid path is found
    for this output, this results in dac = 0, thus it creates a hole in
    dac_nids[]. This confuses is_empty_dac() and trims the detected DAC
    in later reference.

    This patch fixes the bug by appending DAC properly to dac_nids[] in
    via_auto_fill_adc_nids().

    Reported-by: Massimo Del Fedele
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

06 Nov, 2012

1 commit


05 Nov, 2012

5 commits


04 Nov, 2012

2 commits


31 Oct, 2012

1 commit


30 Oct, 2012

6 commits

  • When disconnect callback is called, each component should wake up
    sleepers and check card->shutdown flag for avoiding the endless sleep
    blocking the proper resource release.

    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • For more strict protection for wild disconnections, a refcount is
    introduced to the card instance, and let it up/down when an object is
    referred via snd_lookup_*() in the open ops.

    The free-after-last-close check is also changed to check this refcount
    instead of the empty list, too.

    Reported-by: Matthieu CASTET
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Similar like the previous commit, cover with chip->shutdown_rwsem
    and chip->shutdown checks.

    Reported-by: Matthieu CASTET
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Replace mutex with rwsem for codec->shutdown protection so that
    concurrent accesses are allowed.

    Also add the protection to snd_usb_autosuspend() and
    snd_usb_autoresume(), too.

    Reported-by: Matthieu CASTET
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Close some races at disconnection of a USB audio device by adding the
    chip->shutdown_mutex and chip->shutdown check at appropriate places.

    The spots to put bandaids are:
    - PCM prepare, hw_params and hw_free
    - where the usb device is accessed for communication or get speed, in
    mixer.c and others; the device speed is now cached in subs->speed
    instead of accessing to chip->dev

    The accesses in PCM open and close don't need the mutex protection
    because these are already handled in the core PCM disconnection code.

    The autosuspend/autoresume codes are still uncovered by this patch
    because of possible mutex deadlocks. They'll be covered by the
    upcoming change to rwsem.

    Also the mixer codes are untouched, too. These will be fixed in
    another patch, too.

    Reported-by: Matthieu CASTET
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Fix races at PCM disconnection:
    - while a PCM device is being opened or closed
    - while the PCM state is being changed without lock in prepare,
    hw_params, hw_free ops

    Reported-by: Matthieu CASTET
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

28 Oct, 2012

3 commits


26 Oct, 2012

3 commits


24 Oct, 2012

1 commit


22 Oct, 2012

1 commit


21 Oct, 2012

2 commits

  • snd_miro_probe is a static function that is only called twice in the file
    that defines it. At each call site, its argument is freed using
    snd_card_free. Thus, there is no need for snd_miro_probe to call
    snd_card_free on its argument on any of its error exit paths.

    Because snd_card_free both reads the fields of its argument and kfrees its
    argments, the results of the second snd_card_free should be unpredictable.

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

    //
    @r@
    identifier f,free,a;
    parameter list[n] ps;
    type T;
    expression e;
    @@

    f(ps,T a,...) {
    ... when any
    when != a = e
    if(...) { ... free(a); ... return ...; }
    ... when any
    }

    @@
    identifier r.f,r.free;
    expression x,a;
    expression list[r.n] xs;
    @@

    * x = f(xs,a,...);
    if (...) { ... free(a); ... return ...; }
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Takashi Iwai

    Julia Lawall
     
  • By some reason, Toshiba laptop doesn't like the EAPD turned up for the
    headphone pin. Add a fix up code to force to turn down EAPD for NID
    0x15.

    Bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=569991

    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

20 Oct, 2012

6 commits