diff options
Diffstat (limited to 'sound/core')
-rw-r--r-- | sound/core/init.c | 14 | ||||
-rw-r--r-- | sound/core/sound.c | 2 |
2 files changed, 5 insertions, 11 deletions
diff --git a/sound/core/init.c b/sound/core/init.c index c72a79115cca..59202de1d2ce 100644 --- a/sound/core/init.c +++ b/sound/core/init.c | |||
@@ -676,8 +676,8 @@ struct snd_generic_device { | |||
676 | #define SND_GENERIC_NAME "snd_generic" | 676 | #define SND_GENERIC_NAME "snd_generic" |
677 | 677 | ||
678 | #ifdef CONFIG_PM | 678 | #ifdef CONFIG_PM |
679 | static int snd_generic_suspend(struct device *dev, pm_message_t state, u32 level); | 679 | static int snd_generic_suspend(struct device *dev, pm_message_t state); |
680 | static int snd_generic_resume(struct device *dev, u32 level); | 680 | static int snd_generic_resume(struct device *dev); |
681 | #endif | 681 | #endif |
682 | 682 | ||
683 | /* initialized in sound.c */ | 683 | /* initialized in sound.c */ |
@@ -818,13 +818,10 @@ int snd_card_set_pm_callback(snd_card_t *card, | |||
818 | 818 | ||
819 | #ifdef CONFIG_SND_GENERIC_DRIVER | 819 | #ifdef CONFIG_SND_GENERIC_DRIVER |
820 | /* suspend/resume callbacks for snd_generic platform device */ | 820 | /* suspend/resume callbacks for snd_generic platform device */ |
821 | static int snd_generic_suspend(struct device *dev, pm_message_t state, u32 level) | 821 | static int snd_generic_suspend(struct device *dev, pm_message_t state) |
822 | { | 822 | { |
823 | snd_card_t *card; | 823 | snd_card_t *card; |
824 | 824 | ||
825 | if (level != SUSPEND_DISABLE) | ||
826 | return 0; | ||
827 | |||
828 | card = get_snd_generic_card(dev); | 825 | card = get_snd_generic_card(dev); |
829 | if (card->power_state == SNDRV_CTL_POWER_D3hot) | 826 | if (card->power_state == SNDRV_CTL_POWER_D3hot) |
830 | return 0; | 827 | return 0; |
@@ -834,13 +831,10 @@ static int snd_generic_suspend(struct device *dev, pm_message_t state, u32 level | |||
834 | return 0; | 831 | return 0; |
835 | } | 832 | } |
836 | 833 | ||
837 | static int snd_generic_resume(struct device *dev, u32 level) | 834 | static int snd_generic_resume(struct device *dev) |
838 | { | 835 | { |
839 | snd_card_t *card; | 836 | snd_card_t *card; |
840 | 837 | ||
841 | if (level != RESUME_ENABLE) | ||
842 | return 0; | ||
843 | |||
844 | card = get_snd_generic_card(dev); | 838 | card = get_snd_generic_card(dev); |
845 | if (card->power_state == SNDRV_CTL_POWER_D0) | 839 | if (card->power_state == SNDRV_CTL_POWER_D0) |
846 | return 0; | 840 | return 0; |
diff --git a/sound/core/sound.c b/sound/core/sound.c index 9e76bddb2c0b..b57519a3e3d9 100644 --- a/sound/core/sound.c +++ b/sound/core/sound.c | |||
@@ -231,7 +231,7 @@ int snd_register_device(int type, snd_card_t * card, int dev, snd_minor_t * reg, | |||
231 | devfs_mk_cdev(MKDEV(major, minor), S_IFCHR | device_mode, "snd/%s", name); | 231 | devfs_mk_cdev(MKDEV(major, minor), S_IFCHR | device_mode, "snd/%s", name); |
232 | if (card) | 232 | if (card) |
233 | device = card->dev; | 233 | device = card->dev; |
234 | class_device_create(sound_class, MKDEV(major, minor), device, "%s", name); | 234 | class_device_create(sound_class, NULL, MKDEV(major, minor), device, "%s", name); |
235 | 235 | ||
236 | up(&sound_mutex); | 236 | up(&sound_mutex); |
237 | return 0; | 237 | return 0; |