snd_pcm_dmix_close: raise semaphore if unable to discard
snd_pcm_dmix_close: raise semaphore if unable to discard

This patch causes snd_pcm_dmix_close() to up a semaphore after downing it
if it is unable to discard it.  It prevents some deadlock that I am
getting when a couple of applications interact and one of them closes the
device and later re-opens it.

From: Mike Gorse <9ae0365466ffcdd4e15fdaa229f316e455ece278@mgorse.dhs.org>

mengdonglin/alsa-lib,takaswie/alsa-lib,mengdonglin/alsa-lib,zedongchen/alsa-lib,takaswie/alsa-lib,takaswie/alsa-lib,Distrotech/alsa-lib,zedongchen/alsa-lib,lgirdwood/alsa-lib,mikelima/alsa-lib,zedongchen/alsa-lib,tiwai/alsa-lib,mikelima/alsa-lib,alsa-project/alsa-lib,Distrotech/alsa-lib,lgirdwood/alsa-lib,mengdonglin/alsa-lib,lgirdwood/alsa-lib,gittup/alsa-lib,alsa-project/alsa-lib,mikelima/alsa-lib,alsa-project/alsa-lib,mikelima/alsa-lib,lgirdwood/alsa-lib,lgirdwood/alsa-lib,takaswie/alsa-lib,mikelima/alsa-lib,gittup/alsa-lib,mengdonglin/alsa-lib,tiwai/alsa-lib,takaswie/alsa-lib,gittup/alsa-lib,Distrotech/alsa-lib,tiwai/alsa-lib,Distrotech/alsa-lib,alsa-project/alsa-lib,tiwai/alsa-lib,Distrotech/alsa-lib,mengdonglin/alsa-lib,gittup/alsa-lib,zedongchen/alsa-lib,zedongchen/alsa-lib