/* close a DMA channel and its associated interrupt  */
void frv_dma_close(int dma)
/* close a DMA channel and its associated interrupt  */
void frv_dma_close(int dma)
{
	struct frv_dma_channel *channel = &frv_dma_channels[dma];
	unsigned long flags;
	write_lock_irqsave(&frv_dma_channels_lock, flags);
	free_irq(channel->irq, channel);
	frv_dma_stop(dma);
	channel->flags &= ~FRV_DMA_FLAGS_INUSE;
	write_unlock_irqrestore(&frv_dma_channels_lock, flags);
}