diff options
Diffstat (limited to 'sound/soc/soc-devres.c')
-rw-r--r-- | sound/soc/soc-devres.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/soc-devres.c b/sound/soc/soc-devres.c index b1d732255c02..3449c1e909ae 100644 --- a/sound/soc/soc-devres.c +++ b/sound/soc/soc-devres.c | |||
@@ -66,7 +66,7 @@ static void devm_card_release(struct device *dev, void *res) | |||
66 | */ | 66 | */ |
67 | int devm_snd_soc_register_card(struct device *dev, struct snd_soc_card *card) | 67 | int devm_snd_soc_register_card(struct device *dev, struct snd_soc_card *card) |
68 | { | 68 | { |
69 | struct device **ptr; | 69 | struct snd_soc_card **ptr; |
70 | int ret; | 70 | int ret; |
71 | 71 | ||
72 | ptr = devres_alloc(devm_card_release, sizeof(*ptr), GFP_KERNEL); | 72 | ptr = devres_alloc(devm_card_release, sizeof(*ptr), GFP_KERNEL); |
@@ -75,7 +75,7 @@ int devm_snd_soc_register_card(struct device *dev, struct snd_soc_card *card) | |||
75 | 75 | ||
76 | ret = snd_soc_register_card(card); | 76 | ret = snd_soc_register_card(card); |
77 | if (ret == 0) { | 77 | if (ret == 0) { |
78 | *ptr = dev; | 78 | *ptr = card; |
79 | devres_add(dev, ptr); | 79 | devres_add(dev, ptr); |
80 | } else { | 80 | } else { |
81 | devres_free(ptr); | 81 | devres_free(ptr); |