Skip to content

Commit eb379c3

Browse files
committed
Merge branch 'for-linus' into for-next
Pull the last minute fixes for 6.17. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2 parents 6b9c4a0 + 5c444aa commit eb379c3

File tree

5 files changed

+34
-25
lines changed

5 files changed

+34
-25
lines changed

sound/soc/codecs/tlv320aic3x.c

Lines changed: 14 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,16 @@ static const struct reg_default aic3x_reg[] = {
121121
{ 108, 0x00 }, { 109, 0x00 },
122122
};
123123

124+
static const struct reg_sequence aic3007_class_d[] = {
125+
/* Class-D speaker driver init; datasheet p. 46 */
126+
{ AIC3X_PAGE_SELECT, 0x0D },
127+
{ 0xD, 0x0D },
128+
{ 0x8, 0x5C },
129+
{ 0x8, 0x5D },
130+
{ 0x8, 0x5C },
131+
{ AIC3X_PAGE_SELECT, 0x00 },
132+
};
133+
124134
static bool aic3x_volatile_reg(struct device *dev, unsigned int reg)
125135
{
126136
switch (reg) {
@@ -1393,6 +1403,10 @@ static int aic3x_set_power(struct snd_soc_component *component, int power)
13931403
gpiod_set_value(aic3x->gpio_reset, 0);
13941404
}
13951405

1406+
if (aic3x->model == AIC3X_MODEL_3007)
1407+
regmap_multi_reg_write_bypassed(aic3x->regmap, aic3007_class_d,
1408+
ARRAY_SIZE(aic3007_class_d));
1409+
13961410
/* Sync reg_cache with the hardware */
13971411
regcache_cache_only(aic3x->regmap, false);
13981412
regcache_sync(aic3x->regmap);
@@ -1723,17 +1737,6 @@ static void aic3x_configure_ocmv(struct device *dev, struct aic3x_priv *aic3x)
17231737
}
17241738
}
17251739

