summaryrefslogtreecommitdiffstats
path: root/src/modules/alsa/alsa-source.c
Commit message (Collapse)AuthorAgeFilesLines
* alsa: Fix log output to inform about positive base volumes correctly.Tanu Kaskinen2011-04-041-4/+1
| | | | | This fix was done for _set_port_cb() already, but the first fix didn't fix setup_mixer(). Now that's done too.
* Fix up according to Coding StyleMaarten Bosmans2011-03-111-1/+1
| | | | Only whitespace changes in here
* ratelimit: fix log levels of log suppression messagesLennart Poettering2011-01-311-2/+2
| | | | | | | | | When logging a suppression message do so on the same log level as the suppressed messages. Cherry picked by Colin Guthrie from ec5a7857127a1b3b9c5517c4a70a9b2c8aab35ca with a couple of additional changes due to extra limiting in master that was not present in stable-queue.
* alsa-source: fix enum typesLennart Poettering2010-11-251-2/+2
|
* alsa: Print dB values in addition to percentages in debug messages.Tanu Kaskinen2010-11-191-7/+18
| | | | | | | How about this? There are a couple of bugs in sink_write_volume_cb, by the way. Another patch will be sent once this dB value printing patch is accepted. -- 8< --
* alsa: Take syncronized HW volume infra into use for alsa-sinkJyri Sarha2010-10-161-1/+1
| | | | | | Signed-off-by: Jyri Sarha <jyri.sarha@nokia.com> Reviewed-by: Tanu Kaskinen <tanu.kaskinen@digia.com> Reviewd-by: Colin Guthrie <cguthrie@mandriva.org>
* alsa: make defines for smoother configurationWim Taymans2010-09-091-2/+5
| | | | | | | | | | | | Make new defines for the smoother window size and adjust time constants instead of reusing some unrelated constant. Increase the smoother window size even more because the bigger it is, the better. Since we have a 200ms max update interval and the max smoother history is 64 entries, 10seconds is a good default. Decrease the smoother adjust time to 1 second. The previous value of 4 seconds was too much to adapt quickly after a resume.
* alsa: work around slightly broken _delay implementationsWim Taymans2010-09-091-1/+1
| | | | | | Use snd_pcm_avail_delay() in pa_alsa_safe_delay() so that we can check the delay value against the avail value and patch it up when it looks invalid. Only do this for capture.
* alsa-source: refactor smoother and device startWim Taymans2010-09-071-8/+18
| | | | | | | Move the code to start the capture and the smoother closer together to improve smoother accuracy. Rework things to look more like the alsa sink where the device is started in only one place.
* alsa: increase the smoother windowWim Taymans2010-09-031-2/+2
| | | | | 40ms for the smoother window is too small. Increase the size to 4 seconds, like we do for the sinks.
* alsa-sink/source: Use the "namereg_fail" module argument.Tanu Kaskinen2010-08-301-1/+14
| | | | | | | | | This allows the name registry to mangle the names of auto-detected sinks and sources to be unique, which makes it possible to load multiple identical sound cards using module-udev-detect. At least for now the module argument can only be passed through module-alsa-card.
* alsa: resume smoother after unsuspendWim Taymans2010-08-231-1/+1
| | | | | | The smoother is paused when the device is suspended but never resumed on unsuspend. Pass the paused = FALSE flag to the pa_smoother_reset() call to make it unpause when unsuspending. This patch improves source timings quite a bit.
* alsa: Fix log output to inform about positive base volumes correctly.Tanu Kaskinen2010-05-101-4/+1
| | | | | | | Positive base volume can happen, if the alsa volume range has been limited. For example, in an embedded environment it may be known that the sound device is capable of louder output than what the speakers can handle, so setting the max volume below 0 dB makes sense.
* thread: name all threads so that the names appear in /proc/$PID/task/$TID/commLennart Poettering2010-05-071-1/+1
|
* alsa: don't make use of tsched related variables when tsched is disabledLennart Poettering2010-02-231-11/+17
|
* alsa: ignore volume changes from the hw if we are not on the active consoleLennart Poettering2010-02-091-0/+3
|
* alsa: fix log output when the audio device refuses to give us again the same ↵Lennart Poettering2009-11-201-1/+1
| | | | period settings we had before
* alsa: disable timer-based scheduling inside a VMLennart Poettering2009-11-051-4/+1
| | | | | | | | | | | | | | | In virtual machines sound card clocks and OS scheduling tend to become unreliable, adding various 'uneven' latencies. The adaptive algorithm that handles drop-outs does not handle it this well: in contrast to drop-outs on real machines that are evenly distributed, small and can easily be encountered via the adpative algorithms, drop-outs in VMs tend to happen abruptly, and massively, which is not easy to counter. This patch simply disables timer based scheduling in VMs reverting to classic IO based scheduling. This should help make PA perform better in VMs. https://bugzilla.redhat.com/show_bug.cgi?id=532775
* alsa: disable period event only with tsched=1Lennart Poettering2009-10-061-1/+1
|
* alsa: properly report suspension error codesLennart Poettering2009-09-111-9/+13
|
* alsa: disable tsched for software devices before we configure the buffer ↵Lennart Poettering2009-09-091-5/+0
| | | | metrics so that we don't accidently set a buffer size that is suitable for tsched where we don't use tsched
* alsa: pass SND_PCM_NONBLOCK when opening device during unsuspend, the same ↵Lennart Poettering2009-09-091-1/+1
| | | | way we do it for initial opening
* alsa: rework buffer/period configurationLennart Poettering2009-09-091-21/+24
| | | | | | | | | | | | | - As discussed on alsa-devel it's probably better to initialize the buffer size first, followed by the period size. If that fails try the other way round. If that fails try to configure only buffer size. If that fails try to configure only period size. Finally, try to configure neither. - Don't require integral periods anymore. Both of these changes should help improving compatibility with various weirder sound devices, such as TV cards.
* llvm-clang-analyzer: drop a few unnecessary assignments and other trivial fixesLennart Poettering2009-09-081-2/+1
|
* alsa: by default increase watermarks only on real underruns, don't try to be ↵Lennart Poettering2009-09-011-1/+1
| | | | smart
* alsa: distuingish real underruns from left_to_play=0Lennart Poettering2009-09-011-1/+3
|
* alsa: automatically decrease watermark after a time of stabilityLennart Poettering2009-08-241-34/+111
|
* alsa: increase interval between smoother updates exponentially for alsa ↵Lennart Poettering2009-08-231-2/+18
| | | | sources, following the scheme for sinks
* source: rework volume handlingLennart Poettering2009-08-191-13/+24
| | | | | | | | | | | | | - drop the 'virtual_' prefix from s->virtual_volume since we don't distuingish between reference and real volumes for sources - introduce an accuracy for source volumes: if the hardware can control the volume "close enough" don't necessarily adjust the rest in software unless it is beyond a certain threshold. This should save a little bit of CPU at the expensive of a bit of accuracy in volume handling. - other minor cleanups
* alsa: properly treat ESTRPIPE as system suspendLennart Poettering2009-08-041-0/+3
|
* alsa: throw timing data away after device resumeLennart Poettering2009-07-241-1/+3
|
* alsa: handle correctly if alsa returns us 0 or EAGAIN on snd_pcm_mmap_begin ↵Lennart Poettering2009-07-241-7/+21
| | | | if we didn't call snd_pcm_avail immediately before
* alsa: deal properly with IO functions asking us to write 0 bytesLennart Poettering2009-07-221-1/+7
|
* Merge most of elmarco/rtclock2Lennart Poettering2009-06-221-10/+11
|\ | | | | | | Merge commit 'e4d914c945c13d23b131d7ba75fbdd03cb6d0043'
| * pulse: move pa_rtclock_now in pulsecommonMarc-André Lureau2009-06-201-4/+5
| |
| * perl -p -i -e 's/pa_rtclock_usec/pa_rtclock_now/g' `find . -name '*.[ch]'`Marc-André Lureau2009-06-191-6/+6
| |
* | core: get rid of rt sig/timer handling since modern Linux' ppooll() is ↵Lennart Poettering2009-06-191-1/+0
|/ | | | finally fixed for granularity
* alsa: unify alsa log handling and snd_config_update_free_global() handling ↵Lennart Poettering2009-06-181-2/+0
| | | | in one place
* alsa: when creating alsa sinks/sources include mapping name in device name ↵Lennart Poettering2009-06-181-3/+7
| | | | to allow profiles mit multiple sinks or multiple sources
* alsa: rework mixer logicLennart Poettering2009-06-171-259/+217
| | | | | | | | | | | | Completely rework mixer logic. This now allows controlling a full set of elements from a single sink's volume slider/mute button. This also introduces sink and source "ports" that can be used to choose different input or output ports with the UI. (i.e. "mic"/"line-in" or "speaker"/"headphones". The mixer paths and device maps are now configered in external configuration files and can be tweaked as necessary.
* core: make sure soft mute status stays in sync with hw mute statusLennart Poettering2009-06-081-1/+1
| | | | | | This should close rhbz #494851, mandriva bz #51234. Probably the same as our own #572, launchpad #352732.
* alsa: monitor device reservation status and resume automatically when device ↵Lennart Poettering2009-06-051-3/+62
| | | | becomes unused
* core: add a suspend cause flags fieldLennart Poettering2009-06-051-1/+1
|
* modules: add {sink|source|card}_properties argument to all modulesLennart Poettering2009-05-281-0/+6
|
* alsa: include mixer name in sink/source propertiesLennart Poettering2009-05-121-1/+7
|
* core: introduce pa_{sink,source}_set_fixed_latency()Lennart Poettering2009-05-081-2/+2
| | | | | This allows us to forward the fixed latency directly from the sink to the monitor source withut having to wait for pa_sink_put().
* alsa: don't hit an assert when invalid module arguments are passedLennart Poettering2009-05-011-1/+2
|
* alsa: properly convert return values of snd_strerror() to utf8Lennart Poettering2009-04-191-12/+12
|
* alsa: include the alsa mixer control that is used in the property listLennart Poettering2009-04-131-1/+1
|
* alsa: store mixer controls to use in profile dataLennart Poettering2009-04-131-1/+1
| | | | | This allows us to easily use different mixer controls for analog and spdif output.