projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4e728cf
)
dm-bufio: virt_to_phys() doesn't change remainder modulo PAGE_SIZE
author
Al Viro
<viro@zeniv.linux.org.uk>
Sat, 2 Jan 2016 17:45:27 +0000
(12:45 -0500)
committer
Al Viro
<viro@zeniv.linux.org.uk>
Mon, 4 Jan 2016 15:29:07 +0000
(10:29 -0500)
... so virt_to_phys(p) & (PAGE_SIZE - 1) is a very odd way to
spell offset_in_page(p).
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
drivers/md/dm-bufio.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/md/dm-bufio.c
b/drivers/md/dm-bufio.c
index 2dd33085b331da5bee79392dcf30f7e2c734f70b..adeb8d0f8aad38908af72794c2942a814c297ddd 100644
(file)
--- a/
drivers/md/dm-bufio.c
+++ b/
drivers/md/dm-bufio.c
@@
-630,7
+630,7
@@
static void use_inline_bio(struct dm_buffer *b, int rw, sector_t block,
do {
if (!bio_add_page(&b->bio, virt_to_page(ptr),
len < PAGE_SIZE ? len : PAGE_SIZE,
-
virt_to_phys(ptr) & (PAGE_SIZE - 1
))) {
+
offset_in_page(ptr
))) {
BUG_ON(b->c->block_size <= PAGE_SIZE);
use_dmio(b, rw, block, end_io);
return;