On Fri, Apr 14, 2023 at 3:58 PM Jason Gunthorpe <jgg@xxxxxxxxxx> wrote: > Make it clearer what is going on by adding a function to go back from the > "virtual" dma_addr to a kva and another to a struct page. This is used in the > ib_uses_virt_dma() style drivers (siw, rxe, hfi, qib). > > Call them instead of a naked casting and virt_to_page() when working with dma_addr > values encoded by the various ib_map functions. > > This also fixes the virt_to_page() casting problem Linus Walleij has been > chasing. > > Cc: Linus Walleij <linus.walleij@xxxxxxxxxx> > Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxx> Too late but FWIW: Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx> Thanks for fixing this up so meticulously Jason! Yours, Linus Walleij