Lines Matching full:format
21 #include "format.h"
24 * parse the audio format type I descriptor
25 * and returns the corresponding pcm format
29 * @format: the format tag (wFormatTag)
30 * @fmt: the format type descriptor (v1/v2) or AudioStreaming descriptor (v3)
34 u64 format, void *_fmt) in parse_audio_format_i_type() argument
45 format = 1ULL << format; in parse_audio_format_i_type()
54 if (format & UAC2_FORMAT_TYPE_I_RAW_DATA) { in parse_audio_format_i_type()
60 format <<= 1; in parse_audio_format_i_type()
69 if (format & UAC3_FORMAT_TYPE_I_RAW_DATA) in parse_audio_format_i_type()
72 format <<= 1; in parse_audio_format_i_type()
80 (format == 0 || format == (1 << UAC_FORMAT_TYPE_I_UNDEFINED))) { in parse_audio_format_i_type()
82 usb_audio_info(chip, "%u:%d : format type 0 is detected, processed as PCM\n", in parse_audio_format_i_type()
84 format = 1 << UAC_FORMAT_TYPE_I_PCM; in parse_audio_format_i_type()
86 if (format & (1 << UAC_FORMAT_TYPE_I_PCM)) { in parse_audio_format_i_type()
98 /* check the format byte size */ in parse_audio_format_i_type()
126 if (format & (1 << UAC_FORMAT_TYPE_I_PCM8)) { in parse_audio_format_i_type()
127 /* Dallas DS4201 workaround: it advertises U8 format, but really in parse_audio_format_i_type()
134 if (format & (1 << UAC_FORMAT_TYPE_I_IEEE_FLOAT)) { in parse_audio_format_i_type()
137 if (format & (1 << UAC_FORMAT_TYPE_I_ALAW)) { in parse_audio_format_i_type()
140 if (format & (1 << UAC_FORMAT_TYPE_I_MULAW)) { in parse_audio_format_i_type()
143 if (format & ~0x3f) { in parse_audio_format_i_type()
145 "%u:%d : unsupported format bits %#llx\n", in parse_audio_format_i_type()
146 fp->iface, fp->altsetting, format); in parse_audio_format_i_type()
156 * parse the format descriptor and stores the possible sample rates
161 * @fmt: the format descriptor
217 hwc_debug("All rates were zero. Skipping format!\n"); in parse_audio_format_rates_v1()
316 * parse the format descriptor and stores the possible sample rates
415 * parse the format type I and III descriptors
418 struct audioformat *fp, u64 format, in parse_audio_format_i() argument
442 /* FIXME: the format type is really IECxxx in parse_audio_format_i()
443 * but we give normal PCM format to get the existing in parse_audio_format_i()
460 fp->formats = parse_audio_format_i_type(chip, fp, format, _fmt); in parse_audio_format_i()
498 * parse the format type II descriptor
502 u64 format, void *_fmt) in parse_audio_format_ii() argument
506 switch (format) { in parse_audio_format_ii()
508 /* FIXME: there is no AC3 format defined yet */ in parse_audio_format_ii()
517 "%u:%d : unknown format tag %#llx is detected. processed as MPEG.\n", in parse_audio_format_ii()
518 fp->iface, fp->altsetting, format); in parse_audio_format_ii()
531 usb_audio_info(chip, "found format II with max.bitrate = %d, frame size=%d\n", brate, framesize); in parse_audio_format_ii()
540 usb_audio_info(chip, "found format II with max.bitrate = %d, frame size=%d\n", brate, framesize); in parse_audio_format_ii()
551 struct audioformat *fp, u64 format, in snd_usb_parse_audio_format() argument
560 err = parse_audio_format_i(chip, fp, format, fmt); in snd_usb_parse_audio_format()
563 err = parse_audio_format_ii(chip, fp, format, fmt); in snd_usb_parse_audio_format()
567 "%u:%d : format type %d is not supported yet\n", in snd_usb_parse_audio_format()
597 u64 format = le64_to_cpu(as->bmFormats); in snd_usb_parse_audio_format_v3() local
601 * Type I format bits are D0..D6 in snd_usb_parse_audio_format_v3()
604 if (format & 0x7f) in snd_usb_parse_audio_format_v3()
609 err = parse_audio_format_i(chip, fp, format, as); in snd_usb_parse_audio_format_v3()