diff options
Diffstat (limited to 'sound/pci/hda/hda_codec.h')
-rw-r--r-- | sound/pci/hda/hda_codec.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h index 56b4f74c0b13..54b52819fb47 100644 --- a/sound/pci/hda/hda_codec.h +++ b/sound/pci/hda/hda_codec.h | |||
@@ -704,8 +704,6 @@ struct hda_codec_ops { | |||
704 | unsigned int power_state); | 704 | unsigned int power_state); |
705 | #ifdef CONFIG_PM | 705 | #ifdef CONFIG_PM |
706 | int (*suspend)(struct hda_codec *codec, pm_message_t state); | 706 | int (*suspend)(struct hda_codec *codec, pm_message_t state); |
707 | int (*post_suspend)(struct hda_codec *codec); | ||
708 | int (*pre_resume)(struct hda_codec *codec); | ||
709 | int (*resume)(struct hda_codec *codec); | 707 | int (*resume)(struct hda_codec *codec); |
710 | #endif | 708 | #endif |
711 | #ifdef CONFIG_SND_HDA_POWER_SAVE | 709 | #ifdef CONFIG_SND_HDA_POWER_SAVE |
@@ -829,6 +827,7 @@ struct hda_codec { | |||
829 | 827 | ||
830 | struct mutex spdif_mutex; | 828 | struct mutex spdif_mutex; |
831 | struct mutex control_mutex; | 829 | struct mutex control_mutex; |
830 | struct mutex hash_mutex; | ||
832 | struct snd_array spdif_out; | 831 | struct snd_array spdif_out; |
833 | unsigned int spdif_in_enable; /* SPDIF input enable? */ | 832 | unsigned int spdif_in_enable; /* SPDIF input enable? */ |
834 | const hda_nid_t *slave_dig_outs; /* optional digital out slave widgets */ | 833 | const hda_nid_t *slave_dig_outs; /* optional digital out slave widgets */ |
@@ -861,12 +860,13 @@ struct hda_codec { | |||
861 | unsigned int no_jack_detect:1; /* Machine has no jack-detection */ | 860 | unsigned int no_jack_detect:1; /* Machine has no jack-detection */ |
862 | #ifdef CONFIG_SND_HDA_POWER_SAVE | 861 | #ifdef CONFIG_SND_HDA_POWER_SAVE |
863 | unsigned int power_on :1; /* current (global) power-state */ | 862 | unsigned int power_on :1; /* current (global) power-state */ |
864 | unsigned int power_transition :1; /* power-state in transition */ | 863 | int power_transition; /* power-state in transition */ |
865 | int power_count; /* current (global) power refcount */ | 864 | int power_count; /* current (global) power refcount */ |
866 | struct delayed_work power_work; /* delayed task for powerdown */ | 865 | struct delayed_work power_work; /* delayed task for powerdown */ |
867 | unsigned long power_on_acct; | 866 | unsigned long power_on_acct; |
868 | unsigned long power_off_acct; | 867 | unsigned long power_off_acct; |
869 | unsigned long power_jiffies; | 868 | unsigned long power_jiffies; |
869 | spinlock_t power_lock; | ||
870 | #endif | 870 | #endif |
871 | 871 | ||
872 | /* codec-specific additional proc output */ | 872 | /* codec-specific additional proc output */ |
@@ -911,10 +911,13 @@ int snd_hda_get_sub_nodes(struct hda_codec *codec, hda_nid_t nid, | |||
911 | hda_nid_t *start_id); | 911 | hda_nid_t *start_id); |
912 | int snd_hda_get_connections(struct hda_codec *codec, hda_nid_t nid, | 912 | int snd_hda_get_connections(struct hda_codec *codec, hda_nid_t nid, |
913 | hda_nid_t *conn_list, int max_conns); | 913 | hda_nid_t *conn_list, int max_conns); |
914 | static inline int | ||
915 | snd_hda_get_num_conns(struct hda_codec *codec, hda_nid_t nid) | ||
916 | { | ||
917 | return snd_hda_get_connections(codec, nid, NULL, 0); | ||
918 | } | ||
914 | int snd_hda_get_raw_connections(struct hda_codec *codec, hda_nid_t nid, | 919 | int snd_hda_get_raw_connections(struct hda_codec *codec, hda_nid_t nid, |
915 | hda_nid_t *conn_list, int max_conns); | 920 | hda_nid_t *conn_list, int max_conns); |
916 | int snd_hda_get_conn_list(struct hda_codec *codec, hda_nid_t nid, | ||
917 | const hda_nid_t **listp); | ||
918 | int snd_hda_override_conn_list(struct hda_codec *codec, hda_nid_t nid, int nums, | 921 | int snd_hda_override_conn_list(struct hda_codec *codec, hda_nid_t nid, int nums, |
919 | const hda_nid_t *list); | 922 | const hda_nid_t *list); |
920 | int snd_hda_get_conn_index(struct hda_codec *codec, hda_nid_t mux, | 923 | int snd_hda_get_conn_index(struct hda_codec *codec, hda_nid_t mux, |
@@ -1051,12 +1054,10 @@ const char *snd_hda_get_jack_location(u32 cfg); | |||
1051 | #ifdef CONFIG_SND_HDA_POWER_SAVE | 1054 | #ifdef CONFIG_SND_HDA_POWER_SAVE |
1052 | void snd_hda_power_up(struct hda_codec *codec); | 1055 | void snd_hda_power_up(struct hda_codec *codec); |
1053 | void snd_hda_power_down(struct hda_codec *codec); | 1056 | void snd_hda_power_down(struct hda_codec *codec); |
1054 | #define snd_hda_codec_needs_resume(codec) codec->power_count | ||
1055 | void snd_hda_update_power_acct(struct hda_codec *codec); | 1057 | void snd_hda_update_power_acct(struct hda_codec *codec); |
1056 | #else | 1058 | #else |
1057 | static inline void snd_hda_power_up(struct hda_codec *codec) {} | 1059 | static inline void snd_hda_power_up(struct hda_codec *codec) {} |
1058 | static inline void snd_hda_power_down(struct hda_codec *codec) {} | 1060 | static inline void snd_hda_power_down(struct hda_codec *codec) {} |
1059 | #define snd_hda_codec_needs_resume(codec) 1 | ||
1060 | #endif | 1061 | #endif |
1061 | 1062 | ||
1062 | #ifdef CONFIG_SND_HDA_PATCH_LOADER | 1063 | #ifdef CONFIG_SND_HDA_PATCH_LOADER |