Message ID | 20240624160918.27060-2-mrgolin@amazon.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Jason Gunthorpe |
Headers | show |
Series | RDMA/efa: Cleanups and minor improvements | expand |
On 24/06/2024 19:09, Michael Margolin wrote: > From: Gal Pressman <galpress@amazon.com> > > Use offset_in_page() instead of open-coding it. > > Reviewed-by: Yossi Leybovich <sleybo@amazon.com> > Reviewed-by: Firas Jahjah <firasj@amazon.com> > Signed-off-by: Gal Pressman <galpress@amazon.com> > Signed-off-by: Michael Margolin <mrgolin@amazon.com> Looks good Gal!
diff --git a/drivers/infiniband/hw/efa/efa_verbs.c b/drivers/infiniband/hw/efa/efa_verbs.c index 8f7a13b79cdc..eee2ae215414 100644 --- a/drivers/infiniband/hw/efa/efa_verbs.c +++ b/drivers/infiniband/hw/efa/efa_verbs.c @@ -524,7 +524,7 @@ static int qp_mmap_entries_setup(struct efa_qp *qp, address = dev->mem_bar_addr + resp->llq_desc_offset; length = PAGE_ALIGN(params->sq_ring_size_in_bytes + - (resp->llq_desc_offset & ~PAGE_MASK)); + offset_in_page(resp->llq_desc_offset)); qp->llq_desc_mmap_entry = efa_user_mmap_entry_insert(&ucontext->ibucontext,