projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1a695a9
)
HSI: cmt_speech: use vma_pages().
author
Muhammad Falak R Wani
<falakreyaz@gmail.com>
Sat, 21 May 2016 13:19:21 +0000
(18:49 +0530)
committer
Sebastian Reichel
<sre@kernel.org>
Sun, 29 May 2016 18:37:45 +0000
(20:37 +0200)
Replace explicit computation of vma page count by a call to
vma_pages()
Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com>
Signed-off-by: Sebastian Reichel <sre@kernel.org>
drivers/hsi/clients/cmt_speech.c
patch
|
blob
|
history
diff --git
a/drivers/hsi/clients/cmt_speech.c
b/drivers/hsi/clients/cmt_speech.c
index
95638df
..
b16cfa4
100644
(file)
--- a/
drivers/hsi/clients/cmt_speech.c
+++ b/
drivers/hsi/clients/cmt_speech.c
@@
-1275,7
+1275,7
@@
static int cs_char_mmap(struct file *file, struct vm_area_struct *vma)
if (vma->vm_end < vma->vm_start)
return -EINVAL;
- if (
((vma->vm_end - vma->vm_start) >> PAGE_SHIFT
) != 1)
+ if (
vma_pages(vma
) != 1)
return -EINVAL;
vma->vm_flags |= VM_IO | VM_DONTDUMP | VM_DONTEXPAND;