Merge remote-tracking branches 'asoc/topic/fsl-spdif', 'asoc/topic/hdmi', 'asoc/topic...
[linux-2.6-block.git] / include / sound / compress_driver.h
index c0abcdc1147083f9faa8a036357a5468429ff00a..cee8c00f3d3e6f69c4c899f2f24bbbf6fbb30c13 100644 (file)
@@ -68,6 +68,7 @@ struct snd_compr_runtime {
  * @ops: pointer to DSP callbacks
  * @runtime: pointer to runtime structure
  * @device: device pointer
+ * @error_work: delayed work used when closing the stream due to an error
  * @direction: stream direction, playback/recording
  * @metadata_set: metadata set flag, true when set
  * @next_track: has userspace signal next track transition, true when set
@@ -78,6 +79,7 @@ struct snd_compr_stream {
        struct snd_compr_ops *ops;
        struct snd_compr_runtime *runtime;
        struct snd_compr *device;
+       struct delayed_work error_work;
        enum snd_compr_direction direction;
        bool metadata_set;
        bool next_track;
@@ -187,4 +189,7 @@ static inline void snd_compr_drain_notify(struct snd_compr_stream *stream)
        wake_up(&stream->runtime->sleep);
 }
 
+int snd_compr_stop_error(struct snd_compr_stream *stream,
+                        snd_pcm_state_t state);
+
 #endif