/* Teardown mappings after DMA has completed. This must be called after the completion of each use of ide_build_dmatable and before the next use of ide_build_dmatable. Failure to do so will cause an oops as only one mapping can be live for each target at a given time.  */
void ide_dma_unmap_sg(ide_drive_t *drive, struct ide_cmd *cmd)
/* Teardown mappings after DMA has completed. This must be called after the completion of each use of ide_build_dmatable and before the next use of ide_build_dmatable. Failure to do so will cause an oops as only one mapping can be live for each target at a given time.  */
void ide_dma_unmap_sg(ide_drive_t *drive, struct ide_cmd *cmd)
{
	ide_hwif_t *hwif = drive->hwif;
	dma_unmap_sg(hwif->dev, hwif->sg_table, cmd->orig_sg_nents,
		     cmd->sg_dma_direction);
}