Lines Matching defs:fmt

220 		       const struct audioformat *fmt)
225 if (!(fmt->attributes & UAC_EP_CS_ATTR_PITCH_CONTROL))
228 usb_audio_dbg(chip, "enable PITCH for EP 0x%x\n", fmt->endpoint);
230 switch (fmt->protocol) {
232 err = init_pitch_v1(chip, fmt->endpoint);
235 err = init_pitch_v2(chip, fmt->endpoint);
243 fmt->endpoint);
313 struct audioformat *fmt)
322 if (fmt->sync_ep)
325 alts = snd_usb_get_host_interface(chip, fmt->iface, fmt->altsetting);
330 err = snd_usb_parse_implicit_fb_quirk(chip, fmt, alts);
338 if (fmt->ep_idx > 0 || altsd->bNumEndpoints < 2)
342 attr = fmt->ep_attr & USB_ENDPOINT_SYNCTYPE;
365 fmt->iface, fmt->altsetting,
380 fmt->iface, fmt->altsetting,
387 fmt->sync_ep = ep;
388 fmt->sync_iface = altsd->bInterfaceNumber;
389 fmt->sync_altsetting = altsd->bAlternateSetting;
390 fmt->sync_ep_idx = 1;
392 fmt->implicit_fb = 1;
395 fmt->iface, fmt->altsetting, fmt->sync_ep, fmt->sync_iface,
396 fmt->sync_altsetting, fmt->implicit_fb);
479 const struct audioformat *fmt;
489 fmt = find_substream_format(subs, hw_params);
490 if (!fmt) {
499 if (fmt->implicit_fb) {
500 sync_fmt = snd_usb_find_implicit_fb_sync_format(chip, fmt,
507 fmt->sync_ep, fmt->sync_iface,
508 fmt->sync_altsetting,
515 sync_fmt = fmt;
529 fmt, hw_params))
536 subs->data_endpoint = snd_usb_endpoint_open(chip, fmt, hw_params, false, fixed_rate);
542 if (fmt->sync_ep) {
545 fmt == sync_fmt,
557 subs->cur_audiofmt = fmt;
702 #define hwc_debug(fmt, args...) pr_debug(fmt, ##args)
704 #define hwc_debug(fmt, args...) do { } while(0)
901 static int apply_hw_params_format_bits(struct snd_mask *fmt, u64 fbits)
906 oldbits[0] = fmt->bits[0];
907 oldbits[1] = fmt->bits[1];
908 fmt->bits[0] &= (u32)fbits;
909 fmt->bits[1] &= (u32)(fbits >> 32);
910 if (!fmt->bits[0] && !fmt->bits[1]) {
914 changed = (oldbits[0] != fmt->bits[0] || oldbits[1] != fmt->bits[1]);
915 hwc_debug(" --> %x:%x (changed = %d)\n", fmt->bits[0], fmt->bits[1], changed);
926 struct snd_mask *fmt = hw_param_mask(params, SNDRV_PCM_HW_PARAM_FORMAT);
929 hwc_debug("hw_rule_format: %x:%x\n", fmt->bits[0], fmt->bits[1]);
957 return apply_hw_params_format_bits(fmt, fbits);