This patch fixes a NULL pointer exception which occurs when a
substream is opened and immediately closed.
Signed-off-by: Frank Mandarino <fmandarino@endrelia.com>
Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
ssc_p->dir_mask |= dir_mask;
spin_unlock_irq(&ssc_p->lock);
+ /*
+ * dma_data is not set until hw_params() is called and
+ * shutdown() depends on this value being NULL if hw_params()
+ * was not called.
+ */
+ rtd->cpu_dai->dma_data = NULL;
+
return 0;
}