- 24 2月, 2015 1 次提交
-
-
由 Nicolin Chen 提交于
The current helper functions, snd_soc_of_parse_audio_simple_widgets() and snd_soc_of_parse_audio_routing(), set dapm_widgets and dapm_routes without caring if they are already set by using build-in widgets and routes in the card driver. So there could be one of them, build-in one or Device Tree one, overrided by the other depending on which one was assigned later. This patch adds an extra pair of dapm_widgets and dapm_routes for DT use only so as to prevent unexpected overriding. Signed-off-by: NNicolin Chen <nicoleotsuka@gmail.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 09 2月, 2015 1 次提交
-
-
由 Pierre-Louis Bossart 提交于
Don't use generic snapshot of trigger_tstamp if low-level driver or hardware can get a more precise value for better audio/system time synchronization. Signed-off-by: NPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 06 2月, 2015 1 次提交
-
-
由 Takashi Iwai 提交于
For assigning sysfs entries for a card device from the driver, introduce a new helper function, snd_card_add_dev_attr(). In this way, we can avoid the possible race between the device registration and the sysfs addition / removal. The driver can pass a new attribute group to add freely. This has to be called before snd_card_register(). Currently, up to two extra groups can be added. More than that, it'll return an error. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 03 2月, 2015 3 次提交
-
-
由 Takashi Iwai 提交于
Instead of calling device_create_file() manually, assign the static attribute group entries at the device registration. This simplifies the error handling and avoids the possible races. Signed-off-by: NTakashi Iwai <tiwai@suse.de> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Takashi Iwai 提交于
Since the device is no longer hidden but embedded into each component, we no longer need snd_get_device(). Let's drop it and relevant codes. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Now that all callers have been replaced with snd_device_register_for_dev(), let's drop the obsolete device registration code and concentrate only on the code handling struct device directly. That said, - remove the old snd_device_register(), - rename snd_device_register_for_dev() with snd_device_register(), - drop superfluous arguments from snd_device_register(), - change snd_unregister_device() to pass the device pointer directly Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 02 2月, 2015 8 次提交
-
-
由 Takashi Iwai 提交于
Like previous patches, this one embeds the struct device into struct snd_compr. As the dev field wasn't used beforehand, it's reused as the new device struct. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Like previous patches, this changes the device management for rawmidi, embedding the struct device into struct snd_rawmidi. The required change is more or less same as hwdep device. The currently unused dev field is reused as the new embedded struct field now. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Like previous patches, at this time we embed the struct device into PCM object. However, this needs a bit more caution: struct snd_pcm doesn't own one device but two, for both playback and capture! Thus not struct snd_pcm but struct snd_pcm_str object contains the device. Along with this change, pcm->dev field is dropped for avoiding confusion. It was meant to point to a non-standard parent. But, since now we can touch each struct device directly, we can manipulate the parent field easily there, too. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Like the previous patch, this one embeds the device object into hwdep object. For a proper object lifecycle, it's freed in the release callback. This also allows us to create sysfs entries via passing to the groups field of the device without explicit function calls. Since each driver can see the device and touch its groups field directly, we don't need to delegate in hwdep core any longer. So, remove the groups field from snd_hwdep, and let the user (in this case only hda_hwdep.c) modify the device groups. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
This patch embeds a struct device for the control device into the card object and avoid the device creation at registration time. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Introduce a new helper function snd_device_initialize() to initialize the device object for sound devices. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Instead of open-coding the search over the control file loop, provide a helper function for the preferred subdevice assigned to the current process. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
This is a preliminary patch for the further work on embedding struct device into each sound device instance. It changes snd_register_device*() helpers to receive the device object directly for skipping creating a device there. Reviewed-by: NJaroslav Kysela <perex@perex.cz> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 29 1月, 2015 4 次提交
-
-
由 Takashi Iwai 提交于
Protect the call with a mutex, as this may be called in parallel (either from the PCM rate change and the clock change). Acked-by: NJaroslav Kysela <perex@perex.cz> Tested-by: NPavel Hofman <pavel.hofman@ivitera.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
Define snd_ak4114_suspend() and snd_ak4114_resume() functions to handle PM properly, stopping and restarting the work at PM. Currently only ice1712/juli.c deals with the PM and ak4114, so fix the calls there appropriately. The same PM functions are defined in ak4113.c, too, although they aren't currently called yet (ice1712/quartet.c may be enhanced to support PM later). Acked-by: NJaroslav Kysela <perex@perex.cz> Tested-by: NPavel Hofman <pavel.hofman@ivitera.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
When ak4114 work calls its callback and the callback invokes ak4114_reinit(), it stalls due to flush_delayed_work(). For avoiding this, control the reentrance by introducing a refcount. Also flush_delayed_work() is replaced with cancel_delayed_work_sync(). The exactly same bug is present in ak4113.c and fixed as well. Reported-by: NPavel Hofman <pavel.hofman@ivitera.com> Acked-by: NJaroslav Kysela <perex@perex.cz> Tested-by: NPavel Hofman <pavel.hofman@ivitera.com> Cc: <stable@vger.kernel.org> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Peter Rosin 提交于
Add helper functions to allow drivers to specify several disjoint ranges for a variable. In particular, there is a codec (PCM512x) that has a hole in its supported range of rates, due to PLL and divider restrictions. This is like snd_pcm_hw_constraint_list(), but for ranges instead of points. Signed-off-by: NPeter Rosin <peda@axentia.se> Reviewed-by: NLars-Peter Clausen <lars@metafoo.de> Reviewed-by: NTakashi Iwai <tiwai@suse.de> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 28 1月, 2015 2 次提交
-
-
由 Takashi Iwai 提交于
Nowadays it's recommended. Replace all in a shot. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Thomas Niederprüm 提交于
make the sta32x driver usable with device tree configs. Code is heavily based on the sta350 driver. Signed-off-by: NThomas Niederprüm <niederp@physik.uni-kl.de> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 27 1月, 2015 1 次提交
-
-
由 Lars-Peter Clausen 提交于
In some cases it is necessary to before additional operations after the device has been initialized and before the device is registered. This can for example be resetting the device. This patch introduces a new function snd_soc_alloc_ac97_codec() which is similar to snd_soc_new_ac97_codec() except that it does not register the device. Any users of snd_soc_alloc_ac97_codec() are responsible for calling device_add() manually. Fixes: 6794f709 ("ASoC: ac97: Drop delayed device registration") Reported-by: NManuel Lauss <manuel.lauss@gmail.com> Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Tested-by: NManuel Lauss <manuel.lauss@gmail.com> Signed-off-by: NMark Brown <broonie@kernel.org> Cc: stable@vger.kernel.org
-
- 26 1月, 2015 3 次提交
-
-
由 Clemens Ladisch 提交于
Queues are used both for scheduling playback events and for assigning timestamps to recorded events, so it is easy to need quite a lot of them, especially on a multi-user system. Additionally, the actual queue objects are allocated dynamically, so it does not really make sense to have a low limit. Increase it to something still sane. Signed-off-by: NClemens Ladisch <clemens@ladisch.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Clemens Ladisch 提交于
Signed-off-by: NClemens Ladisch <clemens@ladisch.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Clemens Ladisch 提交于
Signed-off-by: NClemens Ladisch <clemens@ladisch.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 15 1月, 2015 2 次提交
-
-
由 Lars-Peter Clausen 提交于
There are no more users of this field left so it can finally be removed. New users should use snd_soc_dapm_to_codec(w->dapm); The reason why it is removed is because it doesn't fit to well anymore in the componentized ASoC hierarchy, where DAPM works on the snd_soc_component level. And the alternative of snd_soc_dapm_to_codec(w->dapm) typically generates the same amount of code, so there is really no reason to keep it. For automatic conversion the following coccinelle semantic patch can be used: // <smpl> @@ struct snd_soc_dapm_widget *w; @@ -w->codec +snd_soc_dapm_to_codec(w->dapm) // </smpl> Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Jyri Sarha 提交于
Call clk_prepare_enable() and clk_disable_unprepare() for cpu dai clock and codec dai clock in dai statup and shutdown callbacks. This to make sure the related clock are enabled when the audio device is used. Signed-off-by: NJyri Sarha <jsarha@ti.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 13 1月, 2015 1 次提交
-
-
由 Qais Yousef 提交于
Fixes the following compilation error: include/sound/compress_driver.h: In function ‘snd_compr_drain_notify’: include/sound/compress_driver.h:177:2: error: implicit declaration of function ‘snd_BUG_ON’ [-Werror=implicit-function-declaration] if (snd_BUG_ON(!stream)) snd_BUG_ON() is defined in sound/core.h but the file is not included explicitly, so include it. Signed-off-by: NQais Yousef <qais.yousef@imgtec.com> Acked-by: NVinod Koul <vinod.koul@intel.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 12 1月, 2015 1 次提交
-
-
由 Kuninori Morimoto 提交于
L/R channel will be switched if under/over flow error happen on Renesas R-Car sound device by the HW bugs. Then, HW restart is required for salvage. This patch add salvage support for SRC. Signed-off-by: NKuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 09 1月, 2015 1 次提交
-
-
由 Oder Chiou 提交于
The patch adds the MICBIAS VDD setting in the platform data. It can be set to 1V8 or 3V3 in the MICBIAS VDD. Signed-off-by: NOder Chiou <oder_chiou@realtek.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 08 1月, 2015 1 次提交
-
-
由 Lars-Peter Clausen 提交于
For some setups it is necessary to change the DAI link format at runtime. This patch factors out the code that does the initial static DAI link format configuration into a separate helper function which can be used board drivers as well. This allows board drivers that have to change the DAI link format at runtime to reuse it instead of having to manually change the format on all DAIs. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 04 1月, 2015 1 次提交
-
-
由 Lars-Peter Clausen 提交于
Remove function declarations for functions that don't have a matching implementation. For snd_pcm_build_linear_format the implementation was removed in 64d27f96 ("[ALSA] Support 3-bytes 24bit format in PCM OSS emulation"). All the others never had one (as far as git history goes). Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 02 1月, 2015 7 次提交
-
-
由 Lars-Peter Clausen 提交于
The various PCM and hwdep allocation functions in this driver take a pointer to a pointer of a PCM/hwdep where if this parameter is provided the newly allocated object is stored. All callers pass NULL though, so remove the parameter. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
Most callers of snd_wss_pcm(), snd_wss_timer() and snd_cs4236_pcm() pass NULL as the last parameter, some callers pass a pointer but never use it after the function has been called and only a few callers pass a pointer and actually use it. The later is only the case for snd_wss_pcm() for snd_cs4236_pcm() and it is possible to get the same PCM object by accessing the pcm field of the snd_wss struct that was passed as the first parameter. This function removes the last parameters from the functions mentioned above and updates the callers which used it to use chip->pcm instead. This allows us to slightly simplify the functions since they don't have to check and set the last parameter anymore which makes the code slightly shorter and cleaner. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
All callers of snd_sb16dsp_pcm() always pass the pcm field of the first parameter as the last parameter. Simplify the function by moving this inside the function itself. This makes the code a bit shorter and cleaner. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
snd_sb8dsp_pcm() and snd_sb8dsp_midi() take a pointer to a pointer of a PCM/MIDI where if this parameter is provided the newly allocated object is stored. All callers pass NULL though, so remove the parameter. This makes the code a bit cleaner and shorter. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
snd_gf1_pcm_new() and snd_gf1_rawmidi_new() take a pointer to a pointer of a PCM/MIDI where if this parameter is provided the newly allocated object is stored. All callers pass NULL though, so remove the parameter. This makes the code a bit cleaner and shorter. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
snd_es1688_pcm() takes a pointer to a pointer of a PCM where if this parameter is provided the newly allocated PCM is stored. This PCM is also available from the pcm field of the snd_es1688 struct that got passed to the same function. This patch updates all callers which passed a pointer to use that field instead and then removes the parameter from the function. This makes the code a bit shorter and cleaner. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Lars-Peter Clausen 提交于
snd_ad1816a_pcm() and snd_ad1816a_timer() take a pointer to a pointer of a PCM/timer where if this parameter is provided the newly allocated object is stored. All callers pass NULL though, so remove the parameter. This makes the code a bit cleaner and shorter. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 01 1月, 2015 1 次提交
-
-
由 Libin Yang 提交于
Add SNDRV_PCM_TRIGGER_DRAIN trigger for pcm drain. Some audio devices require notification of drain events in order to properly drain and shutdown an audio stream. Signed-off-by: NLibin Yang <libin.yang@intel.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 30 12月, 2014 1 次提交
-
-
由 Lars-Peter Clausen 提交于
__fls has the same semantics as ld2, so there is no need to re-implement it. Furthermore a lot of architectures have custom implementations of __fls that are able to use special hardware instructions to compute the result. This makes the code slightly shorter and faster. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-