Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'sound-3.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
"A bunch of small fixes for USB-audio and HD-audio, where most of them
are for regressions: USB-audio PM fixes, ratelimit annoyance fix, HDMI
offline state fix, and a couple of device-specific quirks"

* tag 'sound-3.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ALSA: hda - hdmi: Set converter channel count even without sink
ALSA: usb-audio: work around corrupted TEAC UD-H01 feedback data
ALSA: usb-audio: Fix deadlocks at resuming
ALSA: usb-audio: Save mixer status only once at suspend
ALSA: usb-audio: Prevent printk ratelimiting from spamming kernel log while DEBUG not defined
ALSA: hda - add headset mic detect quirk for a Dell laptop

+30 -9
+3 -1
sound/pci/hda/patch_hdmi.c
··· 1127 1127 AMP_OUT_UNMUTE); 1128 1128 1129 1129 eld = &per_pin->sink_eld; 1130 - if (!eld->monitor_present) 1130 + if (!eld->monitor_present) { 1131 + hdmi_set_channel_count(codec, per_pin->cvt_nid, channels); 1131 1132 return; 1133 + } 1132 1134 1133 1135 if (!non_pcm && per_pin->chmap_set) 1134 1136 ca = hdmi_manual_channel_allocation(channels, per_pin->chmap);
+1
sound/pci/hda/patch_realtek.c
··· 4622 4622 SND_PCI_QUIRK(0x1028, 0x0668, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE), 4623 4623 SND_PCI_QUIRK(0x1028, 0x0669, "Dell", ALC255_FIXUP_DELL2_MIC_NO_PRESENCE), 4624 4624 SND_PCI_QUIRK(0x1028, 0x0674, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE), 4625 + SND_PCI_QUIRK(0x1028, 0x067e, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE), 4625 4626 SND_PCI_QUIRK(0x1028, 0x067f, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE), 4626 4627 SND_PCI_QUIRK(0x1028, 0x15cc, "Dell X5 Precision", ALC269_FIXUP_DELL2_MIC_NO_PRESENCE), 4627 4628 SND_PCI_QUIRK(0x1028, 0x15cd, "Dell X5 Precision", ALC269_FIXUP_DELL2_MIC_NO_PRESENCE),
+8 -4
sound/usb/card.c
··· 651 651 int err = -ENODEV; 652 652 653 653 down_read(&chip->shutdown_rwsem); 654 - if (chip->probing) 654 + if (chip->probing && chip->in_pm) 655 655 err = 0; 656 656 else if (!chip->shutdown) 657 657 err = usb_autopm_get_interface(chip->pm_intf); ··· 663 663 void snd_usb_autosuspend(struct snd_usb_audio *chip) 664 664 { 665 665 down_read(&chip->shutdown_rwsem); 666 - if (!chip->shutdown && !chip->probing) 666 + if (!chip->shutdown && !chip->probing && !chip->in_pm) 667 667 usb_autopm_put_interface(chip->pm_intf); 668 668 up_read(&chip->shutdown_rwsem); 669 669 } ··· 695 695 chip->autosuspended = 1; 696 696 } 697 697 698 - list_for_each_entry(mixer, &chip->mixer_list, list) 699 - snd_usb_mixer_suspend(mixer); 698 + if (chip->num_suspended_intf == 1) 699 + list_for_each_entry(mixer, &chip->mixer_list, list) 700 + snd_usb_mixer_suspend(mixer); 700 701 701 702 return 0; 702 703 } ··· 712 711 return 0; 713 712 if (--chip->num_suspended_intf) 714 713 return 0; 714 + 715 + chip->in_pm = 1; 715 716 /* 716 717 * ALSA leaves material resumption to user space 717 718 * we just notify and restart the mixers ··· 729 726 chip->autosuspended = 0; 730 727 731 728 err_out: 729 + chip->in_pm = 0; 732 730 return err; 733 731 } 734 732
+1
sound/usb/card.h
··· 92 92 unsigned int curframesize; /* current packet size in frames (for capture) */ 93 93 unsigned int syncmaxsize; /* sync endpoint packet size */ 94 94 unsigned int fill_max:1; /* fill max packet size always */ 95 + unsigned int udh01_fb_quirk:1; /* corrupted feedback data */ 95 96 unsigned int datainterval; /* log_2 of data packet interval */ 96 97 unsigned int syncinterval; /* P for adaptive mode, 0 otherwise */ 97 98 unsigned char silence_value;
+14 -1
sound/usb/endpoint.c
··· 471 471 ep->syncinterval = 3; 472 472 473 473 ep->syncmaxsize = le16_to_cpu(get_endpoint(alts, 1)->wMaxPacketSize); 474 + 475 + if (chip->usb_id == USB_ID(0x0644, 0x8038) /* TEAC UD-H01 */ && 476 + ep->syncmaxsize == 4) 477 + ep->udh01_fb_quirk = 1; 474 478 } 475 479 476 480 list_add_tail(&ep->list, &chip->ep_list); ··· 1109 1105 if (f == 0) 1110 1106 return; 1111 1107 1112 - if (unlikely(ep->freqshift == INT_MIN)) { 1108 + if (unlikely(sender->udh01_fb_quirk)) { 1109 + /* 1110 + * The TEAC UD-H01 firmware sometimes changes the feedback value 1111 + * by +/- 0x1.0000. 1112 + */ 1113 + if (f < ep->freqn - 0x8000) 1114 + f += 0x10000; 1115 + else if (f > ep->freqn + 0x8000) 1116 + f -= 0x10000; 1117 + } else if (unlikely(ep->freqshift == INT_MIN)) { 1113 1118 /* 1114 1119 * The first time we see a feedback value, determine its format 1115 1120 * by shifting it left or right until it matches the nominal
+2 -3
sound/usb/pcm.c
··· 1501 1501 * The error should be lower than 2ms since the estimate relies 1502 1502 * on two reads of a counter updated every ms. 1503 1503 */ 1504 - if (printk_ratelimit() && 1505 - abs(est_delay - subs->last_delay) * 1000 > runtime->rate * 2) 1506 - dev_dbg(&subs->dev->dev, 1504 + if (abs(est_delay - subs->last_delay) * 1000 > runtime->rate * 2) 1505 + dev_dbg_ratelimited(&subs->dev->dev, 1507 1506 "delay: estimated %d, actual %d\n", 1508 1507 est_delay, subs->last_delay); 1509 1508
+1
sound/usb/usbaudio.h
··· 40 40 struct rw_semaphore shutdown_rwsem; 41 41 unsigned int shutdown:1; 42 42 unsigned int probing:1; 43 + unsigned int in_pm:1; 43 44 unsigned int autosuspended:1; 44 45 unsigned int txfr_quirk:1; /* Subframe boundaries on transfers */ 45 46