History

Merge branch 'for-linus' into for-next

Merge for 5.18-rc1

Takashi Iwai committed 4 years ago

Commit 1212fa12 parents 03a8b0d 7b0efea57 files · +492 −263Browse files

Unified · Split

57 files
  1. drivers/firewire/core-card.c +3 −0
  2. drivers/firewire/core-cdev.c +3 −1
  3. drivers/firewire/core-topology.c +3 −6
  4. drivers/firewire/core-transaction.c +16 −14
  5. drivers/firewire/sbp2.c +7 −6
  6. drivers/firmware/cirrus/cs_dsp.c +1 −2
  7. include/sound/soc-component.h +4 −0
  8. sound/firewire/fireworks/fireworks_hwdep.c +1 −0
  9. sound/hda/hdac_i915.c +3 −4
  10. sound/hda/intel-dsp-config.c +9 −0
  11. sound/isa/wavefront/wavefront_synth.c +2 −1
  12. sound/oss/dmasound/dmasound_core.c +1 −1
  13. sound/pci/hda/patch_hdmi.c +5 −2
  14. sound/pci/hda/patch_realtek.c +85 −13
  15. sound/pci/lola/lola_pcm.c +2 −1
  16. sound/soc/atmel/mchp-pdmc.c +1 −0
  17. sound/soc/atmel/sam9g20_wm8731.c +0 −61
  18. sound/soc/codecs/cs35l41-lib.c +6 −4
  19. sound/soc/codecs/da7219.c +10 −4
  20. sound/soc/codecs/lpass-rx-macro.c +10 −4
  21. sound/soc/codecs/lpass-tx-macro.c +10 −4
  22. sound/soc/codecs/lpass-va-macro.c +6 −2
  23. sound/soc/codecs/max98090.c +4 −1
  24. sound/soc/codecs/msm8916-wcd-digital.c +8 −1
  25. sound/soc/codecs/rk817_codec.c +1 −1
  26. sound/soc/codecs/rt5682.c +13 −7
  27. sound/soc/codecs/rt5682s.c +4 −7
  28. sound/soc/codecs/rt711.c +7 −0
  29. sound/soc/codecs/rt9120.c +0 −1
  30. sound/soc/codecs/wcd934x.c +1 −25
  31. sound/soc/codecs/wm8731.c +11 −8
  32. sound/soc/codecs/wm8958-dsp2.c +4 −4
  33. sound/soc/codecs/wm_adsp.c +5 −5
  34. sound/soc/fsl/fsl_sai.c +1 −1
  35. sound/soc/generic/simple-card-utils.c +5 −3
  36. sound/soc/intel/boards/sof_es8336.c +89 −28
  37. sound/soc/intel/boards/sof_rt5682.c +13 −0
  38. sound/soc/intel/common/soc-acpi-intel-tgl-match.c +2 −2
  39. sound/soc/meson/aiu-acodec-ctrl.c +4 −1
  40. sound/soc/meson/aiu-codec-ctrl.c +4 −1
  41. sound/soc/meson/aiu.c +3 −0
  42. sound/soc/meson/axg-card.c +0 −1
  43. sound/soc/meson/axg-tdm-interface.c +5 −21
  44. sound/soc/meson/g12a-tohdmitx.c +1 −1
  45. sound/soc/soc-core.c +5 −0
  46. sound/soc/soc-dapm.c +2 −4
  47. sound/soc/soc-generic-dmaengine-pcm.c +3 −3
  48. sound/soc/soc-ops.c +18 −2
  49. sound/soc/soc-pcm.c +1 −1
  50. sound/soc/soc-topology.c +2 −2
  51. sound/soc/sof/sof-pci-dev.c +13 −1
  52. sound/soc/sof/topology.c +49 −1
  53. sound/usb/clock.c +7 −0
  54. sound/usb/midi.c +1 −0
  55. sound/usb/mixer_maps.c +4 −0
  56. sound/usb/quirks-table.h +12 −0
  57. sound/usb/quirks.c +2 −0
