Skip to content

Commit

Permalink
ALSA: oxfw: fix regression to handle Stanton SCS.1m/1d
Browse files Browse the repository at this point in the history
At a commit 6c29230 ("ALSA: oxfw: delayed registration of sound
card"), ALSA oxfw driver fails to handle SCS.1m/1d, due to -EBUSY at a call
of snd_card_register(). The cause is that the driver manages to register
two rawmidi instances with the same device number 0. This is a regression
introduced since kernel 4.7.

This commit fixes the regression, by fixing up device property after
discovering stream formats.

Fixes: 6c29230 ("ALSA: oxfw: delayed registration of sound card")
Cc: <stable@vger.kernel.org> # 4.7+
Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
takaswie authored and tiwai committed Apr 5, 2017
1 parent 2f726ae commit 3d016d5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sound/firewire/oxfw/oxfw.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,11 +227,11 @@ static void do_registration(struct work_struct *work)
if (err < 0)
goto error;

err = detect_quirks(oxfw);
err = snd_oxfw_stream_discover(oxfw);
if (err < 0)
goto error;

err = snd_oxfw_stream_discover(oxfw);
err = detect_quirks(oxfw);
if (err < 0)
goto error;

Expand Down

0 comments on commit 3d016d5

Please sign in to comment.