diff options
-rw-r--r-- | zttranscode.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/zttranscode.c b/zttranscode.c index 600ec58..334304b 100644 --- a/zttranscode.c +++ b/zttranscode.c @@ -375,7 +375,11 @@ static int zt_tc_mmap(struct file *file, struct vm_area_struct *vma) #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,10) res = remap_pfn_range(vma, vma->vm_start, physical >> PAGE_SHIFT, sizeof(struct zt_transcode_header), PAGE_SHARED); #else + #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0) + res = remap_page_range(vma->vm_start, physical, sizeof(struct zt_transcode_header), PAGE_SHARED); + #else res = remap_page_range(vma, vma->vm_start, physical, sizeof(struct zt_transcode_header), PAGE_SHARED); + #endif #endif if (res) { if (debug) |