diff --git a/scst/include/scst.h b/scst/include/scst.h index 61273fecf..78c0d1973 100644 --- a/scst/include/scst.h +++ b/scst/include/scst.h @@ -5043,9 +5043,7 @@ static inline int __scst_get_buf(struct scst_cmd *cmd, int sg_cnt, goto out; } - *buf = page_address(sg_page(sg)); - *buf += sg->offset; - + *buf = sg_virt(sg); res = sg->length; cmd->get_sg_buf_entry_num++;