27 Sep, 2011

1 commit

  • There are certain devices that are reportedly so slow that they need
    more than 100 ms to handle control transfers. Therefore, increase the
    timeout in mixer(_quirks).c to 1000 ms.

    The timeout parameter of snd_usb_ctl_msg() is now constant, so we can
    drop it.

    Reported-by: Felipe Balbi
    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai

    Clemens Ladisch
     

14 Sep, 2011

1 commit


12 Sep, 2011

1 commit

  • Existing code only updates the audio delay when URBs were
    submitted/retired. This can introduce an uncertainty of 8ms
    on the number of samples played out with the default settings,
    and a lot more when URBs convey more packets to reduce the
    interrupt rate and power consumption.

    This patch relies on the USB frame counter to reduce the
    uncertainty to less than 2ms worst-case. The delay information
    essentially becomes independent of the URB size and number of
    packets. This should help applications like PulseAudio which
    require accurate audio timing. Clemens Ladisch reported
    a decrease of mplayer's A-V difference from nrpacks down to at
    most 1ms.

    Thanks to Clemens for also pointing out that the implementation
    of frame counters varies between different HCDs. Only the
    8 lowest-bits are used to estimate the delay.

    Signed-off-by: Pierre-Louis Bossart
    [clemens: changed debug code]
    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai

    Pierre-Louis Bossart
     

11 Mar, 2011

1 commit

  • Devices are autosuspended if no pcm nor midi channel is open
    Mixer devices may be opened. This way they are active when
    in use to play or record sound, but can be suspended while
    users have a mixer application running.

    [Small clean-ups using static inline by tiwai]

    Signed-off-by: Oliver Neukum
    Signed-off-by: Takashi Iwai

    Oliver Neukum
     

23 Feb, 2011

1 commit

  • When a USB audio device is disconnected, snd_usb_audio_disconnect()
    kills all audio URBs. At the same time, the application, after being
    notified of the disconnection, might close the device, in which case
    ALSA calls the .hw_free callback, which should free the URBs too.

    Commit de1b8b93a0ba "[ALSA] Fix hang-up at disconnection of usb-audio"
    prevented snd_usb_hw_free() from freeing the URBs to avoid a hang that
    resulted from this race, but this introduced another race because the
    URB callbacks could now be executed after snd_usb_hw_free() has
    returned, and try to access already freed data.

    Fix the first race by introducing a mutex to serialize the disconnect
    callback and all PCM callbacks that manage URBs (hw_free and hw_params).

    Reported-and-tested-by: Pierre-Louis Bossart
    Cc:
    [CL: also serialize hw_params callback]
    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

01 Nov, 2010

1 commit


27 Oct, 2010

1 commit

  • There are two USB Audio Class specifications (v1 and v2), but neither of
    them clearly defines the feedback format for high-speed UAC v1 devices.
    Add to this whatever the Creative and M-Audio firmware writers have been
    smoking, and it becomes impossible to predict the exact feedback format
    used by a particular device.

    Therefore, automatically detect the feedback format by looking at the
    magnitude of the first received feedback value.

    Also, this allows us to get rid of some special cases for E-Mu devices.

    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai

    Clemens Ladisch
     

04 Sep, 2010

2 commits


18 Aug, 2010

1 commit


14 Aug, 2010

1 commit

  • This is V2 of the patch, after feedback from Clemens and Daniel.

    This patch adds SuperSpeed support to the USB drivers under sound/. It adds
    tests for USB_SPEED_SUPER to the appropriate places that check for the USB
    speed.

    This patch has been tested with our SS USB3 device emulating a set of Yamaha
    speakers and a Logitech microphone, but with the descriptors modified to add
    USB3 support. It has also been tested with the real speakers and microphone,
    to make sure that USB2 devices still work.

    Signed-off-by: Paul Zimmerman
    Cc: Clemens Ladisch
    Cc: Daniel Mack
    Cc: Greg Kroah-Hartman
    Signed-off-by: Takashi Iwai

    Paul Zimmerman
     

13 Jul, 2010

1 commit


01 Jun, 2010

1 commit

  • Audio devices which comply to the UAC2 standard can export complex clock
    topologies in its descriptors and set up links between them.

    The entities that are defined are

    - clock sources, which define the end-leafs.
    - clock selectors, which act as switch to select one out of many
    possible clocks sources.
    - clock multipliers, which have an input clock source, and act as clock
    source again. They can be used to derive one clock from another.

    All sample rate changes, clock validity queries and the like must go to
    clock source elements, while clock selectors and multipliers can be used
    as terminal clock source.

    The following patch adds a parser for these elements and functions to
    iterate over the tree and find the leaf nodes (clock sources).

    The samplerate set functions were moved to the new clock.c file.

    Signed-off-by: Daniel Mack
    Signed-off-by: Takashi Iwai

    Daniel Mack
     

27 May, 2010

1 commit


29 Mar, 2010

1 commit


12 Mar, 2010

1 commit

  • - Split the audio.h file in two to clearly denote the differences
    between the standards.
    - Add many more defines to audio-v2.h. Most of them are not currently
    used.
    - Replaced a magic value with a proper define

    Signed-off-by: Daniel Mack
    Acked-by: Greg Kroah-Hartman
    Cc: Clemens Ladisch
    Signed-off-by: Takashi Iwai

    Daniel Mack
     

05 Mar, 2010

4 commits