Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 110046
b: refs/heads/master
c: 24e8fc4
h: refs/heads/master
v: v3
  • Loading branch information
Takashi Iwai committed Sep 25, 2008
1 parent 51ba5d3 commit 5d18eea
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 399ccdc1cd4e92e541d4dacbbf18c52bd693418b
refs/heads/master: 24e8fc498e9618338854bfbcf8d1d737e0bf1775
13 changes: 3 additions & 10 deletions trunk/sound/core/pcm_native.c
Original file line number Diff line number Diff line change
Expand Up @@ -1546,16 +1546,10 @@ static int snd_pcm_drop(struct snd_pcm_substream *substream)
card = substream->pcm->card;

if (runtime->status->state == SNDRV_PCM_STATE_OPEN ||
runtime->status->state == SNDRV_PCM_STATE_DISCONNECTED)
runtime->status->state == SNDRV_PCM_STATE_DISCONNECTED ||
runtime->status->state == SNDRV_PCM_STATE_SUSPENDED)
return -EBADFD;

snd_power_lock(card);
if (runtime->status->state == SNDRV_PCM_STATE_SUSPENDED) {
result = snd_power_wait(card, SNDRV_CTL_POWER_D0);
if (result < 0)
goto _unlock;
}

snd_pcm_stream_lock_irq(substream);
/* resume pause */
if (runtime->status->state == SNDRV_PCM_STATE_PAUSED)
Expand All @@ -1564,8 +1558,7 @@ static int snd_pcm_drop(struct snd_pcm_substream *substream)
snd_pcm_stop(substream, SNDRV_PCM_STATE_SETUP);
/* runtime->control->appl_ptr = runtime->status->hw_ptr; */
snd_pcm_stream_unlock_irq(substream);
_unlock:
snd_power_unlock(card);

return result;
}

Expand Down

0 comments on commit 5d18eea

Please sign in to comment.