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-6.14-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
"A collection of last-minute fixes.

Most of them are for ASoC, and the only one core fix is for reverting
the previous change, while the rest are all device-specific quirks and
fixes, which should be relatively safe to apply"

* tag 'sound-6.14-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ASoC: cs42l43: convert to SYSTEM_SLEEP_PM_OPS
ALSA: hda/realtek: Add mute LED quirk for HP Pavilion x360 14-dy1xxx
ASoC: codecs: wm0010: Fix error handling path in wm0010_spi_probe()
ASoC: rt722-sdca: add missing readable registers
ASoC: amd: yc: Support mic on another Lenovo ThinkPad E16 Gen 2 model
ASoC: cs42l43: Fix maximum ADC Volume
ASoC: ops: Consistently treat platform_max as control value
ASoC: rt1320: set wake_capable = 0 explicitly
ASoC: cs42l43: Add jack delay debounce after suspend
ASoC: tegra: Fix ADX S24_LE audio format
ASoC: codecs: wsa884x: report temps to hwmon in millidegree of Celsius
ASoC: Intel: sof_sdw: Fix unlikely uninitialized variable use in create_sdw_dailinks()

+90 -21
+4 -1
include/sound/soc.h
··· 1261 1261 1262 1262 /* mixer control */ 1263 1263 struct soc_mixer_control { 1264 - int min, max, platform_max; 1264 + /* Minimum and maximum specified as written to the hardware */ 1265 + int min, max; 1266 + /* Limited maximum value specified as presented through the control */ 1267 + int platform_max; 1265 1268 int reg, rreg; 1266 1269 unsigned int shift, rshift; 1267 1270 unsigned int sign_bit;
+21
sound/pci/hda/patch_realtek.c
··· 4790 4790 } 4791 4791 } 4792 4792 4793 + static void alc295_fixup_hp_mute_led_coefbit11(struct hda_codec *codec, 4794 + const struct hda_fixup *fix, int action) 4795 + { 4796 + struct alc_spec *spec = codec->spec; 4797 + 4798 + if (action == HDA_FIXUP_ACT_PRE_PROBE) { 4799 + spec->mute_led_polarity = 0; 4800 + spec->mute_led_coef.idx = 0xb; 4801 + spec->mute_led_coef.mask = 3 << 3; 4802 + spec->mute_led_coef.on = 1 << 3; 4803 + spec->mute_led_coef.off = 1 << 4; 4804 + snd_hda_gen_add_mute_led_cdev(codec, coef_mute_led_set); 4805 + } 4806 + } 4807 + 4793 4808 static void alc285_fixup_hp_mute_led(struct hda_codec *codec, 4794 4809 const struct hda_fixup *fix, int action) 4795 4810 { ··· 7671 7656 ALC290_FIXUP_MONO_SPEAKERS_HSJACK, 7672 7657 ALC290_FIXUP_SUBWOOFER, 7673 7658 ALC290_FIXUP_SUBWOOFER_HSJACK, 7659 + ALC295_FIXUP_HP_MUTE_LED_COEFBIT11, 7674 7660 ALC269_FIXUP_THINKPAD_ACPI, 7675 7661 ALC269_FIXUP_LENOVO_XPAD_ACPI, 7676 7662 ALC269_FIXUP_DMIC_THINKPAD_ACPI, ··· 9417 9401 .chained = true, 9418 9402 .chain_id = ALC283_FIXUP_INT_MIC, 9419 9403 }, 9404 + [ALC295_FIXUP_HP_MUTE_LED_COEFBIT11] = { 9405 + .type = HDA_FIXUP_FUNC, 9406 + .v.func = alc295_fixup_hp_mute_led_coefbit11, 9407 + }, 9420 9408 [ALC298_FIXUP_SAMSUNG_AMP] = { 9421 9409 .type = HDA_FIXUP_FUNC, 9422 9410 .v.func = alc298_fixup_samsung_amp, ··· 10471 10451 SND_PCI_QUIRK(0x103c, 0x84e7, "HP Pavilion 15", ALC269_FIXUP_HP_MUTE_LED_MIC3), 10472 10452 SND_PCI_QUIRK(0x103c, 0x8519, "HP Spectre x360 15-df0xxx", ALC285_FIXUP_HP_SPECTRE_X360), 10473 10453 SND_PCI_QUIRK(0x103c, 0x8537, "HP ProBook 440 G6", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF), 10454 + SND_PCI_QUIRK(0x103c, 0x85c6, "HP Pavilion x360 Convertible 14-dy1xxx", ALC295_FIXUP_HP_MUTE_LED_COEFBIT11), 10474 10455 SND_PCI_QUIRK(0x103c, 0x85de, "HP Envy x360 13-ar0xxx", ALC285_FIXUP_HP_ENVY_X360), 10475 10456 SND_PCI_QUIRK(0x103c, 0x860f, "HP ZBook 15 G6", ALC285_FIXUP_HP_GPIO_AMP_INIT), 10476 10457 SND_PCI_QUIRK(0x103c, 0x861f, "HP Elite Dragonfly G1", ALC285_FIXUP_HP_GPIO_AMP_INIT),
+7
sound/soc/amd/yc/acp6x-mach.c
··· 252 252 .driver_data = &acp6x_card, 253 253 .matches = { 254 254 DMI_MATCH(DMI_BOARD_VENDOR, "LENOVO"), 255 + DMI_MATCH(DMI_PRODUCT_NAME, "21M6"), 256 + } 257 + }, 258 + { 259 + .driver_data = &acp6x_card, 260 + .matches = { 261 + DMI_MATCH(DMI_BOARD_VENDOR, "LENOVO"), 255 262 DMI_MATCH(DMI_PRODUCT_NAME, "21ME"), 256 263 } 257 264 },
+10 -3
sound/soc/codecs/cs42l43-jack.c
··· 167 167 autocontrol |= 0x3 << CS42L43_JACKDET_MODE_SHIFT; 168 168 169 169 ret = cs42l43_find_index(priv, "cirrus,tip-fall-db-ms", 500, 170 - NULL, cs42l43_accdet_db_ms, 170 + &priv->tip_fall_db_ms, cs42l43_accdet_db_ms, 171 171 ARRAY_SIZE(cs42l43_accdet_db_ms)); 172 172 if (ret < 0) 173 173 goto error; ··· 175 175 tip_deb |= ret << CS42L43_TIPSENSE_FALLING_DB_TIME_SHIFT; 176 176 177 177 ret = cs42l43_find_index(priv, "cirrus,tip-rise-db-ms", 500, 178 - NULL, cs42l43_accdet_db_ms, 178 + &priv->tip_rise_db_ms, cs42l43_accdet_db_ms, 179 179 ARRAY_SIZE(cs42l43_accdet_db_ms)); 180 180 if (ret < 0) 181 181 goto error; ··· 764 764 error: 765 765 mutex_unlock(&priv->jack_lock); 766 766 767 + priv->suspend_jack_debounce = false; 768 + 767 769 pm_runtime_mark_last_busy(priv->dev); 768 770 pm_runtime_put_autosuspend(priv->dev); 769 771 } ··· 773 771 irqreturn_t cs42l43_tip_sense(int irq, void *data) 774 772 { 775 773 struct cs42l43_codec *priv = data; 774 + unsigned int db_delay = priv->tip_debounce_ms; 776 775 777 776 cancel_delayed_work(&priv->bias_sense_timeout); 778 777 cancel_delayed_work(&priv->tip_sense_work); 779 778 cancel_delayed_work(&priv->button_press_work); 780 779 cancel_work(&priv->button_release_work); 781 780 781 + // Ensure delay after suspend is long enough to avoid false detection 782 + if (priv->suspend_jack_debounce) 783 + db_delay += priv->tip_fall_db_ms + priv->tip_rise_db_ms; 784 + 782 785 queue_delayed_work(system_long_wq, &priv->tip_sense_work, 783 - msecs_to_jiffies(priv->tip_debounce_ms)); 786 + msecs_to_jiffies(db_delay)); 784 787 785 788 return IRQ_HANDLED; 786 789 }
+15 -2
sound/soc/codecs/cs42l43.c
··· 1146 1146 1147 1147 SOC_DOUBLE_R_SX_TLV("ADC Volume", CS42L43_ADC_B_CTRL1, CS42L43_ADC_B_CTRL2, 1148 1148 CS42L43_ADC_PGA_GAIN_SHIFT, 1149 - 0xF, 5, cs42l43_adc_tlv), 1149 + 0xF, 4, cs42l43_adc_tlv), 1150 1150 1151 1151 SOC_DOUBLE("PDM1 Invert Switch", CS42L43_DMIC_PDM_CTRL, 1152 1152 CS42L43_PDM1L_INV_SHIFT, CS42L43_PDM1R_INV_SHIFT, 1, 0), ··· 2402 2402 return 0; 2403 2403 } 2404 2404 2405 + static int cs42l43_codec_runtime_force_suspend(struct device *dev) 2406 + { 2407 + struct cs42l43_codec *priv = dev_get_drvdata(dev); 2408 + 2409 + dev_dbg(priv->dev, "Runtime suspend\n"); 2410 + 2411 + priv->suspend_jack_debounce = true; 2412 + 2413 + pm_runtime_force_suspend(dev); 2414 + 2415 + return 0; 2416 + } 2417 + 2405 2418 static const struct dev_pm_ops cs42l43_codec_pm_ops = { 2406 2419 RUNTIME_PM_OPS(NULL, cs42l43_codec_runtime_resume, NULL) 2407 - SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, pm_runtime_force_resume) 2420 + SYSTEM_SLEEP_PM_OPS(cs42l43_codec_runtime_force_suspend, pm_runtime_force_resume) 2408 2421 }; 2409 2422 2410 2423 static const struct platform_device_id cs42l43_codec_id_table[] = {
+3
sound/soc/codecs/cs42l43.h
··· 78 78 79 79 bool use_ring_sense; 80 80 unsigned int tip_debounce_ms; 81 + unsigned int tip_fall_db_ms; 82 + unsigned int tip_rise_db_ms; 81 83 unsigned int bias_low; 82 84 unsigned int bias_sense_ua; 83 85 unsigned int bias_ramp_ms; ··· 97 95 bool button_detect_running; 98 96 bool jack_present; 99 97 int jack_override; 98 + bool suspend_jack_debounce; 100 99 101 100 struct work_struct hp_ilimit_work; 102 101 struct delayed_work hp_ilimit_clear_work;
+3
sound/soc/codecs/rt1320-sdw.c
··· 535 535 /* set the timeout values */ 536 536 prop->clk_stop_timeout = 64; 537 537 538 + /* BIOS may set wake_capable. Make sure it is 0 as wake events are disabled. */ 539 + prop->wake_capable = 0; 540 + 538 541 return 0; 539 542 } 540 543
+4
sound/soc/codecs/rt722-sdca-sdw.c
··· 86 86 case 0x6100067: 87 87 case 0x6100070 ... 0x610007c: 88 88 case 0x6100080: 89 + case SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT722_SDCA_ENT_FU15, RT722_SDCA_CTL_FU_CH_GAIN, 90 + CH_01) ... 91 + SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT722_SDCA_ENT_FU15, RT722_SDCA_CTL_FU_CH_GAIN, 92 + CH_04): 89 93 case SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT722_SDCA_ENT_USER_FU1E, RT722_SDCA_CTL_FU_VOLUME, 90 94 CH_01): 91 95 case SDW_SDCA_CTL(FUNC_NUM_MIC_ARRAY, RT722_SDCA_ENT_USER_FU1E, RT722_SDCA_CTL_FU_VOLUME,
+11 -2
sound/soc/codecs/wm0010.c
··· 920 920 if (ret) { 921 921 dev_err(wm0010->dev, "Failed to set IRQ %d as wake source: %d\n", 922 922 irq, ret); 923 - return ret; 923 + goto free_irq; 924 924 } 925 925 926 926 if (spi->max_speed_hz) ··· 932 932 &soc_component_dev_wm0010, wm0010_dai, 933 933 ARRAY_SIZE(wm0010_dai)); 934 934 if (ret < 0) 935 - return ret; 935 + goto disable_irq_wake; 936 936 937 937 return 0; 938 + 939 + disable_irq_wake: 940 + irq_set_irq_wake(wm0010->irq, 0); 941 + 942 + free_irq: 943 + if (wm0010->irq) 944 + free_irq(wm0010->irq, wm0010); 945 + 946 + return ret; 938 947 } 939 948 940 949 static void wm0010_spi_remove(struct spi_device *spi)
+2 -2
sound/soc/codecs/wsa884x.c
··· 1875 1875 * Reading temperature is possible only when Power Amplifier is 1876 1876 * off. Report last cached data. 1877 1877 */ 1878 - *temp = wsa884x->temperature; 1878 + *temp = wsa884x->temperature * 1000; 1879 1879 return 0; 1880 1880 } 1881 1881 ··· 1934 1934 if ((val > WSA884X_LOW_TEMP_THRESHOLD) && 1935 1935 (val < WSA884X_HIGH_TEMP_THRESHOLD)) { 1936 1936 wsa884x->temperature = val; 1937 - *temp = val; 1937 + *temp = val * 1000; 1938 1938 ret = 0; 1939 1939 } else { 1940 1940 ret = -EAGAIN;
+1 -1
sound/soc/intel/boards/sof_sdw.c
··· 954 954 955 955 /* generate DAI links by each sdw link */ 956 956 while (sof_dais->initialised) { 957 - int current_be_id; 957 + int current_be_id = 0; 958 958 959 959 ret = create_sdw_dailink(card, sof_dais, dai_links, 960 960 &current_be_id, codec_conf);
+7 -8
sound/soc/soc-ops.c
··· 337 337 if (ucontrol->value.integer.value[0] < 0) 338 338 return -EINVAL; 339 339 val = ucontrol->value.integer.value[0]; 340 - if (mc->platform_max && ((int)val + min) > mc->platform_max) 340 + if (mc->platform_max && val > mc->platform_max) 341 341 return -EINVAL; 342 342 if (val > max - min) 343 343 return -EINVAL; ··· 350 350 if (ucontrol->value.integer.value[1] < 0) 351 351 return -EINVAL; 352 352 val2 = ucontrol->value.integer.value[1]; 353 - if (mc->platform_max && ((int)val2 + min) > mc->platform_max) 353 + if (mc->platform_max && val2 > mc->platform_max) 354 354 return -EINVAL; 355 355 if (val2 > max - min) 356 356 return -EINVAL; ··· 503 503 { 504 504 struct soc_mixer_control *mc = 505 505 (struct soc_mixer_control *)kcontrol->private_value; 506 - int platform_max; 507 - int min = mc->min; 506 + int max; 508 507 509 - if (!mc->platform_max) 510 - mc->platform_max = mc->max; 511 - platform_max = mc->platform_max; 508 + max = mc->max - mc->min; 509 + if (mc->platform_max && mc->platform_max < max) 510 + max = mc->platform_max; 512 511 513 512 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; 514 513 uinfo->count = snd_soc_volsw_is_stereo(mc) ? 2 : 1; 515 514 uinfo->value.integer.min = 0; 516 - uinfo->value.integer.max = platform_max - min; 515 + uinfo->value.integer.max = max; 517 516 518 517 return 0; 519 518 }
+2 -2
sound/soc/tegra/tegra210_adx.c
··· 264 264 .rates = SNDRV_PCM_RATE_8000_192000, \ 265 265 .formats = SNDRV_PCM_FMTBIT_S8 | \ 266 266 SNDRV_PCM_FMTBIT_S16_LE | \ 267 - SNDRV_PCM_FMTBIT_S16_LE | \ 267 + SNDRV_PCM_FMTBIT_S24_LE | \ 268 268 SNDRV_PCM_FMTBIT_S32_LE, \ 269 269 }, \ 270 270 .capture = { \ ··· 274 274 .rates = SNDRV_PCM_RATE_8000_192000, \ 275 275 .formats = SNDRV_PCM_FMTBIT_S8 | \ 276 276 SNDRV_PCM_FMTBIT_S16_LE | \ 277 - SNDRV_PCM_FMTBIT_S16_LE | \ 277 + SNDRV_PCM_FMTBIT_S24_LE | \ 278 278 SNDRV_PCM_FMTBIT_S32_LE, \ 279 279 }, \ 280 280 .ops = &tegra210_adx_out_dai_ops, \