drivers/firewire/core-card.c+3−0
@@ -679,6 +679,7 @@ EXPORT_SYMBOL_GPL(fw_card_release); · 678 unmodified lines
679679 void fw_core_remove_card(struct fw_card *card)
680680 {
681681 struct fw_card_driver dummy_driver = dummy_driver_template;
682+ unsigned long flags;
682683
683684 card->driver->update_phy_reg(card, 4,
684685 PHY_LINK_ACTIVE | PHY_CONTENDER, 0);
@@ -693,7 +694,9 @@ void fw_core_remove_card(struct fw_card *card) · 8 unmodified lines
693694 dummy_driver.stop_iso = card->driver->stop_iso;
694695 card->driver = &dummy_driver;
695696
697+ spin_lock_irqsave(&card->lock, flags);
696698 fw_destroy_nodes(card);
699+ spin_unlock_irqrestore(&card->lock, flags);
697700
698701 /* Wait for all users, especially device workqueue jobs, to finish. */
699702 fw_card_put(card);
drivers/firewire/core-cdev.c+3−1
@@ -1502,6 +1502,7 @@ static void outbound_phy_packet_callback(struct fw_packet *packet, · 1501 unmodified lines
15021502 {
15031503 struct outbound_phy_packet_event *e =
15041504 container_of(packet, struct outbound_phy_packet_event, p);
1505+ struct client *e_client;
15051506
15061507 switch (status) {
15071508 /* expected: */
@@ -1518,9 +1519,10 @@ static void outbound_phy_packet_callback(struct fw_packet *packet, · 10 unmodified lines
15181519 }
15191520 e->phy_packet.data[0] = packet->timestamp;
15201521
1522+ e_client = e->client;
15211523 queue_event(e->client, &e->event, &e->phy_packet,
15221524 sizeof(e->phy_packet) + e->phy_packet.length, NULL, 0);
1523− client_put(e->client);
1525+ client_put(e_client);
15241526 }
15251527
15261528 static int ioctl_send_phy_packet(struct client *client, union ioctl_arg *arg)
drivers/firewire/core-topology.c+3−6
@@ -375,16 +375,13 @@ static void report_found_node(struct fw_card *card, · 374 unmodified lines
375375 card->bm_retries = 0;
376376 }
377377
378+/* Must be called with card->lock held */
378379 void fw_destroy_nodes(struct fw_card *card)
379380 {
380− unsigned long flags;
381−
382− spin_lock_irqsave(&card->lock, flags);
383381 card->color++;
384382 if (card->local_node != NULL)
385383 for_each_fw_node(card, card->local_node, report_lost_node);
386384 card->local_node = NULL;
387− spin_unlock_irqrestore(&card->lock, flags);
388385 }
389386
390387 static void move_tree(struct fw_node *node0, struct fw_node *node1, int port)
@@ -510,6 +507,8 @@ void fw_core_handle_bus_reset(struct fw_card *card, int node_id, int generation, · 119 unmodified lines
510507 struct fw_node *local_node;
511508 unsigned long flags;
512509
510+ spin_lock_irqsave(&card->lock, flags);
511+
513512 /*
514513 * If the selfID buffer is not the immediate successor of the
515514 * previously processed one, we cannot reliably compare the
@@ -521,8 +520,6 @@ void fw_core_handle_bus_reset(struct fw_card *card, int node_id, int generation, · 5 unmodified lines
521520 card->bm_retries = 0;
522521 }
523522
524− spin_lock_irqsave(&card->lock, flags);
525−
526523 card->broadcast_channel_allocated = card->broadcast_channel_auto_allocated;
527524 card->node_id = node_id;
528525 /*
drivers/firewire/core-transaction.c+16−14
@@ -73,24 +73,25 @@ static int try_cancel_split_timeout(struct fw_transaction *t) · 72 unmodified lines
7373 static int close_transaction(struct fw_transaction *transaction,
7474 struct fw_card *card, int rcode)
7575 {
76− struct fw_transaction *t;
76+ struct fw_transaction *t = NULL, *iter;
7777 unsigned long flags;
7878
7979 spin_lock_irqsave(&card->lock, flags);
80− list_for_each_entry(t, &card->transaction_list, link) {
81− if (t == transaction) {
82− if (!try_cancel_split_timeout(t)) {
80+ list_for_each_entry(iter, &card->transaction_list, link) {
81+ if (iter == transaction) {
82+ if (!try_cancel_split_timeout(iter)) {
8383 spin_unlock_irqrestore(&card->lock, flags);
8484 goto timed_out;
8585 }
86− list_del_init(&t->link);
87− card->tlabel_mask &= ~(1ULL << t->tlabel);
86+ list_del_init(&iter->link);
87+ card->tlabel_mask &= ~(1ULL << iter->tlabel);
88+ t = iter;
8889 break;
8990 }
9091 }
9192 spin_unlock_irqrestore(&card->lock, flags);
9293
93− if (&t->link != &card->transaction_list) {
94+ if (t) {
9495 t->callback(card, rcode, NULL, 0, t->callback_data);
9596 return 0;
9697 }
@@ -953,7 +954,7 @@ EXPORT_SYMBOL(fw_core_handle_request); · 856 unmodified lines
953954
954955 void fw_core_handle_response(struct fw_card *card, struct fw_packet *p)
955956 {
956− struct fw_transaction *t;
957+ struct fw_transaction *t = NULL, *iter;
957958 unsigned long flags;
958959 u32 *data;
959960 size_t data_length;
@@ -965,20 +966,21 @@ void fw_core_handle_response(struct fw_card *card, struct fw_packet *p) · 5 unmodified lines
965966 rcode = HEADER_GET_RCODE(p->header[1]);
966967
967968 spin_lock_irqsave(&card->lock, flags);
968− list_for_each_entry(t, &card->transaction_list, link) {
969− if (t->node_id == source && t->tlabel == tlabel) {
970− if (!try_cancel_split_timeout(t)) {
969+ list_for_each_entry(iter, &card->transaction_list, link) {
970+ if (iter->node_id == source && iter->tlabel == tlabel) {
971+ if (!try_cancel_split_timeout(iter)) {
971972 spin_unlock_irqrestore(&card->lock, flags);
972973 goto timed_out;
973974 }
974− list_del_init(&t->link);
975− card->tlabel_mask &= ~(1ULL << t->tlabel);
975+ list_del_init(&iter->link);
976+ card->tlabel_mask &= ~(1ULL << iter->tlabel);
977+ t = iter;
976978 break;
977979 }
978980 }
979981 spin_unlock_irqrestore(&card->lock, flags);
980982
981− if (&t->link == &card->transaction_list) {
983+ if (!t) {
982984 timed_out:
983985 fw_notice(card, "unsolicited response (source %x, tlabel %x)\n",
984986 source, tlabel);
drivers/firewire/sbp2.c+7−6
@@ -408,7 +408,7 @@ static void sbp2_status_write(struct fw_card *card, struct fw_request *request, · 407 unmodified lines
408408 void *payload, size_t length, void *callback_data)
409409 {
410410 struct sbp2_logical_unit *lu = callback_data;
411− struct sbp2_orb *orb;
411+ struct sbp2_orb *orb = NULL, *iter;
412412 struct sbp2_status status;
413413 unsigned long flags;
414414
@@ -433,17 +433,18 @@ static void sbp2_status_write(struct fw_card *card, struct fw_request *request, · 18 unmodified lines
433433
434434 /* Lookup the orb corresponding to this status write. */
435435 spin_lock_irqsave(&lu->tgt->lock, flags);
436− list_for_each_entry(orb, &lu->orb_list, link) {
436+ list_for_each_entry(iter, &lu->orb_list, link) {
437437 if (STATUS_GET_ORB_HIGH(status) == 0 &&
438− STATUS_GET_ORB_LOW(status) == orb->request_bus) {
439− orb->rcode = RCODE_COMPLETE;
440− list_del(&orb->link);
438+ STATUS_GET_ORB_LOW(status) == iter->request_bus) {
439+ iter->rcode = RCODE_COMPLETE;
440+ list_del(&iter->link);
441+ orb = iter;
441442 break;
442443 }
443444 }
444445 spin_unlock_irqrestore(&lu->tgt->lock, flags);
445446
446− if (&orb->link != &lu->orb_list) {
447+ if (orb) {
447448 orb->callback(orb, &status);
448449 kref_put(&orb->kref, free_orb); /* orb callback reference */
449450 } else {
drivers/firmware/cirrus/cs_dsp.c+1−2
@@ -955,8 +955,7 @@ static int cs_dsp_create_control(struct cs_dsp *dsp, · 954 unmodified lines
955955 ctl->alg_region = *alg_region;
956956 if (subname && dsp->fw_ver >= 2) {
957957 ctl->subname_len = subname_len;
958− ctl->subname = kmemdup(subname,
959− strlen(subname) + 1, GFP_KERNEL);
958+ ctl->subname = kasprintf(GFP_KERNEL, "%.*s", subname_len, subname);
960959 if (!ctl->subname) {
961960 ret = -ENOMEM;
962961 goto err_ctl;
include/sound/soc-component.h+4−0
@@ -179,6 +179,10 @@ struct snd_soc_component_driver { · 178 unmodified lines
179179 struct snd_pcm_hw_params *params);
180180 bool use_dai_pcm_id; /* use DAI link PCM ID as PCM device number */
181181 int be_pcm_base; /* base device ID for all BE PCMs */
182+
183+#ifdef CONFIG_DEBUG_FS
184+ const char *debugfs_prefix;
185+#endif
182186 };
183187
184188 struct snd_soc_component {
sound/firewire/fireworks/fireworks_hwdep.c+1−0
@@ -34,6 +34,7 @@ hwdep_read_resp_buf(struct snd_efw *efw, char __user *buf, long remained, · 33 unmodified lines
3434 type = SNDRV_FIREWIRE_EVENT_EFW_RESPONSE;
3535 if (copy_to_user(buf, &type, sizeof(type)))
3636 return -EFAULT;
37+ count += sizeof(type);
3738 remained -= sizeof(type);
3839 buf += sizeof(type);
3940
sound/hda/hdac_i915.c+3−4
@@ -127,11 +127,10 @@ static int i915_gfx_present(struct pci_dev *hdac_pci) · 126 unmodified lines
127127 display_dev = pci_get_class(class, display_dev);
128128
129129 if (display_dev && display_dev->vendor == PCI_VENDOR_ID_INTEL &&
130− connectivity_check(display_dev, hdac_pci))
130+ connectivity_check(display_dev, hdac_pci)) {
131+ pci_dev_put(display_dev);
131132 match = true;
132−
133− pci_dev_put(display_dev);
134−
133+ }
135134 } while (!match && display_dev);
136135
137136 return match;
sound/hda/intel-dsp-config.c+9−0
@@ -424,6 +424,15 @@ static const struct config_entry config_table[] = { · 423 unmodified lines
424424 .flags = FLAG_SOF | FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE,
425425 .device = 0x54c8,
426426 },
427+ /* RaptorLake-P */
428+ {
429+ .flags = FLAG_SOF | FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE,
430+ .device = 0x51ca,
431+ },
432+ {
433+ .flags = FLAG_SOF | FLAG_SOF_ONLY_IF_DMIC_OR_SOUNDWIRE,
434+ .device = 0x51cb,
435+ },
427436 #endif
428437
429438 };
sound/isa/wavefront/wavefront_synth.c+2−1
@@ -1094,7 +1094,8 @@ wavefront_send_sample (snd_wavefront_t *dev, · 1093 unmodified lines
10941094
10951095 if (dataptr < data_end) {
10961096
1097− __get_user (sample_short, dataptr);
1097+ if (get_user(sample_short, dataptr))
1098+ return -EFAULT;
10981099 dataptr += skip;
10991100
11001101 if (data_is_unsigned) { /* GUS ? */
sound/oss/dmasound/dmasound_core.c+1−1
@@ -1428,7 +1428,7 @@ void dmasound_deinit(void) · 1427 unmodified lines
14281428 unregister_sound_dsp(sq_unit);
14291429 }
14301430
1431−static int dmasound_setup(char *str)
1431+static int __maybe_unused dmasound_setup(char *str)
14321432 {
14331433 int ints[6], size;
14341434
sound/pci/hda/patch_hdmi.c+5−2
@@ -1395,7 +1395,7 @@ static int hdmi_find_pcm_slot(struct hdmi_spec *spec, · 1394 unmodified lines
13951395
13961396 last_try:
13971397 /* the last try; check the empty slots in pins */
1398− for (i = 0; i < spec->num_nids; i++) {
1398+ for (i = 0; i < spec->pcm_used; i++) {
13991399 if (!test_bit(i, &spec->pcm_bitmap))
14001400 return i;
14011401 }
@@ -2325,7 +2325,9 @@ static int generic_hdmi_build_pcms(struct hda_codec *codec) · 923 unmodified lines
23252325 * dev_num is the device entry number in a pin
23262326 */
23272327
2328− if (codec->mst_no_extra_pcms)
2328+ if (spec->dyn_pcm_no_legacy && codec->mst_no_extra_pcms)
2329+ pcm_num = spec->num_cvts;
2330+ else if (codec->mst_no_extra_pcms)
23292331 pcm_num = spec->num_nids;
23302332 else
23312333 pcm_num = spec->num_nids + spec->dev_num - 1;
@@ -4551,6 +4553,7 @@ HDA_CODEC_ENTRY(0x80862819, "DG2 HDMI", patch_i915_adlp_hdmi), · 2219 unmodified lines
45514553 HDA_CODEC_ENTRY(0x8086281a, "Jasperlake HDMI", patch_i915_icl_hdmi),
45524554 HDA_CODEC_ENTRY(0x8086281b, "Elkhartlake HDMI", patch_i915_icl_hdmi),
45534555 HDA_CODEC_ENTRY(0x8086281c, "Alderlake-P HDMI", patch_i915_adlp_hdmi),
4556+HDA_CODEC_ENTRY(0x8086281f, "Raptorlake-P HDMI", patch_i915_adlp_hdmi),
45544557 HDA_CODEC_ENTRY(0x80862880, "CedarTrail HDMI", patch_generic_hdmi),
45554558 HDA_CODEC_ENTRY(0x80862882, "Valleyview2 HDMI", patch_i915_byt_hdmi),
45564559 HDA_CODEC_ENTRY(0x80862883, "Braswell HDMI", patch_i915_byt_hdmi),
sound/pci/hda/patch_realtek.c+85−13
@@ -937,6 +937,9 @@ static int alc_init(struct hda_codec *codec) · 936 unmodified lines
937937 return 0;
938938 }
939939
940+#define alc_free snd_hda_gen_free
941+
942+#ifdef CONFIG_PM
940943 static inline void alc_shutup(struct hda_codec *codec)
941944 {
942945 struct alc_spec *spec = codec->spec;
@@ -950,9 +953,6 @@ static inline void alc_shutup(struct hda_codec *codec) · 7 unmodified lines
950953 alc_shutup_pins(codec);
951954 }
952955
953−#define alc_free snd_hda_gen_free
954−
955−#ifdef CONFIG_PM
956956 static void alc_power_eapd(struct hda_codec *codec)
957957 {
958958 alc_auto_setup_eapd(codec, false);
@@ -966,9 +966,7 @@ static int alc_suspend(struct hda_codec *codec) · 7 unmodified lines
966966 spec->power_hook(codec);
967967 return 0;
968968 }
969−#endif
970969
971−#ifdef CONFIG_PM
972970 static int alc_resume(struct hda_codec *codec)
973971 {
974972 struct alc_spec *spec = codec->spec;
@@ -6728,6 +6726,41 @@ static void alc256_fixup_mic_no_presence_and_resume(struct hda_codec *codec, · 5753 unmodified lines
67286726 }
67296727 }
67306728
6729+static void alc_fixup_dell4_mic_no_presence_quiet(struct hda_codec *codec,
6730+ const struct hda_fixup *fix,
6731+ int action)
6732+{
6733+ struct alc_spec *spec = codec->spec;
6734+ struct hda_input_mux *imux = &spec->gen.input_mux;
6735+ int i;
6736+
6737+ alc269_fixup_limit_int_mic_boost(codec, fix, action);
6738+
6739+ switch (action) {
6740+ case HDA_FIXUP_ACT_PRE_PROBE:
6741+ /**
6742+ * Set the vref of pin 0x19 (Headset Mic) and pin 0x1b (Headphone Mic)
6743+ * to Hi-Z to avoid pop noises at startup and when plugging and
6744+ * unplugging headphones.
6745+ */
6746+ snd_hda_codec_set_pin_target(codec, 0x19, PIN_VREFHIZ);
6747+ snd_hda_codec_set_pin_target(codec, 0x1b, PIN_VREFHIZ);
6748+ break;
6749+ case HDA_FIXUP_ACT_PROBE:
6750+ /**
6751+ * Make the internal mic (0x12) the default input source to
6752+ * prevent pop noises on cold boot.
6753+ */
6754+ for (i = 0; i < imux->num_items; i++) {
6755+ if (spec->gen.imux_pins[i] == 0x12) {
6756+ spec->gen.cur_mux[0] = i;
6757+ break;
6758+ }
6759+ }
6760+ break;
6761+ }
6762+}
6763+
67316764 enum {
67326765 ALC269_FIXUP_GPIO2,
67336766 ALC269_FIXUP_SONY_VAIO,
@@ -6769,6 +6802,7 @@ enum { · 35 unmodified lines
67696802 ALC269_FIXUP_DELL2_MIC_NO_PRESENCE,
67706803 ALC269_FIXUP_DELL3_MIC_NO_PRESENCE,
67716804 ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
6805+ ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET,
67726806 ALC269_FIXUP_HEADSET_MODE,
67736807 ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC,
67746808 ALC269_FIXUP_ASPIRE_HEADSET_MIC,
@@ -6954,11 +6988,13 @@ enum { · 179 unmodified lines
69546988 ALC285_FIXUP_LEGION_Y9000X_AUTOMUTE,
69556989 ALC287_FIXUP_LEGION_16ACHG6,
69566990 ALC287_FIXUP_CS35L41_I2C_2,
6991+ ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED,
69576992 ALC245_FIXUP_CS35L41_SPI_2,
69586993 ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED,
69596994 ALC245_FIXUP_CS35L41_SPI_4,
69606995 ALC245_FIXUP_CS35L41_SPI_4_HP_GPIO_LED,
69616996 ALC285_FIXUP_HP_SPEAKERS_MICMUTE_LED,
6997+ ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE,
69626998 };
69636999
69647000 static const struct hda_fixup alc269_fixups[] = {
@@ -8716,6 +8752,14 @@ static const struct hda_fixup alc269_fixups[] = { · 1751 unmodified lines
87168752 [ALC287_FIXUP_CS35L41_I2C_2] = {
87178753 .type = HDA_FIXUP_FUNC,
87188754 .v.func = cs35l41_fixup_i2c_two,
8755+ .chained = true,
8756+ .chain_id = ALC269_FIXUP_THINKPAD_ACPI,
8757+ },
8758+ [ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED] = {
8759+ .type = HDA_FIXUP_FUNC,
8760+ .v.func = cs35l41_fixup_i2c_two,
8761+ .chained = true,
8762+ .chain_id = ALC285_FIXUP_HP_MUTE_LED,
87198763 },
87208764 [ALC245_FIXUP_CS35L41_SPI_2] = {
87218765 .type = HDA_FIXUP_FUNC,
@@ -8747,6 +8791,21 @@ static const struct hda_fixup alc269_fixups[] = { · 25 unmodified lines
87478791 .chained = true,
87488792 .chain_id = ALC285_FIXUP_HP_MUTE_LED,
87498793 },
8794+ [ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET] = {
8795+ .type = HDA_FIXUP_FUNC,
8796+ .v.func = alc_fixup_dell4_mic_no_presence_quiet,
8797+ .chained = true,
8798+ .chain_id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
8799+ },
8800+ [ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE] = {
8801+ .type = HDA_FIXUP_PINS,
8802+ .v.pins = (const struct hda_pintbl[]) {
8803+ { 0x19, 0x02a1112c }, /* use as headset mic, without its own jack detect */
8804+ { }
8805+ },
8806+ .chained = true,
8807+ .chain_id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC
8808+ },
87508809 };
87518810
87528811 static const struct snd_pci_quirk alc269_fixup_tbl[] = {
@@ -8837,6 +8896,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 84 unmodified lines
88378896 SND_PCI_QUIRK(0x1028, 0x09bf, "Dell Precision", ALC233_FIXUP_ASUS_MIC_NO_PRESENCE),
88388897 SND_PCI_QUIRK(0x1028, 0x0a2e, "Dell", ALC236_FIXUP_DELL_AIO_HEADSET_MIC),
88398898 SND_PCI_QUIRK(0x1028, 0x0a30, "Dell", ALC236_FIXUP_DELL_AIO_HEADSET_MIC),
8899+ SND_PCI_QUIRK(0x1028, 0x0a38, "Dell Latitude 7520", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET),
88408900 SND_PCI_QUIRK(0x1028, 0x0a58, "Dell", ALC255_FIXUP_DELL_HEADSET_MIC),
88418901 SND_PCI_QUIRK(0x1028, 0x0a61, "Dell XPS 15 9510", ALC289_FIXUP_DUAL_SPK),
88428902 SND_PCI_QUIRK(0x1028, 0x0a62, "Dell Precision 5560", ALC289_FIXUP_DUAL_SPK),
@@ -8964,21 +9024,22 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 121 unmodified lines
89649024 SND_PCI_QUIRK(0x103c, 0x8896, "HP EliteBook 855 G8 Notebook PC", ALC285_FIXUP_HP_MUTE_LED),
89659025 SND_PCI_QUIRK(0x103c, 0x8898, "HP EliteBook 845 G8 Notebook PC", ALC285_FIXUP_HP_LIMIT_INT_MIC_BOOST),
89669026 SND_PCI_QUIRK(0x103c, 0x88d0, "HP Pavilion 15-eh1xxx (mainboard 88D0)", ALC287_FIXUP_HP_GPIO_LED),
8967− SND_PCI_QUIRK(0x103c, 0x896e, "HP EliteBook x360 830 G9", ALC245_FIXUP_CS35L41_SPI_2),
8968− SND_PCI_QUIRK(0x103c, 0x8971, "HP EliteBook 830 G9", ALC245_FIXUP_CS35L41_SPI_2),
8969− SND_PCI_QUIRK(0x103c, 0x8972, "HP EliteBook 840 G9", ALC245_FIXUP_CS35L41_SPI_2),
8970− SND_PCI_QUIRK(0x103c, 0x8973, "HP EliteBook 860 G9", ALC245_FIXUP_CS35L41_SPI_2),
8971− SND_PCI_QUIRK(0x103c, 0x8974, "HP EliteBook 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2),
8972− SND_PCI_QUIRK(0x103c, 0x8975, "HP EliteBook x360 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2),
9027+ SND_PCI_QUIRK(0x103c, 0x896e, "HP EliteBook x360 830 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
9028+ SND_PCI_QUIRK(0x103c, 0x8971, "HP EliteBook 830 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
9029+ SND_PCI_QUIRK(0x103c, 0x8972, "HP EliteBook 840 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
9030+ SND_PCI_QUIRK(0x103c, 0x8973, "HP EliteBook 860 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
9031+ SND_PCI_QUIRK(0x103c, 0x8974, "HP EliteBook 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
9032+ SND_PCI_QUIRK(0x103c, 0x8975, "HP EliteBook x360 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
89739033 SND_PCI_QUIRK(0x103c, 0x8981, "HP Elite Dragonfly G3", ALC245_FIXUP_CS35L41_SPI_4),
89749034 SND_PCI_QUIRK(0x103c, 0x898e, "HP EliteBook 835 G9", ALC287_FIXUP_CS35L41_I2C_2),
89759035 SND_PCI_QUIRK(0x103c, 0x898f, "HP EliteBook 835 G9", ALC287_FIXUP_CS35L41_I2C_2),
8976− SND_PCI_QUIRK(0x103c, 0x8991, "HP EliteBook 845 G9", ALC287_FIXUP_CS35L41_I2C_2),
9036+ SND_PCI_QUIRK(0x103c, 0x8991, "HP EliteBook 845 G9", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED),
89779037 SND_PCI_QUIRK(0x103c, 0x8992, "HP EliteBook 845 G9", ALC287_FIXUP_CS35L41_I2C_2),
8978− SND_PCI_QUIRK(0x103c, 0x8994, "HP EliteBook 855 G9", ALC287_FIXUP_CS35L41_I2C_2),
9038+ SND_PCI_QUIRK(0x103c, 0x8994, "HP EliteBook 855 G9", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED),
89799039 SND_PCI_QUIRK(0x103c, 0x8995, "HP EliteBook 855 G9", ALC287_FIXUP_CS35L41_I2C_2),
89809040 SND_PCI_QUIRK(0x103c, 0x89a4, "HP ProBook 440 G9", ALC236_FIXUP_HP_GPIO_LED),
89819041 SND_PCI_QUIRK(0x103c, 0x89a6, "HP ProBook 450 G9", ALC236_FIXUP_HP_GPIO_LED),
9042+ SND_PCI_QUIRK(0x103c, 0x89aa, "HP EliteBook 630 G9", ALC236_FIXUP_HP_GPIO_LED),
89829043 SND_PCI_QUIRK(0x103c, 0x89ac, "HP EliteBook 640 G9", ALC236_FIXUP_HP_GPIO_LED),
89839044 SND_PCI_QUIRK(0x103c, 0x89ae, "HP EliteBook 650 G9", ALC236_FIXUP_HP_GPIO_LED),
89849045 SND_PCI_QUIRK(0x103c, 0x89c3, "Zbook Studio G9", ALC245_FIXUP_CS35L41_SPI_4_HP_GPIO_LED),
@@ -9111,6 +9172,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 126 unmodified lines
91119172 SND_PCI_QUIRK(0x1558, 0x8562, "Clevo NH[57][0-9]RZ[Q]", ALC269_FIXUP_DMIC),
91129173 SND_PCI_QUIRK(0x1558, 0x8668, "Clevo NP50B[BE]", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
91139174 SND_PCI_QUIRK(0x1558, 0x866d, "Clevo NP5[05]PN[HJK]", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
9175+ SND_PCI_QUIRK(0x1558, 0x867c, "Clevo NP7[01]PNP", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
91149176 SND_PCI_QUIRK(0x1558, 0x867d, "Clevo NP7[01]PN[HJK]", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
91159177 SND_PCI_QUIRK(0x1558, 0x8680, "Clevo NJ50LU", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
91169178 SND_PCI_QUIRK(0x1558, 0x8686, "Clevo NH50[CZ]U", ALC256_FIXUP_MIC_NO_PRESENCE_AND_RESUME),
@@ -9185,6 +9247,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 68 unmodified lines
91859247 SND_PCI_QUIRK(0x17aa, 0x3813, "Legion 7i 15IMHG05", ALC287_FIXUP_LEGION_15IMHG05_SPEAKERS),
91869248 SND_PCI_QUIRK(0x17aa, 0x3818, "Lenovo C940", ALC298_FIXUP_LENOVO_SPK_VOLUME),
91879249 SND_PCI_QUIRK(0x17aa, 0x3819, "Lenovo 13s Gen2 ITL", ALC287_FIXUP_13S_GEN2_SPEAKERS),
9250+ SND_PCI_QUIRK(0x17aa, 0x3820, "Yoga Duet 7 13ITL6", ALC287_FIXUP_YOGA7_14ITL_SPEAKERS),
91889251 SND_PCI_QUIRK(0x17aa, 0x3824, "Legion Y9000X 2020", ALC285_FIXUP_LEGION_Y9000X_SPEAKERS),
91899252 SND_PCI_QUIRK(0x17aa, 0x3827, "Ideapad S740", ALC285_FIXUP_IDEAPAD_S740_COEF),
91909253 SND_PCI_QUIRK(0x17aa, 0x3834, "Lenovo IdeaPad Slim 9i 14ITL5", ALC287_FIXUP_YOGA7_14ITL_SPEAKERS),
@@ -9227,6 +9290,14 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 36 unmodified lines
92279290 SND_PCI_QUIRK(0x1c06, 0x2013, "Lemote A1802", ALC269_FIXUP_LEMOTE_A1802),
92289291 SND_PCI_QUIRK(0x1c06, 0x2015, "Lemote A190X", ALC269_FIXUP_LEMOTE_A190X),
92299292 SND_PCI_QUIRK(0x1d05, 0x1132, "TongFang PHxTxX1", ALC256_FIXUP_SET_COEF_DEFAULTS),
9293+ SND_PCI_QUIRK(0x1d05, 0x1096, "TongFang GMxMRxx", ALC269_FIXUP_NO_SHUTUP),
9294+ SND_PCI_QUIRK(0x1d05, 0x1100, "TongFang GKxNRxx", ALC269_FIXUP_NO_SHUTUP),
9295+ SND_PCI_QUIRK(0x1d05, 0x1111, "TongFang GMxZGxx", ALC269_FIXUP_NO_SHUTUP),
9296+ SND_PCI_QUIRK(0x1d05, 0x1119, "TongFang GMxZGxx", ALC269_FIXUP_NO_SHUTUP),
9297+ SND_PCI_QUIRK(0x1d05, 0x1129, "TongFang GMxZGxx", ALC269_FIXUP_NO_SHUTUP),
9298+ SND_PCI_QUIRK(0x1d05, 0x1147, "TongFang GMxTGxx", ALC269_FIXUP_NO_SHUTUP),
9299+ SND_PCI_QUIRK(0x1d05, 0x115c, "TongFang GMxTGxx", ALC269_FIXUP_NO_SHUTUP),
9300+ SND_PCI_QUIRK(0x1d05, 0x121b, "TongFang GMxAGxx", ALC269_FIXUP_NO_SHUTUP),
92309301 SND_PCI_QUIRK(0x1d72, 0x1602, "RedmiBook", ALC255_FIXUP_XIAOMI_HEADSET_MIC),
92319302 SND_PCI_QUIRK(0x1d72, 0x1701, "XiaomiNotebook Pro", ALC298_FIXUP_DELL1_MIC_NO_PRESENCE),
92329303 SND_PCI_QUIRK(0x1d72, 0x1901, "RedmiBook 14", ALC256_FIXUP_ASUS_HEADSET_MIC),
@@ -9234,6 +9305,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 1 unmodified line
92349305 SND_PCI_QUIRK(0x8086, 0x2074, "Intel NUC 8", ALC233_FIXUP_INTEL_NUC8_DMIC),
92359306 SND_PCI_QUIRK(0x8086, 0x2080, "Intel NUC 8 Rugged", ALC256_FIXUP_INTEL_NUC8_RUGGED),
92369307 SND_PCI_QUIRK(0x8086, 0x2081, "Intel NUC 10", ALC256_FIXUP_INTEL_NUC10),
9308+ SND_PCI_QUIRK(0xf111, 0x0001, "Framework Laptop", ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE),
92379309
92389310 #if 0
92399311 /* Below is a quirk table taken from the old code.
sound/pci/lola/lola_pcm.c+2−1
@@ -561,8 +561,9 @@ static snd_pcm_uframes_t lola_pcm_pointer(struct snd_pcm_substream *substream) · 560 unmodified lines
561561 void lola_pcm_update(struct lola *chip, struct lola_pcm *pcm, unsigned int bits)
562562 {
563563 int i;
564+ u8 num_streams = min_t(u8, pcm->num_streams, ARRAY_SIZE(pcm->streams));
564565
565− for (i = 0; bits && i < pcm->num_streams; i++) {
566+ for (i = 0; bits && i < num_streams; i++) {
566567 if (bits & (1 << i)) {
567568 struct lola_stream *str = &pcm->streams[i];
568569 if (str->substream && str->running)
sound/soc/atmel/mchp-pdmc.c+1−0
@@ -966,6 +966,7 @@ static int mchp_pdmc_process(struct snd_pcm_substream *substream, · 965 unmodified lines
966966
967967 static struct snd_dmaengine_pcm_config mchp_pdmc_config = {
968968 .process = mchp_pdmc_process,
969+ .prepare_slave_config = snd_dmaengine_pcm_prepare_slave_config,
969970 };
970971
971972 static int mchp_pdmc_probe(struct platform_device *pdev)
sound/soc/atmel/sam9g20_wm8731.c+0−61
@@ -46,35 +46,6 @@ · 45 unmodified lines
4646 */
4747 #undef ENABLE_MIC_INPUT
4848
49−static struct clk *mclk;
50−
51−static int at91sam9g20ek_set_bias_level(struct snd_soc_card *card,
52− struct snd_soc_dapm_context *dapm,
53− enum snd_soc_bias_level level)
54−{
55− static int mclk_on;
56− int ret = 0;
57−
58− switch (level) {
59− case SND_SOC_BIAS_ON:
60− case SND_SOC_BIAS_PREPARE:
61− if (!mclk_on)
62− ret = clk_enable(mclk);
63− if (ret == 0)
64− mclk_on = 1;
65− break;
66−
67− case SND_SOC_BIAS_OFF:
68− case SND_SOC_BIAS_STANDBY:
69− if (mclk_on)
70− clk_disable(mclk);
71− mclk_on = 0;
72− break;
73− }
74−
75− return ret;
76−}
77−
7849 static const struct snd_soc_dapm_widget at91sam9g20ek_dapm_widgets[] = {
7950 SND_SOC_DAPM_MIC("Int Mic", NULL),
8051 SND_SOC_DAPM_SPK("Ext Spk", NULL),
@@ -135,7 +106,6 @@ static struct snd_soc_card snd_soc_at91sam9g20ek = { · 54 unmodified lines
135106 .owner = THIS_MODULE,
136107 .dai_link = &at91sam9g20ek_dai,
137108 .num_links = 1,
138− .set_bias_level = at91sam9g20ek_set_bias_level,
139109
140110 .dapm_widgets = at91sam9g20ek_dapm_widgets,
141111 .num_dapm_widgets = ARRAY_SIZE(at91sam9g20ek_dapm_widgets),
@@ -148,7 +118,6 @@ static int at91sam9g20ek_audio_probe(struct platform_device *pdev) · 6 unmodified lines
148118 {
149119 struct device_node *np = pdev->dev.of_node;
150120 struct device_node *codec_np, *cpu_np;
151− struct clk *pllb;
152121 struct snd_soc_card *card = &snd_soc_at91sam9g20ek;
153122 int ret;
154123
@@ -162,31 +131,6 @@ static int at91sam9g20ek_audio_probe(struct platform_device *pdev) · 7 unmodified lines
162131 return -EINVAL;
163132 }
164133
165− /*
166− * Codec MCLK is supplied by PCK0 - set it up.
167− */
168− mclk = clk_get(NULL, "pck0");
169− if (IS_ERR(mclk)) {
170− dev_err(&pdev->dev, "Failed to get MCLK\n");
171− ret = PTR_ERR(mclk);
172− goto err;
173− }
174−
175− pllb = clk_get(NULL, "pllb");
176− if (IS_ERR(pllb)) {
177− dev_err(&pdev->dev, "Failed to get PLLB\n");
178− ret = PTR_ERR(pllb);
179− goto err_mclk;
180− }
181− ret = clk_set_parent(mclk, pllb);
182− clk_put(pllb);
183− if (ret != 0) {
184− dev_err(&pdev->dev, "Failed to set MCLK parent\n");
185− goto err_mclk;
186− }
187−
188− clk_set_rate(mclk, MCLK_RATE);
189−
190134 card->dev = &pdev->dev;
191135
192136 /* Parse device node info */
@@ -230,9 +174,6 @@ static int at91sam9g20ek_audio_probe(struct platform_device *pdev) · 37 unmodified lines
230174
231175 return ret;
232176
233−err_mclk:
234− clk_put(mclk);
235− mclk = NULL;
236177 err:
237178 atmel_ssc_put_audio(0);
238179 return ret;
@@ -242,8 +183,6 @@ static int at91sam9g20ek_audio_remove(struct platform_device *pdev) · 3 unmodified lines
242183 {
243184 struct snd_soc_card *card = platform_get_drvdata(pdev);
244185
245− clk_disable(mclk);
246− mclk = NULL;
247186 snd_soc_unregister_card(card);
248187 atmel_ssc_put_audio(0);
249188
sound/soc/codecs/cs35l41-lib.c+6−4
@@ -842,8 +842,8 @@ int cs35l41_otp_unpack(struct device *dev, struct regmap *regmap) · 841 unmodified lines
842842 word_offset = otp_map_match->word_offset;
843843
844844 for (i = 0; i < otp_map_match->num_elements; i++) {
845− dev_dbg(dev, "bitoffset= %d, word_offset=%d, bit_sum mod 32=%d\n",
846− bit_offset, word_offset, bit_sum % 32);
845+ dev_dbg(dev, "bitoffset= %d, word_offset=%d, bit_sum mod 32=%d otp_map[i].size = %d\n",
846+ bit_offset, word_offset, bit_sum % 32, otp_map[i].size);
847847 if (bit_offset + otp_map[i].size - 1 >= 32) {
848848 otp_val = (otp_mem[word_offset] &
849849 GENMASK(31, bit_offset)) >> bit_offset;
@@ -851,12 +851,14 @@ int cs35l41_otp_unpack(struct device *dev, struct regmap *regmap) · 1 unmodified line
851851 GENMASK(bit_offset + otp_map[i].size - 33, 0)) <<
852852 (32 - bit_offset);
853853 bit_offset += otp_map[i].size - 32;
854− } else {
854+ } else if (bit_offset + otp_map[i].size - 1 >= 0) {
855855 otp_val = (otp_mem[word_offset] &
856856 GENMASK(bit_offset + otp_map[i].size - 1, bit_offset)
857857 ) >> bit_offset;
858858 bit_offset += otp_map[i].size;
859− }
859+ } else /* both bit_offset and otp_map[i].size are 0 */
860+ otp_val = 0;
861+
860862 bit_sum += otp_map[i].size;
861863
862864 if (bit_offset == 32) {
sound/soc/codecs/da7219.c+10−4
@@ -446,7 +446,7 @@ static int da7219_tonegen_freq_put(struct snd_kcontrol *kcontrol, · 445 unmodified lines
446446 struct soc_mixer_control *mixer_ctrl =
447447 (struct soc_mixer_control *) kcontrol->private_value;
448448 unsigned int reg = mixer_ctrl->reg;
449− __le16 val;
449+ __le16 val_new, val_old;
450450 int ret;
451451
452452 /*
@@ -454,13 +454,19 @@ static int da7219_tonegen_freq_put(struct snd_kcontrol *kcontrol, · 1 unmodified line
454454 * Therefore we need to convert to little endian here to align with
455455 * HW registers.
456456 */
457− val = cpu_to_le16(ucontrol->value.integer.value[0]);
457+ val_new = cpu_to_le16(ucontrol->value.integer.value[0]);
458458
459459 mutex_lock(&da7219->ctrl_lock);
460− ret = regmap_raw_write(da7219->regmap, reg, &val, sizeof(val));
460+ ret = regmap_raw_read(da7219->regmap, reg, &val_old, sizeof(val_old));
461+ if (ret == 0 && (val_old != val_new))
462+ ret = regmap_raw_write(da7219->regmap, reg,
463+ &val_new, sizeof(val_new));
461464 mutex_unlock(&da7219->ctrl_lock);
462465
463− return ret;
466+ if (ret < 0)
467+ return ret;
468+
469+ return val_old != val_new;
464470 }
465471
466472
sound/soc/codecs/lpass-rx-macro.c+10−4
@@ -3566,12 +3566,16 @@ static int rx_macro_probe(struct platform_device *pdev) · 3565 unmodified lines
35663566 return PTR_ERR(rx->pds);
35673567
35683568 base = devm_platform_ioremap_resource(pdev, 0);
3569− if (IS_ERR(base))
3570− return PTR_ERR(base);
3569+ if (IS_ERR(base)) {
3570+ ret = PTR_ERR(base);
3571+ goto err;
3572+ }
35713573
35723574 rx->regmap = devm_regmap_init_mmio(dev, base, &rx_regmap_config);
3573− if (IS_ERR(rx->regmap))
3574− return PTR_ERR(rx->regmap);
3575+ if (IS_ERR(rx->regmap)) {
3576+ ret = PTR_ERR(rx->regmap);
3577+ goto err;
3578+ }
35753579
35763580 dev_set_drvdata(dev, rx);
35773581
@@ -3632,6 +3636,8 @@ err_mclk: · 54 unmodified lines
36323636 err_dcodec:
36333637 clk_disable_unprepare(rx->macro);
36343638 err:
3639+ lpass_macro_pds_exit(rx->pds);
3640+
36353641 return ret;
36363642 }
36373643
sound/soc/codecs/lpass-tx-macro.c+10−4
@@ -1828,8 +1828,10 @@ static int tx_macro_probe(struct platform_device *pdev) · 1827 unmodified lines
18281828 return PTR_ERR(tx->pds);
18291829
18301830 base = devm_platform_ioremap_resource(pdev, 0);
1831− if (IS_ERR(base))
1832− return PTR_ERR(base);
1831+ if (IS_ERR(base)) {
1832+ ret = PTR_ERR(base);
1833+ goto err;
1834+ }
18331835
18341836 /* Update defaults for lpass sc7280 */
18351837 if (of_device_is_compatible(np, "qcom,sc7280-lpass-tx-macro")) {
@@ -1846,8 +1848,10 @@ static int tx_macro_probe(struct platform_device *pdev) · 10 unmodified lines
18461848 }
18471849
18481850 tx->regmap = devm_regmap_init_mmio(dev, base, &tx_regmap_config);
1849− if (IS_ERR(tx->regmap))
1850− return PTR_ERR(tx->regmap);
1851+ if (IS_ERR(tx->regmap)) {
1852+ ret = PTR_ERR(tx->regmap);
1853+ goto err;
1854+ }
18511855
18521856 dev_set_drvdata(dev, tx);
18531857
@@ -1907,6 +1911,8 @@ err_mclk: · 53 unmodified lines
19071911 err_dcodec:
19081912 clk_disable_unprepare(tx->macro);
19091913 err:
1914+ lpass_macro_pds_exit(tx->pds);
1915+
19101916 return ret;
19111917 }
19121918
sound/soc/codecs/lpass-va-macro.c+6−2
@@ -1434,8 +1434,10 @@ static int va_macro_probe(struct platform_device *pdev) · 1433 unmodified lines
14341434 va->dmic_clk_div = VA_MACRO_CLK_DIV_2;
14351435 } else {
14361436 ret = va_macro_validate_dmic_sample_rate(sample_rate, va);
1437− if (!ret)
1438− return -EINVAL;
1437+ if (!ret) {
1438+ ret = -EINVAL;
1439+ goto err;
1440+ }
14391441 }
14401442
14411443 base = devm_platform_ioremap_resource(pdev, 0);
@@ -1492,6 +1494,8 @@ err_mclk: · 50 unmodified lines
14921494 err_dcodec:
14931495 clk_disable_unprepare(va->macro);
14941496 err:
1497+ lpass_macro_pds_exit(va->pds);
1498+
14951499 return ret;
14961500 }
14971501
sound/soc/codecs/max98090.c+4−1
@@ -413,6 +413,9 @@ static int max98090_put_enab_tlv(struct snd_kcontrol *kcontrol, · 412 unmodified lines
413413
414414 val = (val >> mc->shift) & mask;
415415
416+ if (sel < 0 || sel > mc->max)
417+ return -EINVAL;
418+
416419 *select = sel;
417420
418421 /* Setting a volume is only valid if it is already On */
@@ -427,7 +430,7 @@ static int max98090_put_enab_tlv(struct snd_kcontrol *kcontrol, · 8 unmodified lines
427430 mask << mc->shift,
428431 sel << mc->shift);
429432
430− return 0;
433+ return *select != val;
431434 }
432435
433436 static const char *max98090_perf_pwr_text[] =
sound/soc/codecs/msm8916-wcd-digital.c+8−1
@@ -1206,9 +1206,16 @@ static int msm8916_wcd_digital_probe(struct platform_device *pdev) · 1205 unmodified lines
12061206
12071207 dev_set_drvdata(dev, priv);
12081208
1209− return devm_snd_soc_register_component(dev, &msm8916_wcd_digital,
1209+ ret = devm_snd_soc_register_component(dev, &msm8916_wcd_digital,
12101210 msm8916_wcd_digital_dai,
12111211 ARRAY_SIZE(msm8916_wcd_digital_dai));
1212+ if (ret)
1213+ goto err_mclk;
1214+
1215+ return 0;
1216+
1217+err_mclk:
1218+ clk_disable_unprepare(priv->mclk);
12121219 err_clk:
12131220 clk_disable_unprepare(priv->ahbclk);
12141221 return ret;
sound/soc/codecs/rk817_codec.c+1−1
@@ -489,7 +489,7 @@ static int rk817_platform_probe(struct platform_device *pdev) · 488 unmodified lines
489489
490490 rk817_codec_parse_dt_property(&pdev->dev, rk817_codec_data);
491491
492− rk817_codec_data->mclk = clk_get(pdev->dev.parent, "mclk");
492+ rk817_codec_data->mclk = devm_clk_get(pdev->dev.parent, "mclk");
493493 if (IS_ERR(rk817_codec_data->mclk)) {
494494 dev_dbg(&pdev->dev, "Unable to get mclk\n");
495495 ret = -ENXIO;
sound/soc/codecs/rt5682.c+13−7
@@ -1100,6 +1100,15 @@ void rt5682_jack_detect_handler(struct work_struct *work) · 1099 unmodified lines
11001100 return;
11011101 }
11021102
1103+ if (rt5682->is_sdw) {
1104+ if (pm_runtime_status_suspended(rt5682->slave->dev.parent)) {
1105+ dev_dbg(&rt5682->slave->dev,
1106+ "%s: parent device is pm_runtime_status_suspended, skipping jack detection\n",
1107+ __func__);
1108+ return;
1109+ }
1110+ }
1111+
11031112 dapm = snd_soc_component_get_dapm(rt5682->component);
11041113
11051114 snd_soc_dapm_mutex_lock(dapm);
@@ -2822,14 +2831,11 @@ static int rt5682_bclk_set_rate(struct clk_hw *hw, unsigned long rate, · 1716 unmodified lines
28222831
28232832 for_each_component_dais(component, dai)
28242833 if (dai->id == RT5682_AIF1)
2825− break;
2826− if (!dai) {
2827− dev_err(rt5682->i2c_dev, "dai %d not found in component\n",
2828− RT5682_AIF1);
2829− return -ENODEV;
2830− }
2834+ return rt5682_set_bclk1_ratio(dai, factor);
28312835
2832− return rt5682_set_bclk1_ratio(dai, factor);
2836+ dev_err(rt5682->i2c_dev, "dai %d not found in component\n",
2837+ RT5682_AIF1);
2838+ return -ENODEV;
28332839 }
28342840
28352841 static const struct clk_ops rt5682_dai_clk_ops[RT5682_DAI_NUM_CLKS] = {
sound/soc/codecs/rt5682s.c+4−7
@@ -2687,14 +2687,11 @@ static int rt5682s_bclk_set_rate(struct clk_hw *hw, unsigned long rate, · 2686 unmodified lines
26872687
26882688 for_each_component_dais(component, dai)
26892689 if (dai->id == RT5682S_AIF1)
2690− break;
2691− if (!dai) {
2692− dev_err(component->dev, "dai %d not found in component\n",
2693− RT5682S_AIF1);
2694− return -ENODEV;
2695− }
2690+ return rt5682s_set_bclk1_ratio(dai, factor);
26962691
2697− return rt5682s_set_bclk1_ratio(dai, factor);
2692+ dev_err(component->dev, "dai %d not found in component\n",
2693+ RT5682S_AIF1);
2694+ return -ENODEV;
26982695 }
26992696
27002697 static const struct clk_ops rt5682s_dai_clk_ops[RT5682S_DAI_NUM_CLKS] = {
sound/soc/codecs/rt711.c+7−0
@@ -245,6 +245,13 @@ static void rt711_jack_detect_handler(struct work_struct *work) · 244 unmodified lines
245245 if (!rt711->component->card->instantiated)
246246 return;
247247
248+ if (pm_runtime_status_suspended(rt711->slave->dev.parent)) {
249+ dev_dbg(&rt711->slave->dev,
250+ "%s: parent device is pm_runtime_status_suspended, skipping jack detection\n",
251+ __func__);
252+ return;
253+ }
254+
248255 reg = RT711_VERB_GET_PIN_SENSE | RT711_HP_OUT;
249256 ret = regmap_read(rt711->regmap, reg, &jack_status);
250257 if (ret < 0)
sound/soc/codecs/rt9120.c+0−1
@@ -341,7 +341,6 @@ static int rt9120_get_reg_size(unsigned int reg) · 340 unmodified lines
341341 {
342342 switch (reg) {
343343 case 0x00:
344− case 0x09:
345344 case 0x20 ... 0x27:
346345 return 2;
347346 case 0x30 ... 0x3D:
sound/soc/codecs/wcd934x.c+1−25
@@ -1274,29 +1274,7 @@ static int wcd934x_set_sido_input_src(struct wcd934x_codec *wcd, int sido_src) · 1273 unmodified lines
12741274 if (sido_src == wcd->sido_input_src)
12751275 return 0;
12761276
1277− if (sido_src == SIDO_SOURCE_INTERNAL) {
1278− regmap_update_bits(wcd->regmap, WCD934X_ANA_BUCK_CTL,
1279− WCD934X_ANA_BUCK_HI_ACCU_EN_MASK, 0);
1280− usleep_range(100, 110);
1281− regmap_update_bits(wcd->regmap, WCD934X_ANA_BUCK_CTL,
1282− WCD934X_ANA_BUCK_HI_ACCU_PRE_ENX_MASK, 0x0);
1283− usleep_range(100, 110);
1284− regmap_update_bits(wcd->regmap, WCD934X_ANA_RCO,
1285− WCD934X_ANA_RCO_BG_EN_MASK, 0);
1286− usleep_range(100, 110);
1287− regmap_update_bits(wcd->regmap, WCD934X_ANA_BUCK_CTL,
1288− WCD934X_ANA_BUCK_PRE_EN1_MASK,
1289− WCD934X_ANA_BUCK_PRE_EN1_ENABLE);
1290− usleep_range(100, 110);
1291− regmap_update_bits(wcd->regmap, WCD934X_ANA_BUCK_CTL,
1292− WCD934X_ANA_BUCK_PRE_EN2_MASK,
1293− WCD934X_ANA_BUCK_PRE_EN2_ENABLE);
1294− usleep_range(100, 110);
1295− regmap_update_bits(wcd->regmap, WCD934X_ANA_BUCK_CTL,
1296− WCD934X_ANA_BUCK_HI_ACCU_EN_MASK,
1297− WCD934X_ANA_BUCK_HI_ACCU_ENABLE);
1298− usleep_range(100, 110);
1299− } else if (sido_src == SIDO_SOURCE_RCO_BG) {
1277+ if (sido_src == SIDO_SOURCE_RCO_BG) {
13001278 regmap_update_bits(wcd->regmap, WCD934X_ANA_RCO,
13011279 WCD934X_ANA_RCO_BG_EN_MASK,
13021280 WCD934X_ANA_RCO_BG_ENABLE);
@@ -1382,8 +1360,6 @@ static int wcd934x_disable_ana_bias_and_syclk(struct wcd934x_codec *wcd) · 79 unmodified lines
13821360 regmap_update_bits(wcd->regmap, WCD934X_CLK_SYS_MCLK_PRG,
13831361 WCD934X_EXT_CLK_BUF_EN_MASK |
13841362 WCD934X_MCLK_EN_MASK, 0x0);
1385− wcd934x_set_sido_input_src(wcd, SIDO_SOURCE_INTERNAL);
1386−
13871363 regmap_update_bits(wcd->regmap, WCD934X_ANA_BIAS,
13881364 WCD934X_ANA_BIAS_EN_MASK, 0);
13891365 regmap_update_bits(wcd->regmap, WCD934X_ANA_BIAS,
sound/soc/codecs/wm8731.c+11−8
@@ -602,7 +602,7 @@ static int wm8731_hw_init(struct device *dev, struct wm8731_priv *wm8731) · 601 unmodified lines
602602 ret = wm8731_reset(wm8731->regmap);
603603 if (ret < 0) {
604604 dev_err(dev, "Failed to issue reset: %d\n", ret);
605− goto err_regulator_enable;
605+ goto err;
606606 }
607607
608608 /* Clear POWEROFF, keep everything else disabled */
@@ -619,10 +619,7 @@ static int wm8731_hw_init(struct device *dev, struct wm8731_priv *wm8731) · 10 unmodified lines
619619
620620 regcache_mark_dirty(wm8731->regmap);
621621
622−err_regulator_enable:
623− /* Regulators will be enabled by bias management */
624− regulator_bulk_disable(ARRAY_SIZE(wm8731->supplies), wm8731->supplies);
625−
622+err:
626623 return ret;
627624 }
628625
@@ -760,21 +757,27 @@ static int wm8731_i2c_probe(struct i2c_client *i2c, · 131 unmodified lines
760757 ret = PTR_ERR(wm8731->regmap);
761758 dev_err(&i2c->dev, "Failed to allocate register map: %d\n",
762759 ret);
763− return ret;
760+ goto err_regulator_enable;
764761 }
765762
766763 ret = wm8731_hw_init(&i2c->dev, wm8731);
767764 if (ret != 0)
768− return ret;
765+ goto err_regulator_enable;
769766
770767 ret = devm_snd_soc_register_component(&i2c->dev,
771768 &soc_component_dev_wm8731, &wm8731_dai, 1);
772769 if (ret != 0) {
773770 dev_err(&i2c->dev, "Failed to register CODEC: %d\n", ret);
774− return ret;
771+ goto err_regulator_enable;
775772 }
776773
777774 return 0;
775+
776+err_regulator_enable:
777+ /* Regulators will be enabled by bias management */
778+ regulator_bulk_disable(ARRAY_SIZE(wm8731->supplies), wm8731->supplies);
779+
780+ return ret;
778781 }
779782
780783 static const struct i2c_device_id wm8731_i2c_id[] = {
sound/soc/codecs/wm8958-dsp2.c+4−4
@@ -530,7 +530,7 @@ static int wm8958_mbc_put(struct snd_kcontrol *kcontrol, · 529 unmodified lines
530530
531531 wm8958_dsp_apply(component, mbc, wm8994->mbc_ena[mbc]);
532532
533− return 0;
533+ return 1;
534534 }
535535
536536 #define WM8958_MBC_SWITCH(xname, xval) {\
@@ -656,7 +656,7 @@ static int wm8958_vss_put(struct snd_kcontrol *kcontrol, · 119 unmodified lines
656656
657657 wm8958_dsp_apply(component, vss, wm8994->vss_ena[vss]);
658658
659− return 0;
659+ return 1;
660660 }
661661
662662
@@ -730,7 +730,7 @@ static int wm8958_hpf_put(struct snd_kcontrol *kcontrol, · 67 unmodified lines
730730
731731 wm8958_dsp_apply(component, hpf % 3, ucontrol->value.integer.value[0]);
732732
733− return 0;
733+ return 1;
734734 }
735735
736736 #define WM8958_HPF_SWITCH(xname, xval) {\
@@ -824,7 +824,7 @@ static int wm8958_enh_eq_put(struct snd_kcontrol *kcontrol, · 87 unmodified lines
824824
825825 wm8958_dsp_apply(component, eq, ucontrol->value.integer.value[0]);
826826
827− return 0;
827+ return 1;
828828 }
829829
830830 #define WM8958_ENH_EQ_SWITCH(xname, xval) {\
sound/soc/codecs/wm_adsp.c+5−5
@@ -97,13 +97,13 @@ struct wm_adsp_system_config_xm_hdr { · 96 unmodified lines
9797 __be32 wdma[8];
9898 __be32 build_job_name[3];
9999 __be32 build_job_number;
100−};
100+} __packed;
101101
102102 struct wm_halo_system_config_xm_hdr {
103103 __be32 halo_heartbeat;
104104 __be32 build_job_name[3];
105105 __be32 build_job_number;
106−};
106+} __packed;
107107
108108 struct wm_adsp_alg_xm_struct {
109109 __be32 magic;
@@ -114,13 +114,13 @@ struct wm_adsp_alg_xm_struct { · 4 unmodified lines
114114 __be32 high_water_mark;
115115 __be32 low_water_mark;
116116 __be64 smoothed_power;
117−};
117+} __packed;
118118
119119 struct wm_adsp_host_buf_coeff_v1 {
120120 __be32 host_buf_ptr; /* Host buffer pointer */
121121 __be32 versions; /* Version numbers */
122122 __be32 name[4]; /* The buffer name */
123−};
123+} __packed;
124124
125125 struct wm_adsp_buffer {
126126 __be32 buf1_base; /* Base addr of first buffer area */
@@ -141,7 +141,7 @@ struct wm_adsp_buffer { · 14 unmodified lines
141141 __be32 min_free; /* min free space since stream start */
142142 __be32 blocks_written[2]; /* total blocks written (64 bit) */
143143 __be32 words_written[2]; /* total words written (64 bit) */
144−};
144+} __packed;
145145
146146 struct wm_adsp_compr;
147147
sound/soc/fsl/fsl_sai.c+1−1
@@ -372,7 +372,7 @@ static int fsl_sai_set_bclk(struct snd_soc_dai *dai, bool tx, u32 freq) · 371 unmodified lines
372372 continue;
373373 if (ratio == 1 && !support_1_1_ratio)
374374 continue;
375− else if (ratio & 1)
375+ if ((ratio & 1) && ratio > 1)
376376 continue;
377377
378378 diff = abs((long)clk_rate - ratio * freq);
sound/soc/generic/simple-card-utils.c+5−3
@@ -322,7 +322,7 @@ void asoc_simple_shutdown(struct snd_pcm_substream *substream) · 321 unmodified lines
322322
323323 if (props->mclk_fs && !dai->clk_fixed && !snd_soc_dai_active(cpu_dai))
324324 snd_soc_dai_set_sysclk(cpu_dai,
325− 0, 0, SND_SOC_CLOCK_IN);
325+ 0, 0, SND_SOC_CLOCK_OUT);
326326
327327 asoc_simple_clk_disable(dai);
328328 }
@@ -364,13 +364,15 @@ static int asoc_simple_set_tdm(struct snd_soc_dai *dai, · 35 unmodified lines
364364 struct snd_pcm_hw_params *params)
365365 {
366366 int sample_bits = params_width(params);
367− int slot_width = simple_dai->slot_width;
368− int slot_count = simple_dai->slots;
367+ int slot_width, slot_count;
369368 int i, ret;
370369
371370 if (!simple_dai || !simple_dai->tdm_width_map)
372371 return 0;
373372
373+ slot_width = simple_dai->slot_width;
374+ slot_count = simple_dai->slots;
375+
374376 if (slot_width == 0)
375377 slot_width = sample_bits;
376378
sound/soc/intel/boards/sof_es8336.c+89−28
@@ -27,9 +27,11 @@ · 26 unmodified lines
2727 #define SOF_ES8336_SSP_CODEC(quirk) ((quirk) & GENMASK(3, 0))
2828 #define SOF_ES8336_SSP_CODEC_MASK (GENMASK(3, 0))
2929
30−#define SOF_ES8336_TGL_GPIO_QUIRK BIT(4)
30+#define SOF_ES8336_SPEAKERS_EN_GPIO1_QUIRK BIT(4)
3131 #define SOF_ES8336_ENABLE_DMIC BIT(5)
3232 #define SOF_ES8336_JD_INVERTED BIT(6)
33+#define SOF_ES8336_HEADPHONE_GPIO BIT(7)
34+#define SOC_ES8336_HEADSET_MIC1 BIT(8)
3335
3436 static unsigned long quirk;
3537
@@ -39,7 +41,7 @@ MODULE_PARM_DESC(quirk, "Board-specific quirk override"); · 3 unmodified lines
3941
4042 struct sof_es8336_private {
4143 struct device *codec_dev;
42− struct gpio_desc *gpio_pa;
44+ struct gpio_desc *gpio_speakers, *gpio_headphone;
4345 struct snd_soc_jack jack;
4446 struct list_head hdmi_pcm_list;
4547 bool speaker_en;
@@ -51,19 +53,31 @@ struct sof_hdmi_pcm { · 5 unmodified lines
5153 int device;
5254 };
5355
54−static const struct acpi_gpio_params pa_enable_gpio = { 0, 0, true };
55−static const struct acpi_gpio_mapping acpi_es8336_gpios[] = {
56− { "pa-enable-gpios", &pa_enable_gpio, 1 },
56+static const struct acpi_gpio_params enable_gpio0 = { 0, 0, true };
57+static const struct acpi_gpio_params enable_gpio1 = { 1, 0, true };
58+
59+static const struct acpi_gpio_mapping acpi_speakers_enable_gpio0[] = {
60+ { "speakers-enable-gpios", &enable_gpio0, 1 },
5761 { }
5862 };
5963
60−static const struct acpi_gpio_params quirk_pa_enable_gpio = { 1, 0, true };
61−static const struct acpi_gpio_mapping quirk_acpi_es8336_gpios[] = {
62− { "pa-enable-gpios", &quirk_pa_enable_gpio, 1 },
64+static const struct acpi_gpio_mapping acpi_speakers_enable_gpio1[] = {
65+ { "speakers-enable-gpios", &enable_gpio1, 1 },
66+};
67+
68+static const struct acpi_gpio_mapping acpi_enable_both_gpios[] = {
69+ { "speakers-enable-gpios", &enable_gpio0, 1 },
70+ { "headphone-enable-gpios", &enable_gpio1, 1 },
6371 { }
6472 };
6573
66−static const struct acpi_gpio_mapping *gpio_mapping = acpi_es8336_gpios;
74+static const struct acpi_gpio_mapping acpi_enable_both_gpios_rev_order[] = {
75+ { "speakers-enable-gpios", &enable_gpio1, 1 },
76+ { "headphone-enable-gpios", &enable_gpio0, 1 },
77+ { }
78+};
79+
80+static const struct acpi_gpio_mapping *gpio_mapping = acpi_speakers_enable_gpio0;
6781
6882 static void log_quirks(struct device *dev)
6983 {
@@ -71,10 +85,14 @@ static void log_quirks(struct device *dev) · 1 unmodified line
7185 dev_info(dev, "quirk SSP%ld\n", SOF_ES8336_SSP_CODEC(quirk));
7286 if (quirk & SOF_ES8336_ENABLE_DMIC)
7387 dev_info(dev, "quirk DMIC enabled\n");
74− if (quirk & SOF_ES8336_TGL_GPIO_QUIRK)
75− dev_info(dev, "quirk TGL GPIO enabled\n");
88+ if (quirk & SOF_ES8336_SPEAKERS_EN_GPIO1_QUIRK)
89+ dev_info(dev, "Speakers GPIO1 quirk enabled\n");
90+ if (quirk & SOF_ES8336_HEADPHONE_GPIO)
91+ dev_info(dev, "quirk headphone GPIO enabled\n");
7692 if (quirk & SOF_ES8336_JD_INVERTED)
7793 dev_info(dev, "quirk JD inverted enabled\n");
94+ if (quirk & SOC_ES8336_HEADSET_MIC1)
95+ dev_info(dev, "quirk headset at mic1 port enabled\n");
7896 }
7997
8098 static int sof_es8316_speaker_power_event(struct snd_soc_dapm_widget *w,
@@ -83,12 +101,23 @@ static int sof_es8316_speaker_power_event(struct snd_soc_dapm_widget *w, · 2 unmodified lines
83101 struct snd_soc_card *card = w->dapm->card;
84102 struct sof_es8336_private *priv = snd_soc_card_get_drvdata(card);
85103
104+ if (priv->speaker_en == !SND_SOC_DAPM_EVENT_ON(event))
105+ return 0;
106+
107+ priv->speaker_en = !SND_SOC_DAPM_EVENT_ON(event);
108+
109+ if (SND_SOC_DAPM_EVENT_ON(event))
110+ msleep(70);
111+
112+ gpiod_set_value_cansleep(priv->gpio_speakers, priv->speaker_en);
113+
114+ if (!(quirk & SOF_ES8336_HEADPHONE_GPIO))
115+ return 0;
116+
86117 if (SND_SOC_DAPM_EVENT_ON(event))
87− priv->speaker_en = false;
88− else
89− priv->speaker_en = true;
118+ msleep(70);
90119
91− gpiod_set_value_cansleep(priv->gpio_pa, priv->speaker_en);
120+ gpiod_set_value_cansleep(priv->gpio_headphone, priv->speaker_en);
92121
93122 return 0;
94123 }
@@ -114,18 +143,23 @@ static const struct snd_soc_dapm_route sof_es8316_audio_map[] = { · 19 unmodified lines
114143
115144 /*
116145 * There is no separate speaker output instead the speakers are muxed to
117− * the HP outputs. The mux is controlled by the "Speaker Power" supply.
146+ * the HP outputs. The mux is controlled Speaker and/or headphone switch.
118147 */
119148 {"Speaker", NULL, "HPOL"},
120149 {"Speaker", NULL, "HPOR"},
121150 {"Speaker", NULL, "Speaker Power"},
122151 };
123152
124−static const struct snd_soc_dapm_route sof_es8316_intmic_in1_map[] = {
153+static const struct snd_soc_dapm_route sof_es8316_headset_mic2_map[] = {
125154 {"MIC1", NULL, "Internal Mic"},
126155 {"MIC2", NULL, "Headset Mic"},
127156 };
128157
158+static const struct snd_soc_dapm_route sof_es8316_headset_mic1_map[] = {
159+ {"MIC2", NULL, "Internal Mic"},
160+ {"MIC1", NULL, "Headset Mic"},
161+};
162+
129163 static const struct snd_soc_dapm_route dmic_map[] = {
130164 /* digital mics */
131165 {"DMic", NULL, "SoC DMIC"},
@@ -199,8 +233,13 @@ static int sof_es8316_init(struct snd_soc_pcm_runtime *runtime) · 67 unmodified lines
199233
200234 card->dapm.idle_bias_off = true;
201235
202− custom_map = sof_es8316_intmic_in1_map;
203− num_routes = ARRAY_SIZE(sof_es8316_intmic_in1_map);
236+ if (quirk & SOC_ES8336_HEADSET_MIC1) {
237+ custom_map = sof_es8316_headset_mic1_map;
238+ num_routes = ARRAY_SIZE(sof_es8316_headset_mic1_map);
239+ } else {
240+ custom_map = sof_es8316_headset_mic2_map;
241+ num_routes = ARRAY_SIZE(sof_es8316_headset_mic2_map);
242+ }
204243
205244 ret = snd_soc_dapm_add_routes(&card->dapm, custom_map, num_routes);
206245 if (ret)
@@ -233,8 +272,14 @@ static int sof_es8336_quirk_cb(const struct dmi_system_id *id) · 26 unmodified lines
233272 {
234273 quirk = (unsigned long)id->driver_data;
235274
236− if (quirk & SOF_ES8336_TGL_GPIO_QUIRK)
237− gpio_mapping = quirk_acpi_es8336_gpios;
275+ if (quirk & SOF_ES8336_HEADPHONE_GPIO) {
276+ if (quirk & SOF_ES8336_SPEAKERS_EN_GPIO1_QUIRK)
277+ gpio_mapping = acpi_enable_both_gpios;
278+ else
279+ gpio_mapping = acpi_enable_both_gpios_rev_order;
280+ } else if (quirk & SOF_ES8336_SPEAKERS_EN_GPIO1_QUIRK) {
281+ gpio_mapping = acpi_speakers_enable_gpio1;
282+ }
238283
239284 return 1;
240285 }
@@ -257,7 +302,16 @@ static const struct dmi_system_id sof_es8336_quirk_table[] = { · 16 unmodified lines
257302 DMI_MATCH(DMI_SYS_VENDOR, "IP3 tech"),
258303 DMI_MATCH(DMI_BOARD_NAME, "WN1"),
259304 },
260− .driver_data = (void *)(SOF_ES8336_TGL_GPIO_QUIRK)
305+ .driver_data = (void *)(SOF_ES8336_SPEAKERS_EN_GPIO1_QUIRK)
306+ },
307+ {
308+ .callback = sof_es8336_quirk_cb,
309+ .matches = {
310+ DMI_MATCH(DMI_SYS_VENDOR, "HUAWEI"),
311+ DMI_MATCH(DMI_BOARD_NAME, "BOHB-WAX9-PCB-B2"),
312+ },
313+ .driver_data = (void *)(SOF_ES8336_HEADPHONE_GPIO |
314+ SOC_ES8336_HEADSET_MIC1)
261315 },
262316 {}
263317 };
@@ -585,10 +639,17 @@ static int sof_es8336_probe(struct platform_device *pdev) · 321 unmodified lines
585639 if (ret)
586640 dev_warn(codec_dev, "unable to add GPIO mapping table\n");
587641
588− priv->gpio_pa = gpiod_get_optional(codec_dev, "pa-enable", GPIOD_OUT_LOW);
589− if (IS_ERR(priv->gpio_pa)) {
590− ret = dev_err_probe(dev, PTR_ERR(priv->gpio_pa),
591− "could not get pa-enable GPIO\n");
642+ priv->gpio_speakers = gpiod_get_optional(codec_dev, "speakers-enable", GPIOD_OUT_LOW);
643+ if (IS_ERR(priv->gpio_speakers)) {
644+ ret = dev_err_probe(dev, PTR_ERR(priv->gpio_speakers),
645+ "could not get speakers-enable GPIO\n");
646+ goto err_put_codec;
647+ }
648+
649+ priv->gpio_headphone = gpiod_get_optional(codec_dev, "headphone-enable", GPIOD_OUT_LOW);
650+ if (IS_ERR(priv->gpio_headphone)) {
651+ ret = dev_err_probe(dev, PTR_ERR(priv->gpio_headphone),
652+ "could not get headphone-enable GPIO\n");
592653 goto err_put_codec;
593654 }
594655
@@ -604,7 +665,7 @@ static int sof_es8336_probe(struct platform_device *pdev) · 9 unmodified lines
604665
605666 ret = devm_snd_soc_register_card(dev, card);
606667 if (ret) {
607− gpiod_put(priv->gpio_pa);
668+ gpiod_put(priv->gpio_speakers);
608669 dev_err(dev, "snd_soc_register_card failed: %d\n", ret);
609670 goto err_put_codec;
610671 }
@@ -622,7 +683,7 @@ static int sof_es8336_remove(struct platform_device *pdev) · 11 unmodified lines
622683 struct snd_soc_card *card = platform_get_drvdata(pdev);
623684 struct sof_es8336_private *priv = snd_soc_card_get_drvdata(card);
624685
625− gpiod_put(priv->gpio_pa);
686+ gpiod_put(priv->gpio_speakers);
626687 device_remove_software_node(priv->codec_dev);
627688 put_device(priv->codec_dev);
628689
sound/soc/intel/boards/sof_rt5682.c+13−0
@@ -212,6 +212,19 @@ static const struct dmi_system_id sof_rt5682_quirk_table[] = { · 211 unmodified lines
212212 SOF_SSP_BT_OFFLOAD_PRESENT),
213213
214214 },
215+ {
216+ .callback = sof_rt5682_quirk_cb,
217+ .matches = {
218+ DMI_MATCH(DMI_PRODUCT_FAMILY, "Google_Brya"),
219+ DMI_MATCH(DMI_OEM_STRING, "AUDIO-MAX98360_ALC5682I_I2S_AMP_SSP2"),
220+ },
221+ .driver_data = (void *)(SOF_RT5682_MCLK_EN |
222+ SOF_RT5682_SSP_CODEC(0) |
223+ SOF_SPEAKER_AMP_PRESENT |
224+ SOF_MAX98360A_SPEAKER_AMP_PRESENT |
225+ SOF_RT5682_SSP_AMP(2) |
226+ SOF_RT5682_NUM_HDMIDEV(4)),
227+ },
215228 {}
216229 };
217230
sound/soc/intel/common/soc-acpi-intel-tgl-match.c+2−2
@@ -132,13 +132,13 @@ static const struct snd_soc_acpi_adr_device mx8373_1_adr[] = { · 131 unmodified lines
132132 {
133133 .adr = 0x000123019F837300ull,
134134 .num_endpoints = 1,
135− .endpoints = &spk_l_endpoint,
135+ .endpoints = &spk_r_endpoint,
136136 .name_prefix = "Right"
137137 },
138138 {
139139 .adr = 0x000127019F837300ull,
140140 .num_endpoints = 1,
141− .endpoints = &spk_r_endpoint,
141+ .endpoints = &spk_l_endpoint,
142142 .name_prefix = "Left"
143143 }
144144 };
sound/soc/meson/aiu-acodec-ctrl.c+4−1
@@ -58,7 +58,7 @@ static int aiu_acodec_ctrl_mux_put_enum(struct snd_kcontrol *kcontrol, · 57 unmodified lines
5858
5959 snd_soc_dapm_mux_update_power(dapm, kcontrol, mux, e, NULL);
6060
61− return 0;
61+ return 1;
6262 }
6363
6464 static SOC_ENUM_SINGLE_DECL(aiu_acodec_ctrl_mux_enum, AIU_ACODEC_CTRL,
@@ -193,6 +193,9 @@ static const struct snd_soc_component_driver aiu_acodec_ctrl_component = { · 128 unmodified lines
193193 .of_xlate_dai_name = aiu_acodec_of_xlate_dai_name,
194194 .endianness = 1,
195195 .non_legacy_dai_naming = 1,
196+#ifdef CONFIG_DEBUG_FS
197+ .debugfs_prefix = "acodec",
198+#endif
196199 };
197200
198201 int aiu_acodec_ctrl_register_component(struct device *dev)
sound/soc/meson/aiu-codec-ctrl.c+4−1
@@ -57,7 +57,7 @@ static int aiu_codec_ctrl_mux_put_enum(struct snd_kcontrol *kcontrol, · 56 unmodified lines
5757
5858 snd_soc_dapm_mux_update_power(dapm, kcontrol, mux, e, NULL);
5959
60− return 0;
60+ return 1;
6161 }
6262
6363 static SOC_ENUM_SINGLE_DECL(aiu_hdmi_ctrl_mux_enum, AIU_HDMI_CLK_DATA_CTRL,
@@ -140,6 +140,9 @@ static const struct snd_soc_component_driver aiu_hdmi_ctrl_component = { · 76 unmodified lines
140140 .of_xlate_dai_name = aiu_hdmi_of_xlate_dai_name,
141141 .endianness = 1,
142142 .non_legacy_dai_naming = 1,
143+#ifdef CONFIG_DEBUG_FS
144+ .debugfs_prefix = "hdmi",
145+#endif
143146 };
144147
145148 int aiu_hdmi_ctrl_register_component(struct device *dev)
sound/soc/meson/aiu.c+3−0
@@ -103,6 +103,9 @@ static const struct snd_soc_component_driver aiu_cpu_component = { · 102 unmodified lines
103103 .pointer = aiu_fifo_pointer,
104104 .probe = aiu_cpu_component_probe,
105105 .remove = aiu_cpu_component_remove,
106+#ifdef CONFIG_DEBUG_FS
107+ .debugfs_prefix = "cpu",
108+#endif
106109 };
107110
108111 static struct snd_soc_dai_driver aiu_cpu_dai_drv[] = {
sound/soc/meson/axg-card.c+0−1
@@ -320,7 +320,6 @@ static int axg_card_add_link(struct snd_soc_card *card, struct device_node *np, · 319 unmodified lines
320320
321321 dai_link->cpus = cpu;
322322 dai_link->num_cpus = 1;
323− dai_link->nonatomic = true;
324323
325324 ret = meson_card_parse_dai(card, np, &dai_link->cpus->of_node,
326325 &dai_link->cpus->dai_name);
sound/soc/meson/axg-tdm-interface.c+5−21
@@ -351,29 +351,13 @@ static int axg_tdm_iface_hw_free(struct snd_pcm_substream *substream, · 350 unmodified lines
351351 return 0;
352352 }
353353
354−static int axg_tdm_iface_trigger(struct snd_pcm_substream *substream,
355− int cmd,
354+static int axg_tdm_iface_prepare(struct snd_pcm_substream *substream,
356355 struct snd_soc_dai *dai)
357356 {
358− struct axg_tdm_stream *ts =
359− snd_soc_dai_get_dma_data(dai, substream);
360−
361− switch (cmd) {
362− case SNDRV_PCM_TRIGGER_START:
363− case SNDRV_PCM_TRIGGER_RESUME:
364− case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
365− axg_tdm_stream_start(ts);
366− break;
367− case SNDRV_PCM_TRIGGER_SUSPEND:
368− case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
369− case SNDRV_PCM_TRIGGER_STOP:
370− axg_tdm_stream_stop(ts);
371− break;
372− default:
373− return -EINVAL;
374− }
357+ struct axg_tdm_stream *ts = snd_soc_dai_get_dma_data(dai, substream);
375358
376− return 0;
359+ /* Force all attached formatters to update */
360+ return axg_tdm_stream_reset(ts);
377361 }
378362
379363 static int axg_tdm_iface_remove_dai(struct snd_soc_dai *dai)
@@ -413,8 +397,8 @@ static const struct snd_soc_dai_ops axg_tdm_iface_ops = { · 33 unmodified lines
413397 .set_fmt = axg_tdm_iface_set_fmt,
414398 .startup = axg_tdm_iface_startup,
415399 .hw_params = axg_tdm_iface_hw_params,
400+ .prepare = axg_tdm_iface_prepare,
416401 .hw_free = axg_tdm_iface_hw_free,
417− .trigger = axg_tdm_iface_trigger,
418402 };
419403
420404 /* TDM Backend DAIs */
sound/soc/meson/g12a-tohdmitx.c+1−1
@@ -67,7 +67,7 @@ static int g12a_tohdmitx_i2s_mux_put_enum(struct snd_kcontrol *kcontrol, · 66 unmodified lines
6767
6868 snd_soc_dapm_mux_update_power(dapm, kcontrol, mux, e, NULL);
6969
70− return 0;
70+ return 1;
7171 }
7272
7373 static SOC_ENUM_SINGLE_DECL(g12a_tohdmitx_i2s_mux_enum, TOHDMITX_CTRL0,
sound/soc/soc-core.c+5−0
@@ -2587,6 +2587,11 @@ int snd_soc_component_initialize(struct snd_soc_component *component, · 2586 unmodified lines
25872587 component->dev = dev;
25882588 component->driver = driver;
25892589
2590+#ifdef CONFIG_DEBUG_FS
2591+ if (!component->debugfs_prefix)
2592+ component->debugfs_prefix = driver->debugfs_prefix;
2593+#endif
2594+
25902595 return 0;
25912596 }
25922597 EXPORT_SYMBOL_GPL(snd_soc_component_initialize);
sound/soc/soc-dapm.c+2−4
@@ -1687,8 +1687,7 @@ static void dapm_seq_run(struct snd_soc_card *card, · 1686 unmodified lines
16871687 switch (w->id) {
16881688 case snd_soc_dapm_pre:
16891689 if (!w->event)
1690− list_for_each_entry_safe_continue(w, n, list,
1691− power_list);
1690+ continue;
16921691
16931692 if (event == SND_SOC_DAPM_STREAM_START)
16941693 ret = w->event(w,
@@ -1700,8 +1699,7 @@ static void dapm_seq_run(struct snd_soc_card *card, · 5 unmodified lines
17001699
17011700 case snd_soc_dapm_post:
17021701 if (!w->event)
1703− list_for_each_entry_safe_continue(w, n, list,
1704− power_list);
1702+ continue;
17051703
17061704 if (event == SND_SOC_DAPM_STREAM_START)
17071705 ret = w->event(w,
sound/soc/soc-generic-dmaengine-pcm.c+3−3
@@ -86,10 +86,10 @@ static int dmaengine_pcm_hw_params(struct snd_soc_component *component, · 85 unmodified lines
8686
8787 memset(&slave_config, 0, sizeof(slave_config));
8888
89− if (pcm->config && pcm->config->prepare_slave_config)
90− prepare_slave_config = pcm->config->prepare_slave_config;
91− else
89+ if (!pcm->config)
9290 prepare_slave_config = snd_dmaengine_pcm_prepare_slave_config;
91+ else
92+ prepare_slave_config = pcm->config->prepare_slave_config;
9393
9494 if (prepare_slave_config) {
9595 int ret = prepare_slave_config(substream, params, &slave_config);
sound/soc/soc-ops.c+18−2
@@ -461,7 +461,7 @@ int snd_soc_put_volsw_sx(struct snd_kcontrol *kcontrol, · 460 unmodified lines
461461 ret = err;
462462 }
463463 }
464− return err;
464+ return ret;
465465 }
466466 EXPORT_SYMBOL_GPL(snd_soc_put_volsw_sx);
467467
@@ -519,7 +519,15 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol, · 51 unmodified lines
519519 unsigned int mask = (1 << fls(max)) - 1;
520520 unsigned int invert = mc->invert;
521521 unsigned int val, val_mask;
522− int err, ret;
522+ int err, ret, tmp;
523+
524+ tmp = ucontrol->value.integer.value[0];
525+ if (tmp < 0)
526+ return -EINVAL;
527+ if (mc->platform_max && tmp > mc->platform_max)
528+ return -EINVAL;
529+ if (tmp > mc->max - mc->min + 1)
530+ return -EINVAL;
523531
524532 if (invert)
525533 val = (max - ucontrol->value.integer.value[0]) & mask;
@@ -534,6 +542,14 @@ int snd_soc_put_volsw_range(struct snd_kcontrol *kcontrol, · 8 unmodified lines
534542 ret = err;
535543
536544 if (snd_soc_volsw_is_stereo(mc)) {
545+ tmp = ucontrol->value.integer.value[1];
546+ if (tmp < 0)
547+ return -EINVAL;
548+ if (mc->platform_max && tmp > mc->platform_max)
549+ return -EINVAL;
550+ if (tmp > mc->max - mc->min + 1)
551+ return -EINVAL;
552+
537553 if (invert)
538554 val = (max - ucontrol->value.integer.value[1]) & mask;
539555 else
sound/soc/soc-pcm.c+1−1
@@ -1214,7 +1214,7 @@ static int dpcm_be_connect(struct snd_soc_pcm_runtime *fe, · 1213 unmodified lines
12141214 be_substream->pcm->nonatomic = 1;
12151215 }
12161216
1217− dpcm = kzalloc(sizeof(struct snd_soc_dpcm), GFP_ATOMIC);
1217+ dpcm = kzalloc(sizeof(struct snd_soc_dpcm), GFP_KERNEL);
12181218 if (!dpcm)
12191219 return -ENOMEM;
12201220
sound/soc/soc-topology.c+2−2
@@ -1436,12 +1436,12 @@ static int soc_tplg_dapm_widget_create(struct soc_tplg *tplg, · 1435 unmodified lines
14361436 template.num_kcontrols = le32_to_cpu(w->num_kcontrols);
14371437 kc = devm_kcalloc(tplg->dev, le32_to_cpu(w->num_kcontrols), sizeof(*kc), GFP_KERNEL);
14381438 if (!kc)
1439− goto err;
1439+ goto hdr_err;
14401440
14411441 kcontrol_type = devm_kcalloc(tplg->dev, le32_to_cpu(w->num_kcontrols), sizeof(unsigned int),
14421442 GFP_KERNEL);
14431443 if (!kcontrol_type)
1444− goto err;
1444+ goto hdr_err;
14451445
14461446 for (i = 0; i < le32_to_cpu(w->num_kcontrols); i++) {
14471447 control_hdr = (struct snd_soc_tplg_ctl_hdr *)tplg->pos;
sound/soc/sof/sof-pci-dev.c+13−1
@@ -83,7 +83,14 @@ static const struct dmi_system_id sof_tplg_table[] = { · 82 unmodified lines
8383 },
8484 .driver_data = "sof-adl-max98357a-rt5682-2way.tplg",
8585 },
86−
86+ {
87+ .callback = sof_tplg_cb,
88+ .matches = {
89+ DMI_MATCH(DMI_PRODUCT_FAMILY, "Google_Brya"),
90+ DMI_MATCH(DMI_OEM_STRING, "AUDIO-MAX98360_ALC5682I_I2S_AMP_SSP2"),
91+ },
92+ .driver_data = "sof-adl-max98357a-rt5682.tplg",
93+ },
8794 {}
8895 };
8996
@@ -146,6 +153,11 @@ int sof_pci_probe(struct pci_dev *pci, const struct pci_device_id *pci_id) · 56 unmodified lines
146153
147154 dev_dbg(&pci->dev, "PCI DSP detected");
148155
156+ if (!desc) {
157+ dev_err(dev, "error: no matching PCI descriptor\n");
158+ return -ENODEV;
159+ }
160+
149161 if (!desc->ops) {
150162 dev_err(dev, "error: no matching PCI descriptor ops\n");
151163 return -ENODEV;
sound/soc/sof/topology.c+49−1
@@ -904,8 +904,10 @@ static int sof_control_load(struct snd_soc_component *scomp, int index, · 903 unmodified lines
904904 return -ENOMEM;
905905
906906 scontrol->name = kstrdup(hdr->name, GFP_KERNEL);
907− if (!scontrol->name)
907+ if (!scontrol->name) {
908+ kfree(scontrol);
908909 return -ENOMEM;
910+ }
909911
910912 scontrol->scomp = scomp;
911913 scontrol->access = kc->access;
@@ -941,11 +943,13 @@ static int sof_control_load(struct snd_soc_component *scomp, int index, · 29 unmodified lines
941943 default:
942944 dev_warn(scomp->dev, "control type not supported %d:%d:%d\n",
943945 hdr->ops.get, hdr->ops.put, hdr->ops.info);
946+ kfree(scontrol->name);
944947 kfree(scontrol);
945948 return 0;
946949 }
947950
948951 if (ret < 0) {
952+ kfree(scontrol->name);
949953 kfree(scontrol);
950954 return ret;
951955 }
@@ -1068,6 +1072,46 @@ static int sof_connect_dai_widget(struct snd_soc_component *scomp, · 116 unmodified lines
10681072 return 0;
10691073 }
10701074
1075+static void sof_disconnect_dai_widget(struct snd_soc_component *scomp,
1076+ struct snd_soc_dapm_widget *w)
1077+{
1078+ struct snd_soc_card *card = scomp->card;
1079+ struct snd_soc_pcm_runtime *rtd;
1080+ struct snd_soc_dai *cpu_dai;
1081+ int i;
1082+
1083+ if (!w->sname)
1084+ return;
1085+
1086+ list_for_each_entry(rtd, &card->rtd_list, list) {
1087+ /* does stream match DAI link ? */
1088+ if (!rtd->dai_link->stream_name ||
1089+ strcmp(w->sname, rtd->dai_link->stream_name))
1090+ continue;
1091+
1092+ switch (w->id) {
1093+ case snd_soc_dapm_dai_out:
1094+ for_each_rtd_cpu_dais(rtd, i, cpu_dai) {
1095+ if (cpu_dai->capture_widget == w) {
1096+ cpu_dai->capture_widget = NULL;
1097+ break;
1098+ }
1099+ }
1100+ break;
1101+ case snd_soc_dapm_dai_in:
1102+ for_each_rtd_cpu_dais(rtd, i, cpu_dai) {
1103+ if (cpu_dai->playback_widget == w) {
1104+ cpu_dai->playback_widget = NULL;
1105+ break;
1106+ }
1107+ }
1108+ break;
1109+ default:
1110+ break;
1111+ }
1112+ }
1113+}
1114+
10711115 /* bind PCM ID to host component ID */
10721116 static int spcm_bind(struct snd_soc_component *scomp, struct snd_sof_pcm *spcm,
10731117 int dir)
@@ -1353,6 +1397,9 @@ static int sof_widget_unload(struct snd_soc_component *scomp, · 279 unmodified lines
13531397
13541398 if (dai)
13551399 list_del(&dai->list);
1400+
1401+ sof_disconnect_dai_widget(scomp, widget);
1402+
13561403 break;
13571404 default:
13581405 break;
@@ -1380,6 +1427,7 @@ static int sof_widget_unload(struct snd_soc_component *scomp, · 21 unmodified lines
13801427 }
13811428 kfree(scontrol->ipc_control_data);
13821429 list_del(&scontrol->list);
1430+ kfree(scontrol->name);
13831431 kfree(scontrol);
13841432 }
13851433
sound/usb/clock.c+7−0
@@ -572,6 +572,13 @@ static int set_sample_rate_v2v3(struct snd_usb_audio *chip, · 571 unmodified lines
572572 /* continue processing */
573573 }
574574
575+ /* FIXME - TEAC devices require the immediate interface setup */
576+ if (rate != prev_rate && USB_ID_VENDOR(chip->usb_id) == 0x0644) {
577+ usb_set_interface(chip->dev, fmt->iface, fmt->altsetting);
578+ if (chip->quirk_flags & QUIRK_FLAG_IFACE_DELAY)
579+ msleep(50);
580+ }
581+
575582 validation:
576583 /* validate clock after rate change */
577584 if (!uac_clock_source_is_valid(chip, fmt, clock))
sound/usb/midi.c+1−0
@@ -1194,6 +1194,7 @@ static void snd_usbmidi_output_drain(struct snd_rawmidi_substream *substream) · 1193 unmodified lines
11941194 } while (drain_urbs && timeout);
11951195 finish_wait(&ep->drain_wait, &wait);
11961196 }
1197+ port->active = 0;
11971198 spin_unlock_irq(&ep->buffer_lock);
11981199 }
11991200
sound/usb/mixer_maps.c+4−0
@@ -599,6 +599,10 @@ static const struct usbmix_ctl_map usbmix_ctl_maps[] = { · 598 unmodified lines
599599 .id = USB_ID(0x0db0, 0x419c),
600600 .map = msi_mpg_x570s_carbon_max_wifi_alc4080_map,
601601 },
602+ { /* MSI MAG X570S Torpedo Max */
603+ .id = USB_ID(0x0db0, 0xa073),
604+ .map = msi_mpg_x570s_carbon_max_wifi_alc4080_map,
605+ },
602606 { /* MSI TRX40 */
603607 .id = USB_ID(0x0db0, 0x543d),
604608 .map = trx40_mobo_map,
sound/usb/quirks-table.h+12−0
@@ -2672,6 +2672,7 @@ YAMAHA_DEVICE(0x7010, "UB99"), · 2671 unmodified lines
26722672 .altset_idx = 1,
26732673 .attributes = 0,
26742674 .endpoint = 0x82,
2675+ .ep_idx = 1,
26752676 .ep_attr = USB_ENDPOINT_XFER_ISOC,
26762677 .datainterval = 1,
26772678 .maxpacksize = 0x0126,
@@ -2875,6 +2876,7 @@ YAMAHA_DEVICE(0x7010, "UB99"), · 197 unmodified lines
28752876 .altset_idx = 1,
28762877 .attributes = 0x4,
28772878 .endpoint = 0x81,
2879+ .ep_idx = 1,
28782880 .ep_attr = USB_ENDPOINT_XFER_ISOC |
28792881 USB_ENDPOINT_SYNC_ASYNC,
28802882 .maxpacksize = 0x130,
@@ -3235,6 +3237,15 @@ YAMAHA_DEVICE(0x7010, "UB99"), · 354 unmodified lines
32353237 }
32363238 },
32373239
3240+/* Rane SL-1 */
3241+{
3242+ USB_DEVICE(0x13e5, 0x0001),
3243+ .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
3244+ .ifnum = QUIRK_ANY_INTERFACE,
3245+ .type = QUIRK_AUDIO_STANDARD_INTERFACE
3246+ }
3247+},
3248+
32383249 /* disabled due to regression for other devices;
32393250 * see https://bugzilla.kernel.org/show_bug.cgi?id=199905
32403251 */
@@ -3382,6 +3393,7 @@ YAMAHA_DEVICE(0x7010, "UB99"), · 141 unmodified lines
33823393 .altset_idx = 1,
33833394 .attributes = 0,
33843395 .endpoint = 0x03,
3396+ .ep_idx = 1,
33853397 .rates = SNDRV_PCM_RATE_96000,
33863398 .ep_attr = USB_ENDPOINT_XFER_ISOC |
33873399 USB_ENDPOINT_SYNC_ASYNC,
sound/usb/quirks.c+2−0
@@ -1824,6 +1824,8 @@ static const struct usb_audio_quirk_flags_table quirk_flags_table[] = { · 1823 unmodified lines
18241824 QUIRK_FLAG_IGNORE_CTL_ERROR),
18251825 DEVICE_FLG(0x06f8, 0xd002, /* Hercules DJ Console (Macintosh Edition) */
18261826 QUIRK_FLAG_IGNORE_CTL_ERROR),
1827+ DEVICE_FLG(0x0711, 0x5800, /* MCT Trigger 5 USB-to-HDMI */
1828+ QUIRK_FLAG_GET_SAMPLE_RATE),
18271829 DEVICE_FLG(0x074d, 0x3553, /* Outlaw RR2150 (Micronas UAC3553B) */
18281830 QUIRK_FLAG_GET_SAMPLE_RATE),
18291831 DEVICE_FLG(0x0763, 0x2030, /* M-Audio Fast Track C400 */