On Thu, 22 Aug 2013, Daniel Mack wrote:
On 22.08.2013 19:43, Eldad Zack wrote:
On Thu, 22 Aug 2013, Daniel Mack wrote:
On 21.08.2013 23:37, Eldad Zack wrote:
Hi,
This patch series attempts to fix a long starting problem with the concurrent usage of playback and capture on implicit feedback devices.
Applies against current for-next (HEAD b43dd416be21bc8ad60984e13def032f01aaaa18 ).
Thanks a lot for working on this! I'll give that series a test run tonight.
That's great, thanks!
So, with your patches applied, I'm getting the NULL pointer Oops below just by plugging in a UAC2 sound card.
Note that on this system, pulseaudio is running and grabs the new card immediately, then closes it again. That might be different on your machine.
Do you want me to dig deeper or do you have an idea already?
Oh, I think that data_endpoint just doesn't get initialized yet, because it opens and closes immediately.
Does this fix it?
Cheers, Eldad
diff --git a/sound/usb/pcm.c b/sound/usb/pcm.c index 02fb1ea..283e6c0 100644 --- a/sound/usb/pcm.c +++ b/sound/usb/pcm.c @@ -1290,8 +1290,11 @@ static int snd_usb_pcm_close(struct snd_pcm_substream *substream, int direction) subs->interface = -1; }
- subs->data_endpoint->prepare_data_urb = NULL; - subs->data_endpoint->retire_data_urb = NULL; + if (subs->data_endpoint) { + subs->data_endpoint->prepare_data_urb = NULL; + subs->data_endpoint->retire_data_urb = NULL; + } + subs->pcm_substream = NULL; snd_usb_autosuspend(subs->stream->chip);