diff options
Diffstat (limited to 'drivers/misc/mic/host/mic_boot.c')
-rw-r--r-- | drivers/misc/mic/host/mic_boot.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/misc/mic/host/mic_boot.c b/drivers/misc/mic/host/mic_boot.c index 4f2d9212432c..448ddea450dc 100644 --- a/drivers/misc/mic/host/mic_boot.c +++ b/drivers/misc/mic/host/mic_boot.c @@ -88,6 +88,14 @@ static void *__mic_get_dp(struct vop_device *vpdev) return mdev->dp; } +static int __mic_dp_mmap(struct vop_device *vpdev, struct vm_area_struct *vma) +{ + struct mic_device *mdev = vpdev_to_mdev(&vpdev->dev); + + return dma_mmap_coherent(&mdev->pdev->dev, vma, mdev->dp, + mdev->dp_dma_addr, MIC_DP_SIZE); +} + static void __iomem *__mic_get_remote_dp(struct vop_device *vpdev) { return NULL; @@ -119,6 +127,7 @@ static struct vop_hw_ops vop_hw_ops = { .ack_interrupt = __mic_ack_interrupt, .next_db = __mic_next_db, .get_dp = __mic_get_dp, + .dp_mmap = __mic_dp_mmap, .get_remote_dp = __mic_get_remote_dp, .send_intr = __mic_send_intr, .remap = __mic_ioremap, |