Home
last modified time | relevance | path

Searched refs:fmt (Results 1 – 25 of 393) sorted by relevance

12345678910>>...16

/sound/usb/
Dclock.c150 const struct audioformat *fmt, in uac_clock_source_is_valid_quirk() argument
159 cs_desc = snd_usb_find_clock_source(chip, source_id, fmt->protocol); in uac_clock_source_is_valid_quirk()
163 if (fmt->protocol == UAC_VERSION_2) { in uac_clock_source_is_valid_quirk()
171 if (fmt->nr_rates == 1 && in uac_clock_source_is_valid_quirk()
172 (fmt->clock & 0xff) == cs_desc->v2.bClockID && in uac_clock_source_is_valid_quirk()
212 const struct audioformat *fmt, in uac_clock_source_is_valid() argument
221 cs_desc = snd_usb_find_clock_source(chip, source_id, fmt->protocol); in uac_clock_source_is_valid()
225 if (fmt->protocol == UAC_VERSION_3) in uac_clock_source_is_valid()
251 return uac_clock_source_is_valid_quirk(chip, fmt, source_id); in uac_clock_source_is_valid()
255 const struct audioformat *fmt, int entity_id, in __uac_clock_find_source() argument
[all …]
Dimplicit.c83 struct audioformat *fmt, in add_implicit_fb_sync_ep() argument
96 fmt->sync_ep = ep; in add_implicit_fb_sync_ep()
97 fmt->sync_iface = ifnum; in add_implicit_fb_sync_ep()
98 fmt->sync_altsetting = alts->desc.bAlternateSetting; in add_implicit_fb_sync_ep()
99 fmt->sync_ep_idx = ep_idx; in add_implicit_fb_sync_ep()
100 fmt->implicit_fb = 1; in add_implicit_fb_sync_ep()
103 fmt->iface, fmt->altsetting, in add_implicit_fb_sync_ep()
105 fmt->sync_ep, fmt->sync_iface, fmt->sync_altsetting); in add_implicit_fb_sync_ep()
111 struct audioformat *fmt, in add_generic_uac2_implicit_fb() argument
131 return add_implicit_fb_sync_ep(chip, fmt, epd->bEndpointAddress, 0, in add_generic_uac2_implicit_fb()
[all …]
Dformat.c41 struct uac_format_type_i_discrete_descriptor *fmt = _fmt; in parse_audio_format_i_type() local
48 sample_width = fmt->bBitResolution; in parse_audio_format_i_type()
49 sample_bytes = fmt->bSubframeSize; in parse_audio_format_i_type()
55 struct uac_format_type_i_ext_descriptor *fmt = _fmt; in parse_audio_format_i_type() local
56 sample_width = fmt->bBitResolution; in parse_audio_format_i_type()
57 sample_bytes = fmt->bSubslotSize; in parse_audio_format_i_type()
201 unsigned char *fmt, int offset) in parse_audio_format_rates_v1() argument
203 int nr_rates = fmt[offset]; in parse_audio_format_rates_v1()
205 if (fmt[0] < offset + 1 + 3 * (nr_rates ? nr_rates : 2)) { in parse_audio_format_rates_v1()
225 unsigned int rate = combine_triple(&fmt[idx]); in parse_audio_format_rates_v1()
[all …]
Dpcm.c222 const struct audioformat *fmt) in snd_usb_init_pitch() argument
227 if (!(fmt->attributes & UAC_EP_CS_ATTR_PITCH_CONTROL)) in snd_usb_init_pitch()
230 usb_audio_dbg(chip, "enable PITCH for EP 0x%x\n", fmt->endpoint); in snd_usb_init_pitch()
232 switch (fmt->protocol) { in snd_usb_init_pitch()
234 err = init_pitch_v1(chip, fmt->endpoint); in snd_usb_init_pitch()
237 err = init_pitch_v2(chip, fmt->endpoint); in snd_usb_init_pitch()
245 fmt->endpoint); in snd_usb_init_pitch()
315 struct audioformat *fmt) in snd_usb_audioformat_set_sync_ep() argument
324 if (fmt->sync_ep) in snd_usb_audioformat_set_sync_ep()
327 alts = snd_usb_get_host_interface(chip, fmt->iface, fmt->altsetting); in snd_usb_audioformat_set_sync_ep()
[all …]
Dusbaudio.h76 #define usb_audio_err(chip, fmt, args...) \ argument
77 dev_err(&(chip)->dev->dev, fmt, ##args)
78 #define usb_audio_warn(chip, fmt, args...) \ argument
79 dev_warn(&(chip)->dev->dev, fmt, ##args)
80 #define usb_audio_info(chip, fmt, args...) \ argument
81 dev_info(&(chip)->dev->dev, fmt, ##args)
82 #define usb_audio_dbg(chip, fmt, args...) \ argument
83 dev_dbg(&(chip)->dev->dev, fmt, ##args)
Dclock.h6 const struct audioformat *fmt, int rate);
9 const struct audioformat *fmt, bool validate);
12 const struct audioformat *fmt,
/sound/soc/qcom/qdsp6/
Dq6asm.c1097 struct asm_multi_channel_pcm_fmt_blk_v2 *fmt; in q6asm_media_format_block_multi_ch_pcm() local
1103 pkt_size = APR_HDR_SIZE + sizeof(*fmt); in q6asm_media_format_block_multi_ch_pcm()
1109 fmt = p + APR_HDR_SIZE; in q6asm_media_format_block_multi_ch_pcm()
1114 fmt->fmt_blk.fmt_blk_size = sizeof(*fmt) - sizeof(fmt->fmt_blk); in q6asm_media_format_block_multi_ch_pcm()
1115 fmt->num_channels = channels; in q6asm_media_format_block_multi_ch_pcm()
1116 fmt->bits_per_sample = bits_per_sample; in q6asm_media_format_block_multi_ch_pcm()
1117 fmt->sample_rate = rate; in q6asm_media_format_block_multi_ch_pcm()
1118 fmt->is_signed = 1; in q6asm_media_format_block_multi_ch_pcm()
1120 channel_mapping = fmt->channel_mapping; in q6asm_media_format_block_multi_ch_pcm()
1144 struct asm_flac_fmt_blk_v2 *fmt; in q6asm_stream_media_format_block_flac() local
[all …]
/sound/soc/intel/skylake/
Dskl-nhlt.c93 struct nhlt_fmt *fmt, u8 id) in skl_get_ssp_clks() argument
111 if (fmt->fmt_count == 0) in skl_get_ssp_clks()
114 fmt_cfg = (struct nhlt_fmt_cfg *)fmt->fmt_config; in skl_get_ssp_clks()
115 for (i = 0; i < fmt->fmt_count; i++) { in skl_get_ssp_clks()
121 channels = wav_fmt->fmt.channels; in skl_get_ssp_clks()
122 bps = wav_fmt->fmt.bits_per_sample; in skl_get_ssp_clks()
123 fs = wav_fmt->fmt.samples_per_sec; in skl_get_ssp_clks()
136 for (j = i; j < fmt->fmt_count; j++) { in skl_get_ssp_clks()
140 if ((fs == wav_fmt->fmt.samples_per_sec) && in skl_get_ssp_clks()
141 (bps == wav_fmt->fmt.bits_per_sample)) { in skl_get_ssp_clks()
[all …]
Dskl-topology.c120 dev_dbg(skl->dev, "channels = %d\n", iface->inputs[0].fmt.channels); in skl_dump_mconfig()
121 dev_dbg(skl->dev, "s_freq = %d\n", iface->inputs[0].fmt.s_freq); in skl_dump_mconfig()
122 dev_dbg(skl->dev, "ch_cfg = %d\n", iface->inputs[0].fmt.ch_cfg); in skl_dump_mconfig()
124 iface->inputs[0].fmt.valid_bit_depth); in skl_dump_mconfig()
126 dev_dbg(skl->dev, "channels = %d\n", iface->outputs[0].fmt.channels); in skl_dump_mconfig()
127 dev_dbg(skl->dev, "s_freq = %d\n", iface->outputs[0].fmt.s_freq); in skl_dump_mconfig()
129 iface->outputs[0].fmt.valid_bit_depth); in skl_dump_mconfig()
130 dev_dbg(skl->dev, "ch_cfg = %d\n", iface->outputs[0].fmt.ch_cfg); in skl_dump_mconfig()
133 static void skl_tplg_update_chmap(struct skl_module_fmt *fmt, int chs) in skl_tplg_update_chmap() argument
147 fmt->ch_map = slot_map; in skl_tplg_update_chmap()
[all …]
Dskl-debug.c53 static ssize_t skl_print_fmt(struct skl_module_fmt *fmt, char *buf, in skl_print_fmt() argument
61 fmt->channels, fmt->s_freq, fmt->bit_depth, in skl_print_fmt()
62 fmt->valid_bit_depth, fmt->ch_cfg, in skl_print_fmt()
63 fmt->interleaving_style, fmt->sample_type, in skl_print_fmt()
64 fmt->ch_map); in skl_print_fmt()
/sound/soc/codecs/
Dwm8753.c54 unsigned int fmt);
56 unsigned int fmt);
889 unsigned int fmt) in wm8753_vdac_adc_set_dai_fmt() argument
894 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in wm8753_vdac_adc_set_dai_fmt()
957 unsigned int fmt) in wm8753_pcm_set_dai_fmt() argument
965 switch (fmt & SND_SOC_DAIFMT_MASTER_MASK) { in wm8753_pcm_set_dai_fmt()
979 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in wm8753_pcm_set_dai_fmt()
983 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in wm8753_pcm_set_dai_fmt()
997 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in wm8753_pcm_set_dai_fmt()
1051 unsigned int fmt) in wm8753_hdac_set_dai_fmt() argument
[all …]
Dcs4349.c76 unsigned int fmt; in cs4349_set_dai_fmt() local
78 fmt = format & SND_SOC_DAIFMT_FORMAT_MASK; in cs4349_set_dai_fmt()
80 switch (fmt) { in cs4349_set_dai_fmt()
99 int fmt, ret; in cs4349_pcm_hw_params() local
105 fmt = DIF_I2S; in cs4349_pcm_hw_params()
108 fmt = DIF_LEFT_JST; in cs4349_pcm_hw_params()
113 fmt = DIF_RGHT_JST16; in cs4349_pcm_hw_params()
116 fmt = DIF_RGHT_JST24; in cs4349_pcm_hw_params()
127 MODE_FORMAT(fmt)); in cs4349_pcm_hw_params()
Des7241.c30 unsigned int fmt; member
125 static int es7241_set_fmt(struct snd_soc_dai *dai, unsigned int fmt) in es7241_set_fmt() argument
129 if ((fmt & SND_SOC_DAIFMT_INV_MASK) != SND_SOC_DAIFMT_NB_NF) { in es7241_set_fmt()
134 if ((fmt & SND_SOC_DAIFMT_FORMAT_MASK) != priv->fmt) { in es7241_set_fmt()
139 switch (fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) { in es7241_set_fmt()
248 priv->fmt = SND_SOC_DAIFMT_LEFT_J; in es7241_parse_fmt()
250 priv->fmt = SND_SOC_DAIFMT_I2S; in es7241_parse_fmt()
Dsi476x.c66 unsigned int fmt) in si476x_codec_set_dai_fmt() argument
72 if ((fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) != SND_SOC_DAIFMT_CBC_CFC) in si476x_codec_set_dai_fmt()
75 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in si476x_codec_set_dai_fmt()
95 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in si476x_codec_set_dai_fmt()
98 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in si476x_codec_set_dai_fmt()
111 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in si476x_codec_set_dai_fmt()
Dak4613.c216 unsigned int fmt; member
229 unsigned int fmt; member
280 .fmt = SND_SOC_DAIFMT_##_fmt,\
533 unsigned int fmt; in ak4613_dai_set_fmt() local
535 fmt = format & SND_SOC_DAIFMT_FORMAT_MASK; in ak4613_dai_set_fmt()
536 switch (fmt) { in ak4613_dai_set_fmt()
539 priv->fmt = fmt; in ak4613_dai_set_fmt()
545 fmt = format & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK; in ak4613_dai_set_fmt()
546 switch (fmt) { in ak4613_dai_set_fmt()
569 unsigned int fmt = priv->fmt; in ak4613_dai_hw_params() local
[all …]
Dlochnagar-sc.c119 static int lochnagar_sc_check_fmt(struct snd_soc_dai *dai, unsigned int fmt, in lochnagar_sc_check_fmt() argument
124 if ((fmt & ~SND_SOC_DAIFMT_CLOCK_MASK) != tar) in lochnagar_sc_check_fmt()
130 static int lochnagar_sc_set_line_fmt(struct snd_soc_dai *dai, unsigned int fmt) in lochnagar_sc_set_line_fmt() argument
132 return lochnagar_sc_check_fmt(dai, fmt, SND_SOC_DAIFMT_CBS_CFS); in lochnagar_sc_set_line_fmt()
135 static int lochnagar_sc_set_usb_fmt(struct snd_soc_dai *dai, unsigned int fmt) in lochnagar_sc_set_usb_fmt() argument
137 return lochnagar_sc_check_fmt(dai, fmt, SND_SOC_DAIFMT_CBM_CFM); in lochnagar_sc_set_usb_fmt()
/sound/soc/meson/
Daxg-tdm-interface.c45 unsigned int fmt = 0; in axg_tdm_set_tdm_slots() local
63 fmt |= SNDRV_PCM_FMTBIT_S32_LE; in axg_tdm_set_tdm_slots()
66 fmt |= SNDRV_PCM_FMTBIT_S24_LE; in axg_tdm_set_tdm_slots()
67 fmt |= SNDRV_PCM_FMTBIT_S20_LE; in axg_tdm_set_tdm_slots()
70 fmt |= SNDRV_PCM_FMTBIT_S16_LE; in axg_tdm_set_tdm_slots()
73 fmt |= SNDRV_PCM_FMTBIT_S8; in axg_tdm_set_tdm_slots()
86 dai->driver->playback.formats = fmt; in axg_tdm_set_tdm_slots()
92 dai->driver->capture.formats = fmt; in axg_tdm_set_tdm_slots()
118 static int axg_tdm_iface_set_fmt(struct snd_soc_dai *dai, unsigned int fmt) in axg_tdm_iface_set_fmt() argument
122 switch (fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) { in axg_tdm_iface_set_fmt()
[all …]
Daxg-tdm.h33 unsigned int fmt; member
41 static inline bool axg_tdm_lrclk_invert(unsigned int fmt) in axg_tdm_lrclk_invert() argument
43 return ((fmt & SND_SOC_DAIFMT_FORMAT_MASK) == SND_SOC_DAIFMT_I2S) ^ in axg_tdm_lrclk_invert()
44 !!(fmt & (SND_SOC_DAIFMT_IB_IF | SND_SOC_DAIFMT_NB_IF)); in axg_tdm_lrclk_invert()
47 static inline bool axg_tdm_sclk_invert(unsigned int fmt) in axg_tdm_sclk_invert() argument
49 return fmt & (SND_SOC_DAIFMT_IB_IF | SND_SOC_DAIFMT_IB_NF); in axg_tdm_sclk_invert()
/sound/hda/
Dintel-nhlt.c68 if (fmt_ext->fmt.channels > max_ch) in intel_nhlt_get_dmic_geo()
69 max_ch = fmt_ext->fmt.channels; in intel_nhlt_get_dmic_geo()
174 struct nhlt_fmt *fmt; in intel_nhlt_ssp_mclk_mask() local
190 fmt = (struct nhlt_fmt *)(epnt->config.caps + epnt->config.size); in intel_nhlt_ssp_mclk_mask()
191 cfg = fmt->fmt_config; in intel_nhlt_ssp_mclk_mask()
197 for (j = 0; j < fmt->fmt_count; j++) { in intel_nhlt_ssp_mclk_mask()
240 nhlt_get_specific_cfg(struct device *dev, struct nhlt_fmt *fmt, u8 num_ch, in nhlt_get_specific_cfg() argument
243 struct nhlt_fmt_cfg *cfg = fmt->fmt_config; in nhlt_get_specific_cfg()
248 dev_dbg(dev, "Endpoint format count=%d\n", fmt->fmt_count); in nhlt_get_specific_cfg()
250 for (i = 0; i < fmt->fmt_count; i++) { in nhlt_get_specific_cfg()
[all …]
/sound/soc/ux500/
Dux500_msp_dai.c171 unsigned int fmt, in setup_clocking() argument
174 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in setup_clocking()
187 __func__, fmt); in setup_clocking()
192 switch (fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) { in setup_clocking()
218 __func__, fmt); in setup_clocking()
227 unsigned int fmt, in setup_pcm_protdesc() argument
239 if ((fmt & SND_SOC_DAIFMT_FORMAT_MASK) == SND_SOC_DAIFMT_DSP_A) { in setup_pcm_protdesc()
306 unsigned int fmt = drvdata->fmt; in setup_msp_config() local
328 switch (fmt & in setup_msp_config()
358 ret = setup_pcm_protdesc(dai, fmt, prot_desc); in setup_msp_config()
[all …]
/sound/soc/mediatek/mt8186/
Dmt8186-dai-pcm.c16 unsigned int fmt; member
256 pcm_con |= pcm_priv->fmt << PCM_FMT_SFT; in mtk_dai_pcm_hw_params()
284 static int mtk_dai_pcm_set_fmt(struct snd_soc_dai *dai, unsigned int fmt) in mtk_dai_pcm_set_fmt() argument
291 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in mtk_dai_pcm_set_fmt()
293 pcm_priv->fmt = AUD_PCM_FMT_I2S; in mtk_dai_pcm_set_fmt()
296 pcm_priv->fmt = AUD_PCM_FMT_EIAJ; in mtk_dai_pcm_set_fmt()
299 pcm_priv->fmt = AUD_PCM_FMT_PCM_MODE_A; in mtk_dai_pcm_set_fmt()
302 pcm_priv->fmt = AUD_PCM_FMT_PCM_MODE_B; in mtk_dai_pcm_set_fmt()
305 pcm_priv->fmt = AUD_PCM_FMT_I2S; in mtk_dai_pcm_set_fmt()
309 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in mtk_dai_pcm_set_fmt()
[all …]
/sound/soc/ti/
Ddavinci-i2s.c160 unsigned int fmt; member
220 unsigned int fmt) in davinci_i2s_set_dai_fmt() argument
231 dev->fmt = fmt; in davinci_i2s_set_dai_fmt()
233 switch (fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) { in davinci_i2s_set_dai_fmt()
273 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in davinci_i2s_set_dai_fmt()
304 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in davinci_i2s_set_dai_fmt()
385 snd_pcm_format_t fmt; in davinci_i2s_hw_params() local
398 master = dev->fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK; in davinci_i2s_hw_params()
399 fmt = params_format(params); in davinci_i2s_hw_params()
400 mcbsp_word_length = asp_word_length[fmt]; in davinci_i2s_hw_params()
[all …]
/sound/soc/
Dsoc-utils-test.c14 snd_pcm_format_t fmt; member
119 unsigned int rate, snd_pcm_format_t fmt, in test_tdm_params_to_bclk_one() argument
134 params_set_format(&params, fmt); in test_tdm_params_to_bclk_one()
151 tdm_params_to_bclk_cases[i].fmt, in test_tdm_params_to_bclk()
164 tdm_params_to_bclk_cases[i].fmt, in test_tdm_params_to_bclk()
174 unsigned int rate, snd_pcm_format_t fmt, in test_snd_soc_params_to_bclk_one() argument
187 params_set_format(&params, fmt); in test_snd_soc_params_to_bclk_one()
212 tdm_params_to_bclk_cases[i].fmt, in test_snd_soc_params_to_bclk()
/sound/soc/mediatek/mt8195/
Dmt8195-dai-pcm.c129 unsigned int fmt = pcmif_priv->format; in mtk_dai_pcm_configure() local
163 val |= PCM_INTF_CON1_PCM_FMT(fmt); in mtk_dai_pcm_configure()
167 if (fmt == MTK_DAI_PCM_FMT_MODEA || in mtk_dai_pcm_configure()
168 fmt == MTK_DAI_PCM_FMT_MODEB) in mtk_dai_pcm_configure()
226 static int mtk_dai_pcm_set_fmt(struct snd_soc_dai *dai, unsigned int fmt) in mtk_dai_pcm_set_fmt() argument
232 dev_dbg(dai->dev, "%s fmt 0x%x\n", __func__, fmt); in mtk_dai_pcm_set_fmt()
234 switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { in mtk_dai_pcm_set_fmt()
248 switch (fmt & SND_SOC_DAIFMT_INV_MASK) { in mtk_dai_pcm_set_fmt()
269 switch (fmt & SND_SOC_DAIFMT_CLOCK_PROVIDER_MASK) { in mtk_dai_pcm_set_fmt()
/sound/core/
Dmisc.c69 vaf.fmt = format; in __snd_printk()
72 while ((kern_level = printk_get_level(vaf.fmt)) != 0) { in __snd_printk()
73 const char *end_of_header = printk_skip_level(vaf.fmt); in __snd_printk()
77 memcpy(verbose_fmt, vaf.fmt, end_of_header - vaf.fmt); in __snd_printk()
81 vaf.fmt = end_of_header; in __snd_printk()

12345678910>>...16