summaryrefslogtreecommitdiff
path: root/include/sound/compress_driver.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sound/compress_driver.h')
-rw-r--r--include/sound/compress_driver.h11
1 files changed, 4 insertions, 7 deletions
diff --git a/include/sound/compress_driver.h b/include/sound/compress_driver.h
index 175ab3237b58..ae6c3b8ed2f5 100644
--- a/include/sound/compress_driver.h
+++ b/include/sound/compress_driver.h
@@ -48,8 +48,6 @@ struct snd_compr_ops;
* the ring buffer
* @total_bytes_transferred: cumulative bytes transferred by offload DSP
* @sleep: poll sleep
- * @wait: drain wait queue
- * @drain_wake: condition for drain wake
*/
struct snd_compr_runtime {
snd_pcm_state_t state;
@@ -61,8 +59,6 @@ struct snd_compr_runtime {
u64 total_bytes_available;
u64 total_bytes_transferred;
wait_queue_head_t sleep;
- wait_queue_head_t wait;
- unsigned int drain_wake;
void *private_data;
};
@@ -177,10 +173,11 @@ static inline void snd_compr_fragment_elapsed(struct snd_compr_stream *stream)
static inline void snd_compr_drain_notify(struct snd_compr_stream *stream)
{
- snd_BUG_ON(!stream);
+ if (snd_BUG_ON(!stream))
+ return;
- stream->runtime->drain_wake = 1;
- wake_up(&stream->runtime->wait);
+ stream->runtime->state = SNDRV_PCM_STATE_SETUP;
+ wake_up(&stream->runtime->sleep);
}
#endif