summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorLibin Yang <libin.yang@intel.com>2015-10-01 12:01:08 +0300
committerDaniel Vetter <daniel.vetter@ffwll.ch>2015-10-07 17:05:37 +0300
commit3f4c90bd203125c807a96f18d3195cf3a1988279 (patch)
tree94a92b439627cf62e00e74214c7bb36a207e2a1a /include/drm
parent2844659842017c981f6e6f74aca3a7ebe10edebb (diff)
downloadlinux-3f4c90bd203125c807a96f18d3195cf3a1988279.tar.xz
drm/i915: add kerneldoc for i915_audio_component
Add the kerneldoc for i915_audio_component in i915_component.h Signed-off-by: Libin Yang <libin.yang@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/i915_component.h65
1 files changed, 38 insertions, 27 deletions
diff --git a/include/drm/i915_component.h b/include/drm/i915_component.h
index 89dc7d6bc1cc..30d89e0da2c6 100644
--- a/include/drm/i915_component.h
+++ b/include/drm/i915_component.h
@@ -30,38 +30,49 @@
*/
#define MAX_PORTS 5
-struct i915_audio_component {
- struct device *dev;
+/**
+ * struct i915_audio_component_ops - callbacks defined in gfx driver
+ * @owner: the module owner
+ * @get_power: get the POWER_DOMAIN_AUDIO power well
+ * @put_power: put the POWER_DOMAIN_AUDIO power well
+ * @codec_wake_override: Enable/Disable generating the codec wake signal
+ * @get_cdclk_freq: get the Core Display Clock in KHz
+ * @sync_audio_rate: set n/cts based on the sample rate
+ */
+struct i915_audio_component_ops {
+ struct module *owner;
+ void (*get_power)(struct device *);
+ void (*put_power)(struct device *);
+ void (*codec_wake_override)(struct device *, bool enable);
+ int (*get_cdclk_freq)(struct device *);
+ int (*sync_audio_rate)(struct device *, int port, int rate);
+};
+
+struct i915_audio_component_audio_ops {
+ void *audio_ptr;
/**
- * @aud_sample_rate: the array of audio sample rate per port
+ * Call from i915 driver, notifying the HDA driver that
+ * pin sense and/or ELD information has changed.
+ * @audio_ptr: HDA driver object
+ * @port: Which port has changed (PORTA / PORTB / PORTC etc)
*/
+ void (*pin_eld_notify)(void *audio_ptr, int port);
+};
+
+/**
+ * struct i915_audio_component - used for audio video interaction
+ * @dev: the device from gfx driver
+ * @aud_sample_rate: the array of audio sample rate per port
+ * @ops: callback for audio driver calling
+ * @audio_ops: Call from i915 driver
+ */
+struct i915_audio_component {
+ struct device *dev;
int aud_sample_rate[MAX_PORTS];
- const struct i915_audio_component_ops {
- struct module *owner;
- void (*get_power)(struct device *);
- void (*put_power)(struct device *);
- void (*codec_wake_override)(struct device *, bool enable);
- int (*get_cdclk_freq)(struct device *);
- /**
- * @sync_audio_rate: set n/cts based on the sample rate
- *
- * Called from audio driver. After audio driver sets the
- * sample rate, it will call this function to set n/cts
- */
- int (*sync_audio_rate)(struct device *, int port, int rate);
- } *ops;
+ const struct i915_audio_component_ops *ops;
- const struct i915_audio_component_audio_ops {
- void *audio_ptr;
- /**
- * Call from i915 driver, notifying the HDA driver that
- * pin sense and/or ELD information has changed.
- * @audio_ptr: HDA driver object
- * @port: Which port has changed (PORTA / PORTB / PORTC etc)
- */
- void (*pin_eld_notify)(void *audio_ptr, int port);
- } *audio_ops;
+ const struct i915_audio_component_audio_ops *audio_ops;
};
#endif /* _I915_COMPONENT_H_ */