From eb646fbed25df3b6714e83e48a0694af62c7e18d Mon Sep 17 00:00:00 2001 From: kpfleming Date: Wed, 12 Jul 2006 12:58:40 +0000 Subject: and now... use the old mmap API properly (oops) git-svn-id: http://svn.digium.com/svn/zaptel/trunk@1220 5390a7c7-147a-4af0-8ec9-7488f05a26cb --- zttranscode.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'zttranscode.c') diff --git a/zttranscode.c b/zttranscode.c index 207b561..aa6bd3a 100644 --- a/zttranscode.c +++ b/zttranscode.c @@ -371,9 +371,9 @@ static int zt_tc_mmap(struct file *file, struct vm_area_struct *vma) physical = (unsigned long) virt_to_phys(ztc->tch); #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,10) - res = remap_pfn_range(vma, vma->vm_start, physical, sizeof(struct zt_transcode_header), PAGE_SHARED); + res = remap_pfn_range(vma, vma->vm_start, physical >> PAGE_SHIFT, sizeof(struct zt_transcode_header), PAGE_SHARED); #else - res = remap_page_range(vma, vma->vm_start, physical >> PAGE_SHIFT, sizeof(struct zt_transcode_header), PAGE_SHARED); + res = remap_page_range(vma, vma->vm_start, physical, sizeof(struct zt_transcode_header), PAGE_SHARED); #endif if (res) { if (debug) -- cgit v1.2.3