drm/ttm: fix misplaced parentheses

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dave Airlie <airlied@linux.ie>
This commit is contained in:
Roel Kluin
2009-07-15 16:00:37 +10:00
committed by Dave Airlie
parent 42dd861994
commit 916635bfca

View File

@@ -327,7 +327,7 @@ ssize_t ttm_bo_io(struct ttm_bo_device *bdev, struct file *filp,
goto out_unref; goto out_unref;
kmap_offset = dev_offset - bo->vm_node->start; kmap_offset = dev_offset - bo->vm_node->start;
if (unlikely(kmap_offset) >= bo->num_pages) { if (unlikely(kmap_offset >= bo->num_pages)) {
ret = -EFBIG; ret = -EFBIG;
goto out_unref; goto out_unref;
} }
@@ -401,7 +401,7 @@ ssize_t ttm_bo_fbdev_io(struct ttm_buffer_object *bo, const char __user *wbuf,
bool dummy; bool dummy;
kmap_offset = (*f_pos >> PAGE_SHIFT); kmap_offset = (*f_pos >> PAGE_SHIFT);
if (unlikely(kmap_offset) >= bo->num_pages) if (unlikely(kmap_offset >= bo->num_pages))
return -EFBIG; return -EFBIG;
page_offset = *f_pos & ~PAGE_MASK; page_offset = *f_pos & ~PAGE_MASK;