Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/j.anaszewski...
[linux-2.6-block.git] / include / sound / hda_i915.h
CommitLineData
98d8fc6c
ML
1/*
2 * HD-Audio helpers to sync with i915 driver
3 */
4#ifndef __SOUND_HDA_I915_H
5#define __SOUND_HDA_I915_H
6
45c053df
DH
7#include <drm/i915_component.h>
8
98d8fc6c
ML
9#ifdef CONFIG_SND_HDA_I915
10int snd_hdac_set_codec_wakeup(struct hdac_bus *bus, bool enable);
11int snd_hdac_display_power(struct hdac_bus *bus, bool enable);
bb03ed21 12void snd_hdac_i915_set_bclk(struct hdac_bus *bus);
e2dc7d7d
TI
13int snd_hdac_sync_audio_rate(struct hdac_bus *bus, hda_nid_t nid, int rate);
14int snd_hdac_acomp_get_eld(struct hdac_bus *bus, hda_nid_t nid,
15 bool *audio_enabled, char *buffer, int max_bytes);
98d8fc6c
ML
16int snd_hdac_i915_init(struct hdac_bus *bus);
17int snd_hdac_i915_exit(struct hdac_bus *bus);
45c053df 18int snd_hdac_i915_register_notifier(const struct i915_audio_component_audio_ops *);
98d8fc6c 19#else
6869de38 20static inline int snd_hdac_set_codec_wakeup(struct hdac_bus *bus, bool enable)
98d8fc6c
ML
21{
22 return 0;
23}
24static inline int snd_hdac_display_power(struct hdac_bus *bus, bool enable)
25{
26 return 0;
27}
bb03ed21 28static inline void snd_hdac_i915_set_bclk(struct hdac_bus *bus)
98d8fc6c 29{
98d8fc6c 30}
e2dc7d7d
TI
31static inline int snd_hdac_sync_audio_rate(struct hdac_bus *bus, hda_nid_t nid,
32 int rate)
33{
34 return 0;
35}
36static inline int snd_hdac_acomp_get_eld(struct hdac_bus *bus, hda_nid_t nid,
37 bool *audio_enabled, char *buffer,
38 int max_bytes)
39{
40 return -ENODEV;
41}
98d8fc6c
ML
42static inline int snd_hdac_i915_init(struct hdac_bus *bus)
43{
44 return -ENODEV;
45}
46static inline int snd_hdac_i915_exit(struct hdac_bus *bus)
47{
48 return 0;
49}
45c053df
DH
50static inline int snd_hdac_i915_register_notifier(const struct i915_audio_component_audio_ops *ops)
51{
52 return -ENODEV;
53}
98d8fc6c
ML
54#endif
55
56#endif /* __SOUND_HDA_I915_H */