Message ID | 1513711816-2618-19-git-send-email-dongwon.kim@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c b/drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c index b61d29a..9b05063 100644 --- a/drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c +++ b/drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c @@ -129,7 +129,7 @@ struct sg_table* hyper_dmabuf_create_sgt(struct page **pages, sg_set_page(sgl, pages[i], PAGE_SIZE, 0); } - if (i > 1) /* more than one page */ { + if (nents > 1) /* more than one page */ { sgl = sg_next(sgl); sg_set_page(sgl, pages[i], last_len, 0); }