Page MenuHomeFreeBSD

D61755.1795244599.diff
No OneTemporary

Authored By
Unknown
Size
770 B
Referenced Files
None
Subscribers
None

D61755.1795244599.diff

diff --git a/sys/dev/xen/gntdev/gntdev.c b/sys/dev/xen/gntdev/gntdev.c
--- a/sys/dev/xen/gntdev/gntdev.c
+++ b/sys/dev/xen/gntdev/gntdev.c
@@ -750,7 +750,7 @@
gmap = mem->handle;
if (gmap == NULL ||
- (entry->end - entry->start) != (gmap->count * PAGE_SIZE)) {
+ OFF_TO_IDX(entry->end - entry->start) != gmap->count) {
rc = EINVAL;
goto out;
}
@@ -906,7 +906,7 @@
mtx_lock(&priv_user->user_data_lock);
RB_FOREACH(gmap, gmap_tree_head, &priv_user->gmap_tree) {
if (arg->index >= gmap->file_index &&
- arg->index < gmap->file_index + gmap->count * PAGE_SIZE) {
+ OFF_TO_IDX(arg->index - gmap->file_index) < gmap->count) {
if (gmap->notify == NULL)
gmap->notify = malloc(sizeof(*arg), M_GNTDEV,
M_WAITOK | M_ZERO);

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 21, 7:03 AM (48 m, 58 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41870360
Default Alt Text
D61755.1795244599.diff (770 B)

Event Timeline