summaryrefslogtreecommitdiffstats
path: root/sound/firewire/fireface
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2018-10-10 02:34:59 -0400
committerTakashi Iwai <tiwai@suse.de>2018-10-10 06:11:34 -0400
commit61ccc6f6b27c03bb32ca38a3c580d49ce1612d43 (patch)
tree7db489b32d390c7627693eec90e3488d7c3a21ec /sound/firewire/fireface
parentd06fb562bff5d14defdacbd92449bacbaedd5cdf (diff)
ALSA: firewire: block .remove callback of bus driver till all of ALSA character devices are released
At present, in .remove callback of bus driver just decrease reference count of device for ALSA card instance. This delegates release of the device to a process in which the last of ALSA character device is released. On the other hand, the other drivers such as for devices on PCIe are programmed to block .remove callback of bus driver till all of ALSA character devices are released. For consistency of behaviour for whole drivers, this probably confuses users. This commit takes drivers in ALSA firewire stack to imitate the above behaviour. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/fireface')
-rw-r--r--sound/firewire/fireface/ff.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/firewire/fireface/ff.c b/sound/firewire/fireface/ff.c
index 98731bd8816f..73425dfe63bf 100644
--- a/sound/firewire/fireface/ff.c
+++ b/sound/firewire/fireface/ff.c
@@ -145,8 +145,8 @@ static void snd_ff_remove(struct fw_unit *unit)
145 cancel_work_sync(&ff->dwork.work); 145 cancel_work_sync(&ff->dwork.work);
146 146
147 if (ff->registered) { 147 if (ff->registered) {
148 /* No need to wait for releasing card object in this context. */ 148 // Block till all of ALSA character devices are released.
149 snd_card_free_when_closed(ff->card); 149 snd_card_free(ff->card);
150 } else { 150 } else {
151 /* Don't forget this case. */ 151 /* Don't forget this case. */
152 ff_free(ff); 152 ff_free(ff);