projects
/
GitHub
/
LineageOS
/
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:
d5ff506
)
xen/scsifront: use offset_in_page() macro
author
Geliang Tang
<geliangtang@gmail.com>
Sat, 22 Apr 2017 01:21:13 +0000
(09:21 +0800)
committer
Juergen Gross
<jgross@suse.com>
Tue, 2 May 2017 09:14:53 +0000
(11:14 +0200)
Use offset_in_page() macro instead of open-coding.
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Juergen Gross <jgross@suse.com>
drivers/scsi/xen-scsifront.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/scsi/xen-scsifront.c
b/drivers/scsi/xen-scsifront.c
index 9aa1fe1fc93967109256690be004d31fa04b52e7..a6a8b60d4902ab018442ab41acb99a9369c63146 100644
(file)
--- a/
drivers/scsi/xen-scsifront.c
+++ b/
drivers/scsi/xen-scsifront.c
@@
-434,7
+434,7
@@
static int map_data_for_request(struct vscsifrnt_info *info,
if (seg_grants) {
page = virt_to_page(seg);
- off =
(unsigned long)seg & ~PAGE_MASK
;
+ off =
offset_in_page(seg)
;
len = sizeof(struct scsiif_request_segment) * data_grants;
while (len > 0) {
bytes = min_t(unsigned int, len, PAGE_SIZE - off);