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

ASoC: Merge up fixes

We need some of the AMD fixes as a base for new work.

+145 -75
+1
MAINTAINERS
··· 18210 18210 M: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> 18211 18211 M: Banajit Goswami <bgoswami@quicinc.com> 18212 18212 L: alsa-devel@alsa-project.org (moderated for non-subscribers) 18213 + L: linux-arm-msm@vger.kernel.org 18213 18214 S: Supported 18214 18215 F: Documentation/devicetree/bindings/soc/qcom/qcom,apr* 18215 18216 F: Documentation/devicetree/bindings/sound/qcom,*
+1
include/sound/dmaengine_pcm.h
··· 36 36 int snd_dmaengine_pcm_open(struct snd_pcm_substream *substream, 37 37 struct dma_chan *chan); 38 38 int snd_dmaengine_pcm_close(struct snd_pcm_substream *substream); 39 + int snd_dmaengine_pcm_sync_stop(struct snd_pcm_substream *substream); 39 40 40 41 int snd_dmaengine_pcm_open_request_chan(struct snd_pcm_substream *substream, 41 42 dma_filter_fn filter_fn, void *filter_data);
+10
sound/core/pcm_dmaengine.c
··· 349 349 } 350 350 EXPORT_SYMBOL_GPL(snd_dmaengine_pcm_open_request_chan); 351 351 352 + int snd_dmaengine_pcm_sync_stop(struct snd_pcm_substream *substream) 353 + { 354 + struct dmaengine_pcm_runtime_data *prtd = substream_to_prtd(substream); 355 + 356 + dmaengine_synchronize(prtd->dma_chan); 357 + 358 + return 0; 359 + } 360 + EXPORT_SYMBOL_GPL(snd_dmaengine_pcm_sync_stop); 361 + 352 362 /** 353 363 * snd_dmaengine_pcm_close - Close a dmaengine based PCM substream 354 364 * @substream: PCM substream
-8
sound/soc/amd/acp/acp-i2s.c
··· 588 588 { 589 589 struct device *dev = dai->component->dev; 590 590 struct acp_dev_data *adata = dev_get_drvdata(dev); 591 - struct acp_resource *rsrc = adata->rsrc; 592 - unsigned int val; 593 591 594 592 if (!adata->acp_base) { 595 593 dev_err(dev, "I2S base is NULL\n"); 596 - return -EINVAL; 597 - } 598 - 599 - val = readl(adata->acp_base + rsrc->i2s_pin_cfg_offset); 600 - if (val != rsrc->i2s_mode) { 601 - dev_err(dev, "I2S Mode not supported val %x\n", val); 602 594 return -EINVAL; 603 595 } 604 596
+7 -5
sound/soc/amd/acp/acp-pci.c
··· 100 100 ret = -EINVAL; 101 101 goto release_regions; 102 102 } 103 + chip->flag = flag; 103 104 dmic_dev = platform_device_register_data(dev, "dmic-codec", PLATFORM_DEVID_NONE, NULL, 0); 104 105 if (IS_ERR(dmic_dev)) { 105 106 dev_err(dev, "failed to create DMIC device\n"); ··· 140 139 } 141 140 } 142 141 143 - chip->flag = flag; 144 142 memset(&pdevinfo, 0, sizeof(pdevinfo)); 145 143 146 144 pdevinfo.name = chip->name; ··· 199 199 ret = acp_init(chip); 200 200 if (ret) 201 201 dev_err(dev, "ACP init failed\n"); 202 - child = chip->chip_pdev->dev; 203 - adata = dev_get_drvdata(&child); 204 - if (adata) 205 - acp_enable_interrupts(adata); 202 + if (chip->chip_pdev) { 203 + child = chip->chip_pdev->dev; 204 + adata = dev_get_drvdata(&child); 205 + if (adata) 206 + acp_enable_interrupts(adata); 207 + } 206 208 return ret; 207 209 } 208 210
+5 -2
sound/soc/atmel/atmel-classd.c
··· 473 473 if (!dai_link) 474 474 return -ENOMEM; 475 475 476 - comp = devm_kzalloc(dev, sizeof(*comp), GFP_KERNEL); 476 + comp = devm_kzalloc(dev, 2 * sizeof(*comp), GFP_KERNEL); 477 477 if (!comp) 478 478 return -ENOMEM; 479 479 480 - dai_link->cpus = comp; 480 + dai_link->cpus = &comp[0]; 481 481 dai_link->codecs = &snd_soc_dummy_dlc; 482 + dai_link->platforms = &comp[1]; 482 483 483 484 dai_link->num_cpus = 1; 484 485 dai_link->num_codecs = 1; 486 + dai_link->num_platforms = 1; 485 487 486 488 dai_link->name = "CLASSD"; 487 489 dai_link->stream_name = "CLASSD PCM"; 488 490 dai_link->cpus->dai_name = dev_name(dev); 491 + dai_link->platforms->name = dev_name(dev); 489 492 490 493 card->dai_link = dai_link; 491 494 card->num_links = 1;
+4
sound/soc/codecs/cs35l56-shared.c
··· 215 215 REG_SEQ0(CS35L56_ASP1_FRAME_CONTROL5, 0x00020100), 216 216 REG_SEQ0(CS35L56_ASP1_DATA_CONTROL1, 0x00000018), 217 217 REG_SEQ0(CS35L56_ASP1_DATA_CONTROL5, 0x00000018), 218 + REG_SEQ0(CS35L56_ASP1TX1_INPUT, 0x00000000), 219 + REG_SEQ0(CS35L56_ASP1TX2_INPUT, 0x00000000), 220 + REG_SEQ0(CS35L56_ASP1TX3_INPUT, 0x00000000), 221 + REG_SEQ0(CS35L56_ASP1TX4_INPUT, 0x00000000), 218 222 }; 219 223 220 224 /*
+2 -2
sound/soc/codecs/cs42l43-jack.c
··· 121 121 priv->buttons[3] = 735; 122 122 } 123 123 124 - ret = cs42l43_find_index(priv, "cirrus,detect-us", 1000, &priv->detect_us, 124 + ret = cs42l43_find_index(priv, "cirrus,detect-us", 50000, &priv->detect_us, 125 125 cs42l43_accdet_us, ARRAY_SIZE(cs42l43_accdet_us)); 126 126 if (ret < 0) 127 127 goto error; ··· 433 433 434 434 // Wait for 2 full cycles of comb filter to ensure good reading 435 435 queue_delayed_work(system_wq, &priv->button_press_work, 436 - msecs_to_jiffies(10)); 436 + msecs_to_jiffies(20)); 437 437 438 438 return IRQ_HANDLED; 439 439 }
+6 -2
sound/soc/codecs/es8326.c
··· 857 857 * set auto-check mode, then restart jack_detect_work after 400ms. 858 858 * Don't report jack status. 859 859 */ 860 - regmap_write(es8326->regmap, ES8326_INT_SOURCE, 861 - (ES8326_INT_SRC_PIN9 | ES8326_INT_SRC_BUTTON)); 860 + regmap_write(es8326->regmap, ES8326_INT_SOURCE, 0x00); 862 861 regmap_update_bits(es8326->regmap, ES8326_HPDET_TYPE, 0x03, 0x01); 862 + regmap_update_bits(es8326->regmap, ES8326_HPDET_TYPE, 0x10, 0x00); 863 863 es8326_enable_micbias(es8326->component); 864 864 usleep_range(50000, 70000); 865 865 regmap_update_bits(es8326->regmap, ES8326_HPDET_TYPE, 0x03, 0x00); 866 + regmap_update_bits(es8326->regmap, ES8326_HPDET_TYPE, 0x10, 0x10); 867 + usleep_range(50000, 70000); 868 + regmap_write(es8326->regmap, ES8326_INT_SOURCE, 869 + (ES8326_INT_SRC_PIN9 | ES8326_INT_SRC_BUTTON)); 866 870 regmap_write(es8326->regmap, ES8326_SYS_BIAS, 0x1f); 867 871 regmap_update_bits(es8326->regmap, ES8326_HP_DRIVER_REF, 0x0f, 0x08); 868 872 queue_delayed_work(system_wq, &es8326->jack_detect_work,
+3 -1
sound/soc/codecs/rt722-sdca-sdw.c
··· 68 68 case 0x200007f: 69 69 case 0x2000082 ... 0x200008e: 70 70 case 0x2000090 ... 0x2000094: 71 + case 0x3110000: 71 72 case 0x5300000 ... 0x5300002: 72 73 case 0x5400002: 73 74 case 0x5600000 ... 0x5600007: ··· 126 125 case 0x2000067: 127 126 case 0x2000084: 128 127 case 0x2000086: 128 + case 0x3110000: 129 129 return true; 130 130 default: 131 131 return false; ··· 352 350 353 351 if (status->sdca_cascade && !rt722->disable_irq) 354 352 mod_delayed_work(system_power_efficient_wq, 355 - &rt722->jack_detect_work, msecs_to_jiffies(30)); 353 + &rt722->jack_detect_work, msecs_to_jiffies(280)); 356 354 357 355 mutex_unlock(&rt722->disable_irq_lock); 358 356
+2 -1
sound/soc/fsl/fsl-asoc-card.c
··· 559 559 if (!priv) 560 560 return -ENOMEM; 561 561 562 + priv->pdev = pdev; 563 + 562 564 cpu_np = of_parse_phandle(np, "audio-cpu", 0); 563 565 /* Give a chance to old DT binding */ 564 566 if (!cpu_np) ··· 789 787 } 790 788 791 789 /* Initialize sound card */ 792 - priv->pdev = pdev; 793 790 priv->card.dev = &pdev->dev; 794 791 priv->card.owner = THIS_MODULE; 795 792 ret = snd_soc_of_parse_card_name(&priv->card, "model");
+1
sound/soc/fsl/imx-pcm-dma.c
··· 50 50 } 51 51 EXPORT_SYMBOL_GPL(imx_pcm_dma_init); 52 52 53 + MODULE_DESCRIPTION("Freescale i.MX PCM DMA interface"); 53 54 MODULE_LICENSE("GPL");
+15 -4
sound/soc/intel/avs/topology.c
··· 1545 1545 { 1546 1546 struct snd_soc_acpi_mach *mach = dev_get_platdata(comp->card->dev); 1547 1547 size_t len = SNDRV_CTL_ELEM_ID_NAME_MAXLEN; 1548 - char buf[SNDRV_CTL_ELEM_ID_NAME_MAXLEN]; 1549 1548 int ssp_port, tdm_slot; 1549 + char *buf; 1550 1550 1551 1551 /* See parse_link_formatted_string() for dynamic naming when(s). */ 1552 1552 if (!avs_mach_singular_ssp(mach)) ··· 1557 1557 return 0; 1558 1558 tdm_slot = avs_mach_ssp_tdm(mach, ssp_port); 1559 1559 1560 + buf = devm_kzalloc(comp->card->dev, len, GFP_KERNEL); 1561 + if (!buf) 1562 + return -ENOMEM; 1560 1563 avs_ssp_sprint(buf, len, route->source, ssp_port, tdm_slot); 1561 - strscpy((char *)route->source, buf, len); 1564 + route->source = buf; 1565 + 1566 + buf = devm_kzalloc(comp->card->dev, len, GFP_KERNEL); 1567 + if (!buf) 1568 + return -ENOMEM; 1562 1569 avs_ssp_sprint(buf, len, route->sink, ssp_port, tdm_slot); 1563 - strscpy((char *)route->sink, buf, len); 1570 + route->sink = buf; 1571 + 1564 1572 if (route->control) { 1573 + buf = devm_kzalloc(comp->card->dev, len, GFP_KERNEL); 1574 + if (!buf) 1575 + return -ENOMEM; 1565 1576 avs_ssp_sprint(buf, len, route->control, ssp_port, tdm_slot); 1566 - strscpy((char *)route->control, buf, len); 1577 + route->control = buf; 1567 1578 } 1568 1579 1569 1580 return 0;
+11
sound/soc/intel/boards/bytcr_rt5640.c
··· 613 613 { 614 614 .matches = { 615 615 DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ARCHOS"), 616 + DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "ARCHOS 101 CESIUM"), 617 + }, 618 + .driver_data = (void *)(BYTCR_INPUT_DEFAULTS | 619 + BYT_RT5640_JD_NOT_INV | 620 + BYT_RT5640_DIFF_MIC | 621 + BYT_RT5640_SSP0_AIF1 | 622 + BYT_RT5640_MCLK_EN), 623 + }, 624 + { 625 + .matches = { 626 + DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ARCHOS"), 616 627 DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "ARCHOS 140 CESIUM"), 617 628 }, 618 629 .driver_data = (void *)(BYT_RT5640_IN1_MAP |
+1 -1
sound/soc/intel/common/soc-acpi-intel-mtl-match.c
··· 293 293 .adr = 0x000130025D131801, 294 294 .num_endpoints = 1, 295 295 .endpoints = &single_endpoint, 296 - .name_prefix = "rt1318" 296 + .name_prefix = "rt1318-1" 297 297 } 298 298 }; 299 299
+5 -5
sound/soc/mediatek/mt8183/mt8183-da7219-max98357.c
··· 31 31 32 32 static struct snd_soc_jack_pin mt8183_da7219_max98357_jack_pins[] = { 33 33 { 34 - .pin = "Headphone", 34 + .pin = "Headphones", 35 35 .mask = SND_JACK_HEADPHONE, 36 36 }, 37 37 { ··· 626 626 }; 627 627 628 628 static const struct snd_kcontrol_new mt8183_da7219_max98357_snd_controls[] = { 629 - SOC_DAPM_PIN_SWITCH("Headphone"), 629 + SOC_DAPM_PIN_SWITCH("Headphones"), 630 630 SOC_DAPM_PIN_SWITCH("Headset Mic"), 631 631 SOC_DAPM_PIN_SWITCH("Speakers"), 632 632 SOC_DAPM_PIN_SWITCH("Line Out"), ··· 634 634 635 635 static const 636 636 struct snd_soc_dapm_widget mt8183_da7219_max98357_dapm_widgets[] = { 637 - SND_SOC_DAPM_HP("Headphone", NULL), 637 + SND_SOC_DAPM_HP("Headphones", NULL), 638 638 SND_SOC_DAPM_MIC("Headset Mic", NULL), 639 639 SND_SOC_DAPM_SPK("Speakers", NULL), 640 640 SND_SOC_DAPM_SPK("Line Out", NULL), ··· 680 680 }; 681 681 682 682 static const struct snd_kcontrol_new mt8183_da7219_rt1015_snd_controls[] = { 683 - SOC_DAPM_PIN_SWITCH("Headphone"), 683 + SOC_DAPM_PIN_SWITCH("Headphones"), 684 684 SOC_DAPM_PIN_SWITCH("Headset Mic"), 685 685 SOC_DAPM_PIN_SWITCH("Left Spk"), 686 686 SOC_DAPM_PIN_SWITCH("Right Spk"), ··· 689 689 690 690 static const 691 691 struct snd_soc_dapm_widget mt8183_da7219_rt1015_dapm_widgets[] = { 692 - SND_SOC_DAPM_HP("Headphone", NULL), 692 + SND_SOC_DAPM_HP("Headphones", NULL), 693 693 SND_SOC_DAPM_MIC("Headset Mic", NULL), 694 694 SND_SOC_DAPM_SPK("Left Spk", NULL), 695 695 SND_SOC_DAPM_SPK("Right Spk", NULL),
+1
sound/soc/mxs/mxs-pcm.c
··· 43 43 } 44 44 EXPORT_SYMBOL_GPL(mxs_pcm_platform_register); 45 45 46 + MODULE_DESCRIPTION("MXS ASoC PCM driver"); 46 47 MODULE_LICENSE("GPL");
+20 -12
sound/soc/qcom/qdsp6/q6apm-lpass-dais.c
··· 146 146 struct q6apm_lpass_dai_data *dai_data = dev_get_drvdata(dai->dev); 147 147 int rc; 148 148 149 - if (!dai_data->is_port_started[dai->id]) 150 - return; 151 - rc = q6apm_graph_stop(dai_data->graph[dai->id]); 152 - if (rc < 0) 153 - dev_err(dai->dev, "fail to close APM port (%d)\n", rc); 149 + if (dai_data->is_port_started[dai->id]) { 150 + rc = q6apm_graph_stop(dai_data->graph[dai->id]); 151 + dai_data->is_port_started[dai->id] = false; 152 + if (rc < 0) 153 + dev_err(dai->dev, "fail to close APM port (%d)\n", rc); 154 + } 154 155 155 - q6apm_graph_close(dai_data->graph[dai->id]); 156 - dai_data->is_port_started[dai->id] = false; 156 + if (dai_data->graph[dai->id]) { 157 + q6apm_graph_close(dai_data->graph[dai->id]); 158 + dai_data->graph[dai->id] = NULL; 159 + } 157 160 } 158 161 159 162 static int q6apm_lpass_dai_prepare(struct snd_pcm_substream *substream, struct snd_soc_dai *dai) ··· 171 168 q6apm_graph_stop(dai_data->graph[dai->id]); 172 169 dai_data->is_port_started[dai->id] = false; 173 170 174 - if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) 171 + if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) { 175 172 q6apm_graph_close(dai_data->graph[dai->id]); 173 + dai_data->graph[dai->id] = NULL; 174 + } 176 175 } 177 176 178 177 /** ··· 193 188 194 189 cfg->direction = substream->stream; 195 190 rc = q6apm_graph_media_format_pcm(dai_data->graph[dai->id], cfg); 196 - 197 191 if (rc) { 198 192 dev_err(dai->dev, "Failed to set media format %d\n", rc); 199 - return rc; 193 + goto err; 200 194 } 201 195 202 196 rc = q6apm_graph_prepare(dai_data->graph[dai->id]); 203 197 if (rc) { 204 198 dev_err(dai->dev, "Failed to prepare Graph %d\n", rc); 205 - return rc; 199 + goto err; 206 200 } 207 201 208 202 rc = q6apm_graph_start(dai_data->graph[dai->id]); 209 203 if (rc < 0) { 210 204 dev_err(dai->dev, "fail to start APM port %x\n", dai->id); 211 - return rc; 205 + goto err; 212 206 } 213 207 dai_data->is_port_started[dai->id] = true; 214 208 215 209 return 0; 210 + err: 211 + q6apm_graph_close(dai_data->graph[dai->id]); 212 + dai_data->graph[dai->id] = NULL; 213 + return rc; 216 214 } 217 215 218 216 static int q6apm_lpass_dai_startup(struct snd_pcm_substream *substream, struct snd_soc_dai *dai)
+1
sound/soc/qcom/sdw.c
··· 160 160 return 0; 161 161 } 162 162 EXPORT_SYMBOL_GPL(qcom_snd_sdw_hw_free); 163 + MODULE_DESCRIPTION("Qualcomm ASoC SoundWire helper functions"); 163 164 MODULE_LICENSE("GPL");
+11 -2
sound/soc/rockchip/rockchip_i2s_tdm.c
··· 655 655 int err; 656 656 657 657 if (i2s_tdm->is_master_mode) { 658 - struct clk *mclk = (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) ? 659 - i2s_tdm->mclk_tx : i2s_tdm->mclk_rx; 658 + struct clk *mclk; 659 + 660 + if (i2s_tdm->clk_trcm == TRCM_TX) { 661 + mclk = i2s_tdm->mclk_tx; 662 + } else if (i2s_tdm->clk_trcm == TRCM_RX) { 663 + mclk = i2s_tdm->mclk_rx; 664 + } else if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) { 665 + mclk = i2s_tdm->mclk_tx; 666 + } else { 667 + mclk = i2s_tdm->mclk_rx; 668 + } 660 669 661 670 err = clk_set_rate(mclk, DEFAULT_MCLK_FS * params_rate(params)); 662 671 if (err)
+8
sound/soc/soc-generic-dmaengine-pcm.c
··· 318 318 return 0; 319 319 } 320 320 321 + static int dmaengine_pcm_sync_stop(struct snd_soc_component *component, 322 + struct snd_pcm_substream *substream) 323 + { 324 + return snd_dmaengine_pcm_sync_stop(substream); 325 + } 326 + 321 327 static const struct snd_soc_component_driver dmaengine_pcm_component = { 322 328 .name = SND_DMAENGINE_PCM_DRV_NAME, 323 329 .probe_order = SND_SOC_COMP_ORDER_LATE, ··· 333 327 .trigger = dmaengine_pcm_trigger, 334 328 .pointer = dmaengine_pcm_pointer, 335 329 .pcm_construct = dmaengine_pcm_new, 330 + .sync_stop = dmaengine_pcm_sync_stop, 336 331 }; 337 332 338 333 static const struct snd_soc_component_driver dmaengine_pcm_component_process = { ··· 346 339 .pointer = dmaengine_pcm_pointer, 347 340 .copy = dmaengine_copy, 348 341 .pcm_construct = dmaengine_pcm_new, 342 + .sync_stop = dmaengine_pcm_sync_stop, 349 343 }; 350 344 351 345 static const char * const dmaengine_pcm_dma_channel_names[] = {
+17 -20
sound/soc/soc-topology.c
··· 1021 1021 struct snd_soc_tplg_hdr *hdr) 1022 1022 { 1023 1023 struct snd_soc_dapm_context *dapm = &tplg->comp->dapm; 1024 + const size_t maxlen = SNDRV_CTL_ELEM_ID_NAME_MAXLEN; 1024 1025 struct snd_soc_tplg_dapm_graph_elem *elem; 1025 1026 struct snd_soc_dapm_route *route; 1026 1027 int count, i; ··· 1045 1044 tplg->pos += sizeof(struct snd_soc_tplg_dapm_graph_elem); 1046 1045 1047 1046 /* validate routes */ 1048 - if (strnlen(elem->source, SNDRV_CTL_ELEM_ID_NAME_MAXLEN) == 1049 - SNDRV_CTL_ELEM_ID_NAME_MAXLEN) { 1050 - ret = -EINVAL; 1051 - break; 1052 - } 1053 - if (strnlen(elem->sink, SNDRV_CTL_ELEM_ID_NAME_MAXLEN) == 1054 - SNDRV_CTL_ELEM_ID_NAME_MAXLEN) { 1055 - ret = -EINVAL; 1056 - break; 1057 - } 1058 - if (strnlen(elem->control, SNDRV_CTL_ELEM_ID_NAME_MAXLEN) == 1059 - SNDRV_CTL_ELEM_ID_NAME_MAXLEN) { 1047 + if ((strnlen(elem->source, maxlen) == maxlen) || 1048 + (strnlen(elem->sink, maxlen) == maxlen) || 1049 + (strnlen(elem->control, maxlen) == maxlen)) { 1060 1050 ret = -EINVAL; 1061 1051 break; 1062 1052 } 1063 1053 1064 - route->source = elem->source; 1065 - route->sink = elem->sink; 1054 + route->source = devm_kstrdup(tplg->dev, elem->source, GFP_KERNEL); 1055 + route->sink = devm_kstrdup(tplg->dev, elem->sink, GFP_KERNEL); 1056 + if (!route->source || !route->sink) { 1057 + ret = -ENOMEM; 1058 + break; 1059 + } 1066 1060 1067 - /* set to NULL atm for tplg users */ 1068 - route->connected = NULL; 1069 - if (strnlen(elem->control, SNDRV_CTL_ELEM_ID_NAME_MAXLEN) == 0) 1070 - route->control = NULL; 1071 - else 1072 - route->control = elem->control; 1061 + if (strnlen(elem->control, maxlen) != 0) { 1062 + route->control = devm_kstrdup(tplg->dev, elem->control, GFP_KERNEL); 1063 + if (!route->control) { 1064 + ret = -ENOMEM; 1065 + break; 1066 + } 1067 + } 1073 1068 1074 1069 /* add route dobj to dobj_list */ 1075 1070 route->dobj.type = SND_SOC_DOBJ_GRAPH;
+4 -2
sound/soc/sof/intel/hda-dai.c
··· 379 379 380 380 sdev = widget_to_sdev(w); 381 381 if (sdev->dspless_mode_selected) 382 - goto skip_tlv; 382 + return 0; 383 383 384 384 /* get stream_id */ 385 385 hext_stream = ops->get_hext_stream(sdev, cpu_dai, substream); ··· 423 423 dma_config->dma_stream_channel_map.device_count = 1; 424 424 dma_config->dma_priv_config_size = 0; 425 425 426 - skip_tlv: 427 426 return 0; 428 427 } 429 428 ··· 523 524 __func__, ret); 524 525 return ret; 525 526 } 527 + 528 + if (sdev->dspless_mode_selected) 529 + return 0; 526 530 527 531 ipc4_copier = widget_to_copier(w); 528 532 dma_config_tlv = &ipc4_copier->dma_config_tlv[cpu_dai_id];
+1 -1
sound/soc/sof/sof-audio.c
··· 485 485 if (ret < 0) { 486 486 /* unprepare the source widget */ 487 487 if (widget_ops[widget->id].ipc_unprepare && 488 - swidget && swidget->prepared) { 488 + swidget && swidget->prepared && swidget->use_count == 0) { 489 489 widget_ops[widget->id].ipc_unprepare(swidget); 490 490 swidget->prepared = false; 491 491 }
+7 -2
sound/soc/ti/davinci-mcasp.c
··· 1472 1472 { 1473 1473 struct snd_interval *period_size = hw_param_interval(params, 1474 1474 SNDRV_PCM_HW_PARAM_PERIOD_SIZE); 1475 + u8 numevt = *((u8 *)rule->private); 1475 1476 struct snd_interval frames; 1476 1477 1477 1478 snd_interval_any(&frames); 1478 - frames.min = 64; 1479 + frames.min = numevt; 1479 1480 frames.integer = 1; 1480 1481 1481 1482 return snd_interval_refine(period_size, &frames); ··· 1491 1490 u32 max_channels = 0; 1492 1491 int i, dir, ret; 1493 1492 int tdm_slots = mcasp->tdm_slots; 1493 + u8 *numevt; 1494 1494 1495 1495 /* Do not allow more then one stream per direction */ 1496 1496 if (mcasp->substreams[substream->stream]) ··· 1591 1589 return ret; 1592 1590 } 1593 1591 1592 + numevt = (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) ? 1593 + &mcasp->txnumevt : 1594 + &mcasp->rxnumevt; 1594 1595 snd_pcm_hw_rule_add(substream->runtime, 0, 1595 1596 SNDRV_PCM_HW_PARAM_PERIOD_SIZE, 1596 - davinci_mcasp_hw_rule_min_periodsize, NULL, 1597 + davinci_mcasp_hw_rule_min_periodsize, numevt, 1597 1598 SNDRV_PCM_HW_PARAM_PERIOD_SIZE, -1); 1598 1599 1599 1600 return 0;
+1 -5
sound/soc/ti/omap-hdmi.c
··· 354 354 if (!card) 355 355 return -ENOMEM; 356 356 357 - card->name = devm_kasprintf(dev, GFP_KERNEL, 358 - "HDMI %s", dev_name(ad->dssdev)); 359 - if (!card->name) 360 - return -ENOMEM; 361 - 357 + card->name = "HDMI"; 362 358 card->owner = THIS_MODULE; 363 359 card->dai_link = 364 360 devm_kzalloc(dev, sizeof(*(card->dai_link)), GFP_KERNEL);