@@ -429,7 +429,7 @@ static void pvscsi_unmap_buffers(const struct pvscsi_adapter *adapter,
}
if (cmd->sense_buffer)
dma_unmap_single(&adapter->dev->dev, ctx->sensePA,
- SCSI_SENSE_BUFFERSIZE, DMA_FROM_DEVICE);
+ SCSI_SENSE_BUFFERSIZE, DMA_BIDIRECTIONAL);
}
static int pvscsi_allocate_rings(struct pvscsi_adapter *adapter)
@@ -714,7 +714,7 @@ static int pvscsi_queue_ring(struct pvscsi_adapter *adapter,
if (cmd->sense_buffer) {
ctx->sensePA = dma_map_single(&adapter->dev->dev,
cmd->sense_buffer, SCSI_SENSE_BUFFERSIZE,
- DMA_FROM_DEVICE);
+ DMA_BIDIRECTIONAL);
if (dma_mapping_error(&adapter->dev->dev, ctx->sensePA)) {
scmd_printk(KERN_DEBUG, cmd,
"vmw_pvscsi: Failed to map sense buffer for DMA.\n");
@@ -746,7 +746,7 @@ static int pvscsi_queue_ring(struct pvscsi_adapter *adapter,
if (cmd->sense_buffer) {
dma_unmap_single(&adapter->dev->dev, ctx->sensePA,
SCSI_SENSE_BUFFERSIZE,
- DMA_FROM_DEVICE);
+ DMA_BIDIRECTIONAL);
ctx->sensePA = 0;
}
return -ENOMEM;