1726-
1727-
static const struct reg_sequence aic3007_class_d[] = {
1728-
/* Class-D speaker driver init; datasheet p. 46 */
1729-
{ AIC3X_PAGE_SELECT, 0x0D },
1730-
{ 0xD, 0x0D },
1731-
{ 0x8, 0x5C },
1732-
{ 0x8, 0x5D },
1733-
{ 0x8, 0x5C },
1734-
{ AIC3X_PAGE_SELECT, 0x00 },
1735-
};
1736-
17371740
int aic3x_probe(struct device *dev, struct regmap *regmap, kernel_ulong_t driver_data)
17381741
{
17391742
struct aic3x_priv *aic3x;
@@ -1823,13 +1826,6 @@ int aic3x_probe(struct device *dev, struct regmap *regmap, kernel_ulong_t driver
18231826

18241827
aic3x_configure_ocmv(dev, aic3x);
18251828

1826-
if (aic3x->model == AIC3X_MODEL_3007) {
1827-
ret = regmap_register_patch(aic3x->regmap, aic3007_class_d,
1828-
ARRAY_SIZE(aic3007_class_d));
1829-
if (ret != 0)
1830-
dev_err(dev, "Failed to init class D: %d\n", ret);
1831-
}
1832-
18331829
ret = devm_snd_soc_register_component(dev, &soc_component_dev_aic3x, &aic3x_dai, 1);
18341830
if (ret)
18351831
return ret;

sound/soc/codecs/wcd934x.c

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5794,6 +5794,13 @@ static const struct snd_soc_component_driver wcd934x_component_drv = {
57945794
.endianness = 1,
57955795
};
57965796

5797+
static void wcd934x_put_device_action(void *data)
5798+
{
5799+
struct device *dev = data;
5800+
5801+
put_device(dev);
5802+
}
5803+
57975804
static int wcd934x_codec_parse_data(struct wcd934x_codec *wcd)
57985805
{
57995806
struct device *dev = &wcd->sdev->dev;
@@ -5810,11 +5817,13 @@ static int wcd934x_codec_parse_data(struct wcd934x_codec *wcd)
58105817
return dev_err_probe(dev, -EINVAL, "Unable to get SLIM Interface device\n");
58115818

58125819
slim_get_logical_addr(wcd->sidev);
5813-
wcd->if_regmap = regmap_init_slimbus(wcd->sidev,
5820+
wcd->if_regmap = devm_regmap_init_slimbus(wcd->sidev,
58145821
&wcd934x_ifc_regmap_config);
5815-
if (IS_ERR(wcd->if_regmap))
5822+
if (IS_ERR(wcd->if_regmap)) {
5823+
put_device(&wcd->sidev->dev);
58165824
return dev_err_probe(dev, PTR_ERR(wcd->if_regmap),
58175825
"Failed to allocate ifc register map\n");
5826+
}
58185827

58195828
of_property_read_u32(dev->parent->of_node, "qcom,dmic-sample-rate",
58205829
&wcd->dmic_sample_rate);
@@ -5857,6 +5866,10 @@ static int wcd934x_codec_probe(struct platform_device *pdev)
58575866
if (ret)
58585867
return ret;
58595868

5869+
ret = devm_add_action_or_reset(dev, wcd934x_put_device_action, &wcd->sidev->dev);
5870+
if (ret)
5871+
return ret;
5872+
58605873
/* set default rate 9P6MHz */
58615874
regmap_update_bits(wcd->regmap, WCD934X_CODEC_RPM_CLK_MCLK_CFG,
58625875
WCD934X_CODEC_RPM_CLK_MCLK_CFG_MCLK_MASK,

sound/soc/intel/boards/sof_sdw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -841,7 +841,7 @@ static int create_sdw_dailink(struct snd_soc_card *card,
841841
(*codec_conf)++;
842842
}
843843

844-
if (sof_end->include_sidecar) {
844+
if (sof_end->include_sidecar && sof_end->codec_info->add_sidecar) {
845845
ret = sof_end->codec_info->add_sidecar(card, dai_links, codec_conf);
846846
if (ret)
847847
return ret;

sound/soc/qcom/sc8280xp.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,8 +194,8 @@ static const struct of_device_id snd_sc8280xp_dt_match[] = {
194194
{.compatible = "qcom,qcm6490-idp-sndcard", "qcm6490"},
195195
{.compatible = "qcom,qcs6490-rb3gen2-sndcard", "qcs6490"},
196196
{.compatible = "qcom,qcs8275-sndcard", "qcs8300"},
197-
{.compatible = "qcom,qcs9075-sndcard", "qcs9075"},
198-
{.compatible = "qcom,qcs9100-sndcard", "qcs9100"},
197+
{.compatible = "qcom,qcs9075-sndcard", "sa8775p"},
198+
{.compatible = "qcom,qcs9100-sndcard", "sa8775p"},
199199
{.compatible = "qcom,sc8280xp-sndcard", "sc8280xp"},
200200
{.compatible = "qcom,sm8450-sndcard", "sm8450"},
201201
{.compatible = "qcom,sm8550-sndcard", "sm8550"},

sound/soc/sof/ipc4-pcm.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -639,14 +639,14 @@ static int ipc4_ssp_dai_config_pcm_params_match(struct snd_sof_dev *sdev,
639639

640640
if (params_rate(params) == le32_to_cpu(hw_config->fsync_rate) &&
641641
params_width(params) == le32_to_cpu(hw_config->tdm_slot_width) &&
642-
params_channels(params) == le32_to_cpu(hw_config->tdm_slots)) {
642+
params_channels(params) <= le32_to_cpu(hw_config->tdm_slots)) {
643643
current_config = le32_to_cpu(hw_config->id);
644644
partial_match = false;
645645
/* best match found */
646646
break;
647647
} else if (current_config < 0 &&
648648
params_rate(params) == le32_to_cpu(hw_config->fsync_rate) &&
649-
params_channels(params) == le32_to_cpu(hw_config->tdm_slots)) {
649+
params_channels(params) <= le32_to_cpu(hw_config->tdm_slots)) {
650650
current_config = le32_to_cpu(hw_config->id);
651651
partial_match = true;
652652
/* keep looking for better match */

0 commit comments

Comments
 (0)