mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 01:10:04 +00:00
ASoC: Use dev_set_name() instead of init_name
init_name is basically a hack and should only be used for statically allocated device structs. For dynamically allocated devices dev_set_name() should be used. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@linaro.org>
This commit is contained in:
parent
7d1311b93e
commit
f294afed03
1 changed files with 1 additions and 1 deletions
|
@ -1325,7 +1325,7 @@ static int soc_post_component_init(struct snd_soc_pcm_runtime *rtd,
|
|||
device_initialize(rtd->dev);
|
||||
rtd->dev->parent = rtd->card->dev;
|
||||
rtd->dev->release = rtd_release;
|
||||
rtd->dev->init_name = name;
|
||||
dev_set_name(rtd->dev, "%s", name);
|
||||
dev_set_drvdata(rtd->dev, rtd);
|
||||
mutex_init(&rtd->pcm_mutex);
|
||||
INIT_LIST_HEAD(&rtd->dpcm[SNDRV_PCM_STREAM_PLAYBACK].be_clients);
|
||||
|
|
Loading…
Reference in a new issue