mirror of https://github.com/thesofproject/sof.git
lib: dma: make dma stop op optional
In preparation for adding a reset op that could be used in place of the stop op for DAI's that support the two-step stop option. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
This commit is contained in:
parent
6b420fd538
commit
aa2cf1fc94
|
@ -311,7 +311,10 @@ static inline int dma_start(struct dma_chan_data *channel)
|
|||
|
||||
static inline int dma_stop(struct dma_chan_data *channel)
|
||||
{
|
||||
return channel->dma->ops->stop(channel);
|
||||
if (channel->dma->ops->stop)
|
||||
return channel->dma->ops->stop(channel);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/** \defgroup sof_dma_copy_func static int dma_copy (struct dma_chan_data * channel, int bytes, uint32_t flags)
|
||||
|
|
Loading…
Reference in New Issue