Home
last modified time | relevance | path

Searched full:pcm (Results 1 – 25 of 1252) sorted by relevance

12345678910>>...51

/linux/sound/soc/
H A Dsoc-generic-dmaengine-pcm.c10 #include <sound/pcm.h>
28 static struct device *dmaengine_dma_dev(struct dmaengine_pcm *pcm, in dmaengine_dma_dev() argument
31 if (!pcm->chan[substream->stream]) in dmaengine_dma_dev()
34 return pcm->chan[substream->stream]->device->dev; in dmaengine_dma_dev()
39 * @substream: PCM substream
80 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); in dmaengine_pcm_hw_params() local
85 if (!pcm->config->prepare_slave_config) in dmaengine_pcm_hw_params()
90 ret = pcm->config->prepare_slave_config(substream, params, &slave_config); in dmaengine_pcm_hw_params()
102 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); in dmaengine_pcm_set_runtime_hwparams() local
103 struct device *dma_dev = dmaengine_dma_dev(pcm, substrea in dmaengine_pcm_set_runtime_hwparams()
151 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); dmaengine_pcm_open() local
179 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); dmaengine_pcm_compat_request_channel() local
222 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); dmaengine_pcm_new() local
282 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); dmaengine_pcm_pointer() local
296 struct dmaengine_pcm *pcm = soc_component_to_pcm(component); dmaengine_copy() local
349 dmaengine_pcm_request_chan_of(struct dmaengine_pcm * pcm,struct device * dev,const struct snd_dmaengine_pcm_config * config) dmaengine_pcm_request_chan_of() argument
402 dmaengine_pcm_release_chan(struct dmaengine_pcm * pcm) dmaengine_pcm_release_chan() argument
429 struct dmaengine_pcm *pcm; snd_dmaengine_pcm_register() local
483 struct dmaengine_pcm *pcm; snd_dmaengine_pcm_unregister() local
[all...]
/linux/sound/core/
H A Dpcm.c3 * Digital Audio (PCM) abstract layer
16 #include <sound/pcm.h>
24 MODULE_DESCRIPTION("Midlevel PCM code for ALSA.");
33 static int snd_pcm_free(struct snd_pcm *pcm);
40 struct snd_pcm *pcm; in snd_pcm_get() local
42 list_for_each_entry(pcm, &snd_pcm_devices, list) { in snd_pcm_get()
43 if (pcm->card == card && pcm->device == device) in snd_pcm_get()
44 return pcm; in snd_pcm_get()
51 struct snd_pcm *pcm; in snd_pcm_next() local
53 list_for_each_entry(pcm, &snd_pcm_devices, list) { in snd_pcm_next()
[all …]
H A Dpcm_dmaengine.c7 * imx-pcm-dma-mx2.c, Copyright 2009 Sascha Hauer <s.hauer@pengutronix.de>
8 * mxs-pcm.c, Copyright (C) 2011 Freescale Semiconductor, Inc.
9 * ep93xx-pcm.c, Copyright (C) 2006 Lennert Buytenhek <buytenh@wantstofly.org>
16 #include <sound/pcm.h>
45 * @substream: PCM substream
50 * and hw_params in a dmaengine based PCM driver implementation.
92 * @substream: PCM substream
178 * snd_dmaengine_pcm_trigger - dmaengine based PCM trigger implementation
179 * @substream: PCM substream
182 * This function can be used as the PCM trigger callback for dmaengine based PCM
[all …]
H A Dpcm_memory.c3 * Digital Audio (PCM) abstract layer
14 #include <sound/pcm.h>
21 MODULE_PARM_DESC(preallocate_dma, "Preallocate DMA memory when the PCM devices are initialized.");
102 struct snd_card *card = substream->pcm->card; in preallocate_pcm_pages()
117 substream->pcm->card->number, substream->pcm->device, in preallocate_pcm_pages()
119 substream->pcm->name, orig_size); in preallocate_pcm_pages()
125 * @substream: the pcm substream instance
131 do_free_pages(substream->pcm->card, &substream->dma_buffer); in snd_pcm_lib_preallocate_free()
135 * snd_pcm_lib_preallocate_free_for_all - release all pre-allocated buffers on the pcm
136 * @pcm: the pcm instance
[all …]
/linux/sound/soc/samsung/
H A Dpcm.c3 // ALSA SoC Audio Layer - S3C PCM-Controller driver
20 #include "pcm.h"
106 * struct s3c_pcm_info - S3C PCM Controller information
112 * @pclk: the PCLK_PCM (pcm) clock pointer
154 static void s3c_pcm_snd_txctrl(struct s3c_pcm_info *pcm, int on) in s3c_pcm_snd_txctrl() argument
156 void __iomem *regs = pcm->regs; in s3c_pcm_snd_txctrl()
176 if (!pcm->idleclk) in s3c_pcm_snd_txctrl()
185 static void s3c_pcm_snd_rxctrl(struct s3c_pcm_info *pcm, int on) in s3c_pcm_snd_rxctrl() argument
187 void __iomem *regs = pcm->regs; in s3c_pcm_snd_rxctrl()
207 if (!pcm->idleclk) in s3c_pcm_snd_rxctrl()
[all …]
/linux/sound/pci/ac97/
H A Dac97_pcm.c18 #include <sound/pcm.h>
26 * PCM support
144 static unsigned char get_slot_reg(struct ac97_pcm *pcm, unsigned short cidx, in get_slot_reg() argument
151 if (pcm->spdif) in get_slot_reg()
153 if (pcm->stream == SNDRV_PCM_STREAM_PLAYBACK) in get_slot_reg()
154 return rate_reg_tables[dbl][pcm->r[dbl].rate_table[cidx]][slot - 3]; in get_slot_reg()
393 static unsigned int get_rates(struct ac97_pcm *pcm, unsigned int cidx, unsigned short slots, int db… in get_rates() argument
402 reg = get_slot_reg(pcm, cidx, i, dbl); in get_rates()
411 rates &= pcm->r[dbl].codec[cidx]->rates[idx]; in get_rates()
420 * snd_ac97_pcm_assign - assign AC97 slots to given PCM streams
[all …]
/linux/Documentation/sound/designs/
H A Doss-emulation.rst12 The OSS emulation for PCM, mixer and sequencer devices is implemented
13 as add-on kernel modules, snd-pcm-oss, snd-mixer-oss and snd-seq-oss.
14 When you need to access the OSS PCM, mixer or sequencer devices, the
48 PCM:
73 As seen above, PCM and MIDI may have two devices. Usually, the first
74 PCM device (``hw:0,0`` in ALSA) is mapped to /dev/dsp and the secondary
79 snd-pcm-oss and snd-rawmidi. In the case of PCM, the following
80 options are available for snd-pcm-oss:
83 PCM device number assigned to /dev/dspX
86 PCM device number assigned to /dev/adspX
[all …]
H A Dtracepoints.rst8 Tracepoints in ALSA PCM core
11 ALSA PCM core registers ``snd_pcm`` subsystem to kernel tracepoint system.
12 This subsystem includes two categories of tracepoints; for state of PCM buffer
13 and for processing of PCM hardware parameters. These tracepoints are available
18 Tracepoints for state of PCM buffer
24 Tracepoints for processing of PCM hardware parameters
30 In a design of ALSA PCM core, data transmission is abstracted as PCM substream.
31 Applications manage PCM substream to maintain data transmission for PCM frames.
32 Before starting the data transmission, applications need to configure PCM
33 substream. In this procedure, PCM hardware parameters are decided by
[all …]
H A Dprocfile.rst42 pcm
43 Lists the currently available PCM devices in format of
66 When PCM devices are available on this card, you can see directories
67 like pcm0p or pcm1c. They hold the PCM information for each PCM
68 stream. The number after ``pcm`` is the PCM device number from 0, and
85 PCM Proc Files
88 ``card*/pcm*/info``
89 The general information of this PCM device: card #, device #,
92 ``card*/pcm*/xrun_debug``
96 invalid PCM position debug/check of ALSA PCM middle layer.
[all …]
/linux/sound/soc/codecs/
H A Dhdac_hdmi.c148 struct hdac_hdmi_pcm *pcm; in hdac_hdmi_get_pcm_from_cvt() local
150 list_for_each_entry(pcm, &hdmi->pcm_list, head) { in hdac_hdmi_get_pcm_from_cvt()
151 if (pcm->cvt == cvt) in hdac_hdmi_get_pcm_from_cvt()
152 return pcm; in hdac_hdmi_get_pcm_from_cvt()
158 static void hdac_hdmi_jack_report(struct hdac_hdmi_pcm *pcm, in hdac_hdmi_jack_report() argument
167 * for the first time where same PCM is attached to multiple in hdac_hdmi_jack_report()
170 if (pcm->jack_event == 0) { in hdac_hdmi_jack_report()
172 "jack report for pcm=%d\n", in hdac_hdmi_jack_report()
173 pcm->pcm_id); in hdac_hdmi_jack_report()
174 snd_soc_jack_report(pcm->jack, SND_JACK_AVOUT, in hdac_hdmi_jack_report()
[all …]
H A Dhda.c21 struct hda_pcm *pcm; in hda_codec_create_dais() local
28 pcm = list_first_entry(&codec->pcm_list_head, struct hda_pcm, list); in hda_codec_create_dais()
30 for (i = 0; i < pcm_count; i++, pcm = list_next_entry(pcm, list)) { in hda_codec_create_dais()
34 dev_info(dev, "creating for %s %d\n", pcm->name, i); in hda_codec_create_dais()
36 drvs[i].name = pcm->name; in hda_codec_create_dais()
41 if (!pcm->stream[dir].substreams) { in hda_codec_create_dais()
42 dev_info(dev, "skipping playback dai for %s\n", pcm->name); in hda_codec_create_dais()
47 devm_kasprintf(dev, GFP_KERNEL, "%s %s", pcm->name, in hda_codec_create_dais()
51 stream->channels_min = pcm->stream[dir].channels_min; in hda_codec_create_dais()
52 stream->channels_max = pcm->stream[dir].channels_max; in hda_codec_create_dais()
[all …]
H A Dhda-dai.c16 struct hda_pcm *pcm; in hda_codec_dai_startup() local
21 pcm = container_of(stream_info, struct hda_pcm, stream[substream->stream]); in hda_codec_dai_startup()
23 dev_dbg(dai->dev, "open stream codec: %08x, info: %p, pcm: %p %s substream: %p\n", in hda_codec_dai_startup()
24 codec->core.vendor_id, stream_info, pcm, pcm->name, substream); in hda_codec_dai_startup()
26 snd_hda_codec_pcm_get(pcm); in hda_codec_dai_startup()
31 snd_hda_codec_pcm_put(pcm); in hda_codec_dai_startup()
42 struct hda_pcm *pcm; in hda_codec_dai_shutdown() local
47 pcm = container_of(stream_info, struct hda_pcm, stream[substream->stream]); in hda_codec_dai_shutdown()
49 dev_dbg(dai->dev, "close stream codec: %08x, info: %p, pcm: %p %s substream: %p\n", in hda_codec_dai_shutdown()
50 codec->core.vendor_id, stream_info, pcm, pcm->name, substream); in hda_codec_dai_shutdown()
[all …]
/linux/Documentation/sound/cards/
H A Dsb-live-mixer.rst15 IEC958 (S/PDIF) raw PCM
18 This PCM device (it's the 3rd PCM device (index 2!) and first subdevice
22 to 8 raw PCM devices operating at 48kHz, 16-bit little endian. It would
64 This control is used to attenuate samples from left and right PCM FX-bus
65 accumulators. ALSA uses accumulators 0 and 1 for left and right PCM samples.
66 The result samples are forwarded to the front DAC PCM slots of the AC97 codec.
70 This control is used to attenuate samples from left and right PCM FX-bus
71 accumulators. ALSA uses accumulators 0 and 1 for left and right PCM samples.
77 This control is used to attenuate samples from left and right PCM FX-bus
78 accumulators. ALSA uses accumulators 0 and 1 for left and right PCM samples.
[all …]
H A Daudigy-mixer.rst47 name='PCM Front Playback Volume',index=0
49 This control is used to attenuate samples from left and right front PCM FX-bus
50 accumulators. ALSA uses accumulators 8 and 9 for left and right front PCM
53 name='PCM Surround Playback Volume',index=0
55 This control is used to attenuate samples from left and right surround PCM FX-bus
56 accumulators. ALSA uses accumulators 2 and 3 for left and right surround PCM
60 name='PCM Side Playback Volume',index=0
62 This control is used to attenuate samples from left and right side PCM FX-bus
63 accumulators. ALSA uses accumulators 14 and 15 for left and right side PCM
66 name='PCM Center Playback Volume',index=0
[all …]
/linux/sound/soc/sof/
H A Dipc3-pcm.c49 struct sof_ipc_pcm_params pcm; in sof_ipc3_pcm_hw_params() local
57 memset(&pcm, 0, sizeof(pcm)); in sof_ipc3_pcm_hw_params()
60 pcm.params.buffer.pages = PFN_UP(runtime->dma_bytes); in sof_ipc3_pcm_hw_params()
62 /* set IPC PCM parameters */ in sof_ipc3_pcm_hw_params()
63 pcm.hdr.size = sizeof(pcm); in sof_ipc3_pcm_hw_params()
64 pcm.hdr.cmd = SOF_IPC_GLB_STREAM_MSG | SOF_IPC_STREAM_PCM_PARAMS; in sof_ipc3_pcm_hw_params()
65 pcm.comp_id = spcm->stream[substream->stream].comp_id; in sof_ipc3_pcm_hw_params()
66 pcm.params.hdr.size = sizeof(pcm.params); in sof_ipc3_pcm_hw_params()
67 pcm.params.buffer.phy_addr = spcm->stream[substream->stream].page_table.addr; in sof_ipc3_pcm_hw_params()
68 pcm.params.buffer.size = runtime->dma_bytes; in sof_ipc3_pcm_hw_params()
[all …]
H A Dcompress.c74 /* use the same workqueue-based solution as for PCM, cf. snd_sof_pcm_elapsed */ in snd_sof_compr_fragment_elapsed()
172 struct sof_ipc_pcm_params *pcm; in sof_compr_set_params() local
195 if (sizeof(*pcm) + ext_data_size > sdev->ipc->max_payload_size) in sof_compr_set_params()
198 pcm = kzalloc(sizeof(*pcm) + ext_data_size, GFP_KERNEL); in sof_compr_set_params()
199 if (!pcm) in sof_compr_set_params()
212 pcm->params.buffer.pages = PFN_UP(crtd->dma_bytes); in sof_compr_set_params()
213 pcm->hdr.size = sizeof(*pcm) + ext_data_size; in sof_compr_set_params()
214 pcm->hdr.cmd = SOF_IPC_GLB_STREAM_MSG | SOF_IPC_STREAM_PCM_PARAMS; in sof_compr_set_params()
216 pcm->comp_id = spcm->stream[cstream->direction].comp_id; in sof_compr_set_params()
217 pcm->params.hdr.size = sizeof(pcm->params) + ext_data_size; in sof_compr_set_params()
[all …]
H A Dpcm.c10 // PCM Layer, interface between ALSA and IPC.
42 * sof pcm period elapse work
59 * sof pcm period elapse, this could be called at irq thread context.
78 * when the PCM is done draining or xrun happened, a STOP IPC will in snd_sof_pcm_period_elapsed()
111 dev_err(sdev->dev, "error: failed widget list set up for pcm %d dir %d\n", in sof_pcm_setup_connected_widgets()
112 spcm->pcm.pcm_id, dir); in sof_pcm_setup_connected_widgets()
128 const struct sof_ipc_pcm_ops *pcm_ops = sof_ipc_get_ops(sdev, pcm); in sof_pcm_hw_params()
154 dev_dbg(component->dev, "pcm: hw params stream %d dir %d\n", in sof_pcm_hw_params()
155 spcm->pcm.pcm_id, substream->stream); in sof_pcm_hw_params()
188 /* save pcm hw_params */ in sof_pcm_hw_params()
[all …]
/linux/sound/pci/lola/
H A Dlola_pcm.c14 #include <sound/pcm.h>
24 return &chip->pcm[substream->stream]; in lola_get_pcm()
29 struct lola_pcm *pcm = lola_get_pcm(substream); in lola_get_stream() local
31 return &pcm->streams[idx]; in lola_get_stream()
128 if (s->pcm->card != substream->pcm->card) in lola_sync_wait_for_fifo()
159 if (s->pcm->card != substream->pcm->card) in lola_sync_pause()
213 struct lola_pcm *pcm = lola_get_pcm(substream); in lola_pcm_open() local
226 runtime->hw.channels_max = pcm->num_streams - str->index; in lola_pcm_open()
246 static void lola_cleanup_slave_streams(struct lola_pcm *pcm, in lola_cleanup_slave_streams() argument
250 for (i = str->index + 1; i < pcm->num_streams; i++) { in lola_cleanup_slave_streams()
[all …]
/linux/sound/pci/au88x0/
H A Dau88x0_pcm.c6 * Vortex PCM ALSA driver.
14 #include <sound/pcm.h>
146 if (VORTEX_PCM_TYPE(substream->pcm) != VORTEX_PCM_WT) { in snd_vortex_pcm_open()
148 if (VORTEX_PCM_TYPE(substream->pcm) == VORTEX_PCM_A3D) { in snd_vortex_pcm_open()
152 if (VORTEX_PCM_TYPE(substream->pcm) == VORTEX_PCM_SPDIF) { in snd_vortex_pcm_open()
166 if (VORTEX_PCM_TYPE(substream->pcm) == VORTEX_PCM_ADB in snd_vortex_pcm_open()
167 || VORTEX_PCM_TYPE(substream->pcm) == VORTEX_PCM_I2S) in snd_vortex_pcm_open()
172 VORTEX_PCM_TYPE(substream->pcm) == VORTEX_PCM_ADB) { in snd_vortex_pcm_open()
219 if (VORTEX_PCM_TYPE(substream->pcm) != VORTEX_PCM_WT) { in snd_vortex_pcm_hw_params()
220 int dma, type = VORTEX_PCM_TYPE(substream->pcm); in snd_vortex_pcm_hw_params()
[all …]
/linux/sound/pci/emu10k1/
H A Demupcm.c9 * Routines for control of EMU10K1 chips / PCM routines
1413 struct snd_pcm *pcm; in snd_emu10k1_pcm() local
1417 err = snd_pcm_new(emu->card, "emu10k1", device, 32, 1, &pcm); in snd_emu10k1_pcm()
1421 pcm->private_data = emu; in snd_emu10k1_pcm()
1423 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &snd_emu10k1_playback_ops); in snd_emu10k1_pcm()
1424 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_CAPTURE, &snd_emu10k1_capture_ops); in snd_emu10k1_pcm()
1426 pcm->info_flags = 0; in snd_emu10k1_pcm()
1427 pcm->dev_subclass = SNDRV_PCM_SUBCLASS_GENERIC_MIX; in snd_emu10k1_pcm()
1428 strcpy(pcm->name, "ADC Capture/Standard PCM Playback"); in snd_emu10k1_pcm()
1429 emu->pcm = pcm; in snd_emu10k1_pcm()
[all …]
/linux/sound/soc/mediatek/mt6797/
H A Dmt6797-dai-pcm.c155 {"PCM 1 Playback", NULL, "PCM_1_PB_CH1"},
156 {"PCM 1 Playback", NULL, "PCM_1_PB_CH2"},
157 {"PCM 1 Playback", NULL, "PCM_1_PB_CH4"},
158 {"PCM 2 Playback", NULL, "PCM_2_PB_CH1"},
159 {"PCM 2 Playback", NULL, "PCM_2_PB_CH2"},
160 {"PCM 2 Playback", NULL, "PCM_2_PB_CH4"},
162 {"PCM 1 Playback", NULL, "PCM_1_EN"},
163 {"PCM 2 Playback", NULL, "PCM_2_EN"},
164 {"PCM 1 Capture", NULL, "PCM_1_EN"},
165 {"PCM 2 Capture", NULL, "PCM_2_EN"},
[all …]
/linux/sound/soc/mediatek/mt8183/
H A Dmt8183-dai-pcm.c155 {"PCM 1 Playback", NULL, "PCM_1_PB_CH1"},
156 {"PCM 1 Playback", NULL, "PCM_1_PB_CH2"},
157 {"PCM 1 Playback", NULL, "PCM_1_PB_CH4"},
158 {"PCM 2 Playback", NULL, "PCM_2_PB_CH1"},
159 {"PCM 2 Playback", NULL, "PCM_2_PB_CH2"},
160 {"PCM 2 Playback", NULL, "PCM_2_PB_CH4"},
162 {"PCM 1 Playback", NULL, "PCM_1_EN"},
163 {"PCM 2 Playback", NULL, "PCM_2_EN"},
164 {"PCM 1 Capture", NULL, "PCM_1_EN"},
165 {"PCM 2 Capture", NULL, "PCM_2_EN"},
[all …]
/linux/sound/pci/ctxfi/
H A Dctpcm.c8 * This file contains the definition of the pcm device functions.
17 #include <sound/pcm.h>
114 /* pcm playback operations */
128 if (IEC958 == substream->pcm->device) { in ct_pcm_playback_open()
133 if (FRONT == substream->pcm->device) in ct_pcm_playback_open()
168 if (IEC958 == substream->pcm->device) in ct_pcm_playback_close()
205 if (IEC958 == substream->pcm->device) in ct_pcm_playback_prepare()
212 "Preparing pcm playback failed!!!\n"); in ct_pcm_playback_prepare()
260 /* pcm capture operations */
321 "Preparing pcm capture failed!!!\n"); in ct_pcm_capture_prepare()
[all …]
/linux/sound/firewire/oxfw/
H A Doxfw-pcm.c31 if (!snd_interval_test(c, formation.pcm)) in hw_rule_rate()
63 if (list[count] == formation.pcm) in hw_rule_channels()
67 if (list[j] == formation.pcm) in hw_rule_channels()
71 list[count] = formation.pcm; in hw_rule_channels()
100 hw->channels_min = min(hw->channels_min, formation.pcm); in limit_channels_and_rates()
101 hw->channels_max = max(hw->channels_max, formation.pcm); in limit_channels_and_rates()
162 substream->runtime->hw.channels_min = formation.pcm; in limit_to_current_params()
163 substream->runtime->hw.channels_max = formation.pcm; in limit_to_current_params()
187 // transmission of PCM frames, the available sampling rate is limited in pcm_open()
348 struct snd_pcm_substream *pcm; in pcm_capture_trigger() local
[all …]
/linux/tools/testing/selftests/alsa/
H A Dpcm-test.c3 // kselftest for the ALSA PCM API
9 // every PCM device it can find. This may conflict with other system
129 pcm_config = conf_get_subtree(card_config, "pcm", NULL); in missing_devices()
228 sprintf(key, "pcm.%d.%s", dev, snd_pcm_stream_name(stream)); in find_pcms()
231 ksft_print_msg("skipping pcm %d.%d.%s\n", card, dev, snd_pcm_stream_name(stream)); in find_pcms()
249 sprintf(key, "pcm.%d.%d.%s", dev, subdev, snd_pcm_stream_name(stream)); in find_pcms()
251 ksft_print_msg("skipping pcm %d.%d.%d.%s\n", card, dev, in find_pcms()
353 snprintf(msg, sizeof(msg), "Failed to get pcm handle: %s", snd_strerror(err)); in test_pcm_time()
554 void run_time_tests(struct pcm_data *pcm, enum test_class class, in run_time_tests() argument
574 test_pcm_time(pcm, class, test_name, pcm_cfg); in run_time_tests()
[all …]

12345678910>>...51