diff options
author | sos <sos@FreeBSD.org> | 2007-04-08 15:31:39 +0000 |
---|---|---|
committer | sos <sos@FreeBSD.org> | 2007-04-08 15:31:39 +0000 |
commit | e8b0a99e5702ea2b9dcb24a67d39b2d250ca0c95 (patch) | |
tree | 511b9399806896e922ed1f10478f41ea6bd269c1 /sys/dev | |
parent | bc44c7c360c549b7a9e9594e98704011290a0c1b (diff) | |
download | FreeBSD-src-e8b0a99e5702ea2b9dcb24a67d39b2d250ca0c95.zip FreeBSD-src-e8b0a99e5702ea2b9dcb24a67d39b2d250ca0c95.tar.gz |
Dont zero out 64BIT flag on DMA ops.
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/ata/ata-dma.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/ata/ata-dma.c b/sys/dev/ata/ata-dma.c index fbe23f0..4627856 100644 --- a/sys/dev/ata/ata-dma.c +++ b/sys/dev/ata/ata-dma.c @@ -259,7 +259,8 @@ ata_dmaload(device_t dev, caddr_t data, int32_t count, int dir, dir ? BUS_DMASYNC_PREREAD : BUS_DMASYNC_PREWRITE); ch->dma->cur_iosize = count; - ch->dma->flags = dir ? (ATA_DMA_LOADED | ATA_DMA_READ) : ATA_DMA_LOADED; + ch->dma->flags &= ATA_DMA_READ; + ch->dma->flags |= dir ? (ATA_DMA_LOADED | ATA_DMA_READ) : ATA_DMA_LOADED; return 0; } @@ -273,7 +274,7 @@ ata_dmaunload(device_t dev) BUS_DMASYNC_POSTWRITE); bus_dmamap_sync(ch->dma->data_tag, ch->dma->data_map, - (ch->dma->flags & ATA_DMA_READ) != 0 ? + (ch->dma->flags & ATA_DMA_READ) ? BUS_DMASYNC_POSTREAD : BUS_DMASYNC_POSTWRITE); bus_dmamap_unload(ch->dma->data_tag, ch->dma->data_map); |