Commit 82af2b7f authored by Mark Brown's avatar Mark Brown

Merge remote-tracking branches 'asoc/topic/adau1977', 'asoc/topic/arizona',...

Merge remote-tracking branches 'asoc/topic/adau1977', 'asoc/topic/arizona', 'asoc/topic/atmel', 'asoc/topic/au1x' and 'asoc/topic/bcm' into asoc-next
...@@ -783,7 +783,9 @@ static int atmel_ac97c_probe(struct platform_device *pdev) ...@@ -783,7 +783,9 @@ static int atmel_ac97c_probe(struct platform_device *pdev)
dev_dbg(&pdev->dev, "no peripheral clock\n"); dev_dbg(&pdev->dev, "no peripheral clock\n");
return PTR_ERR(pclk); return PTR_ERR(pclk);
} }
clk_prepare_enable(pclk); retval = clk_prepare_enable(pclk);
if (retval)
goto err_prepare_enable;
retval = snd_card_new(&pdev->dev, SNDRV_DEFAULT_IDX1, retval = snd_card_new(&pdev->dev, SNDRV_DEFAULT_IDX1,
SNDRV_DEFAULT_STR1, THIS_MODULE, SNDRV_DEFAULT_STR1, THIS_MODULE,
...@@ -879,6 +881,7 @@ static int atmel_ac97c_probe(struct platform_device *pdev) ...@@ -879,6 +881,7 @@ static int atmel_ac97c_probe(struct platform_device *pdev)
snd_card_free(card); snd_card_free(card);
err_snd_card_new: err_snd_card_new:
clk_disable_unprepare(pclk); clk_disable_unprepare(pclk);
err_prepare_enable:
clk_put(pclk); clk_put(pclk);
return retval; return retval;
} }
...@@ -897,9 +900,9 @@ static int atmel_ac97c_resume(struct device *pdev) ...@@ -897,9 +900,9 @@ static int atmel_ac97c_resume(struct device *pdev)
{ {
struct snd_card *card = dev_get_drvdata(pdev); struct snd_card *card = dev_get_drvdata(pdev);
struct atmel_ac97c *chip = card->private_data; struct atmel_ac97c *chip = card->private_data;
int ret = clk_prepare_enable(chip->pclk);
clk_prepare_enable(chip->pclk); return ret;
return 0;
} }
static SIMPLE_DEV_PM_OPS(atmel_ac97c_pm, atmel_ac97c_suspend, atmel_ac97c_resume); static SIMPLE_DEV_PM_OPS(atmel_ac97c_pm, atmel_ac97c_suspend, atmel_ac97c_resume);
......
...@@ -652,7 +652,6 @@ static int atmel_classd_probe(struct platform_device *pdev) ...@@ -652,7 +652,6 @@ static int atmel_classd_probe(struct platform_device *pdev)
} }
snd_soc_card_set_drvdata(card, dd); snd_soc_card_set_drvdata(card, dd);
platform_set_drvdata(pdev, card);
ret = atmel_classd_asoc_card_init(dev, card); ret = atmel_classd_asoc_card_init(dev, card);
if (ret) { if (ret) {
......
...@@ -694,7 +694,6 @@ static int atmel_pdmic_probe(struct platform_device *pdev) ...@@ -694,7 +694,6 @@ static int atmel_pdmic_probe(struct platform_device *pdev)
} }
snd_soc_card_set_drvdata(card, dd); snd_soc_card_set_drvdata(card, dd);
platform_set_drvdata(pdev, card);
ret = atmel_pdmic_asoc_card_init(dev, card); ret = atmel_pdmic_asoc_card_init(dev, card);
if (ret) { if (ret) {
......
...@@ -99,7 +99,7 @@ static int db1200_i2s_startup(struct snd_pcm_substream *substream) ...@@ -99,7 +99,7 @@ static int db1200_i2s_startup(struct snd_pcm_substream *substream)
return 0; return 0;
} }
static struct snd_soc_ops db1200_i2s_wm8731_ops = { static const struct snd_soc_ops db1200_i2s_wm8731_ops = {
.startup = db1200_i2s_startup, .startup = db1200_i2s_startup,
}; };
......
...@@ -304,7 +304,7 @@ static int au1xpsc_pcm_close(struct snd_pcm_substream *substream) ...@@ -304,7 +304,7 @@ static int au1xpsc_pcm_close(struct snd_pcm_substream *substream)
return 0; return 0;
} }
static struct snd_pcm_ops au1xpsc_pcm_ops = { static const struct snd_pcm_ops au1xpsc_pcm_ops = {
.open = au1xpsc_pcm_open, .open = au1xpsc_pcm_open,
.close = au1xpsc_pcm_close, .close = au1xpsc_pcm_close,
.ioctl = snd_pcm_lib_ioctl, .ioctl = snd_pcm_lib_ioctl,
......
...@@ -277,7 +277,7 @@ static snd_pcm_uframes_t alchemy_pcm_pointer(struct snd_pcm_substream *ss) ...@@ -277,7 +277,7 @@ static snd_pcm_uframes_t alchemy_pcm_pointer(struct snd_pcm_substream *ss)
return bytes_to_frames(ss->runtime, location); return bytes_to_frames(ss->runtime, location);
} }
static struct snd_pcm_ops alchemy_pcm_ops = { static const struct snd_pcm_ops alchemy_pcm_ops = {
.open = alchemy_pcm_open, .open = alchemy_pcm_open,
.close = alchemy_pcm_close, .close = alchemy_pcm_close,
.ioctl = snd_pcm_lib_ioctl, .ioctl = snd_pcm_lib_ioctl,
......
...@@ -392,7 +392,7 @@ static int au1xpsc_i2s_drvresume(struct device *dev) ...@@ -392,7 +392,7 @@ static int au1xpsc_i2s_drvresume(struct device *dev)
return 0; return 0;
} }
static struct dev_pm_ops au1xpsci2s_pmops = { static const struct dev_pm_ops au1xpsci2s_pmops = {
.suspend = au1xpsc_i2s_drvsuspend, .suspend = au1xpsc_i2s_drvsuspend,
.resume = au1xpsc_i2s_drvresume, .resume = au1xpsc_i2s_drvresume,
}; };
......
...@@ -1288,7 +1288,7 @@ static const struct snd_soc_dai_driver cygnus_ssp_dai_info[] = { ...@@ -1288,7 +1288,7 @@ static const struct snd_soc_dai_driver cygnus_ssp_dai_info[] = {
INIT_CPU_DAI(2), INIT_CPU_DAI(2),
}; };
static struct snd_soc_dai_driver cygnus_spdif_dai_info = { static const struct snd_soc_dai_driver cygnus_spdif_dai_info = {
.name = "cygnus-spdif", .name = "cygnus-spdif",
.playback = { .playback = {
.channels_min = 2, .channels_min = 2,
......
...@@ -388,8 +388,7 @@ static int adau1977_power_disable(struct adau1977 *adau1977) ...@@ -388,8 +388,7 @@ static int adau1977_power_disable(struct adau1977 *adau1977)
regcache_mark_dirty(adau1977->regmap); regcache_mark_dirty(adau1977->regmap);
if (adau1977->reset_gpio) gpiod_set_value_cansleep(adau1977->reset_gpio, 0);
gpiod_set_value_cansleep(adau1977->reset_gpio, 0);
regcache_cache_only(adau1977->regmap, true); regcache_cache_only(adau1977->regmap, true);
...@@ -420,8 +419,7 @@ static int adau1977_power_enable(struct adau1977 *adau1977) ...@@ -420,8 +419,7 @@ static int adau1977_power_enable(struct adau1977 *adau1977)
goto err_disable_avdd; goto err_disable_avdd;
} }
if (adau1977->reset_gpio) gpiod_set_value_cansleep(adau1977->reset_gpio, 1);
gpiod_set_value_cansleep(adau1977->reset_gpio, 1);
regcache_cache_only(adau1977->regmap, false); regcache_cache_only(adau1977->regmap, false);
......
...@@ -1203,7 +1203,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_cs47l24 = { ...@@ -1203,7 +1203,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_cs47l24 = {
}, },
}; };
static struct snd_compr_ops cs47l24_compr_ops = { static const struct snd_compr_ops cs47l24_compr_ops = {
.open = cs47l24_open, .open = cs47l24_open,
.free = wm_adsp_compr_free, .free = wm_adsp_compr_free,
.set_params = wm_adsp_compr_set_params, .set_params = wm_adsp_compr_set_params,
......
...@@ -2017,7 +2017,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_wm5102 = { ...@@ -2017,7 +2017,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_wm5102 = {
}, },
}; };
static struct snd_compr_ops wm5102_compr_ops = { static const struct snd_compr_ops wm5102_compr_ops = {
.open = wm5102_open, .open = wm5102_open,
.free = wm_adsp_compr_free, .free = wm_adsp_compr_free,
.set_params = wm_adsp_compr_set_params, .set_params = wm_adsp_compr_set_params,
......
...@@ -2372,7 +2372,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_wm5110 = { ...@@ -2372,7 +2372,7 @@ static const struct snd_soc_codec_driver soc_codec_dev_wm5110 = {
}, },
}; };
static struct snd_compr_ops wm5110_compr_ops = { static const struct snd_compr_ops wm5110_compr_ops = {
.open = wm5110_open, .open = wm5110_open,
.free = wm_adsp_compr_free, .free = wm_adsp_compr_free,
.set_params = wm_adsp_compr_set_params, .set_params = wm_adsp_compr_set_params,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment