]> git.baikalelectronics.ru Git - kernel.git/commit
drm/vmwgfx: Use the dma scatter-gather iterator to get dma addresses
authorThomas Hellstrom <thellstrom@vmware.com>
Wed, 15 May 2019 15:45:23 +0000 (17:45 +0200)
committerThomas Hellstrom <thellstrom@vmware.com>
Tue, 21 May 2019 08:23:09 +0000 (10:23 +0200)
commitd43b1b9fec0ba2ba9549cc3971adc6313b4af7d2
treee342423dd9ed3fbdb2536326779de59af12123f9
parent9f3e0c1bb8acd55a0a7f71015b228e822fbbaa6b
drm/vmwgfx: Use the dma scatter-gather iterator to get dma addresses

Use struct sg_dma_page_iter in favour struct of sg_page_iter, which fairly
recently was declared useless for obtaining dma addresses.

With a struct sg_dma_page_iter we can't call sg_page_iter_page() so
when the page is needed, use the same page lookup mechanism as for the
non-sg dma modes instead of calling sg_dma_page_iter.

Note, the fixes tag doesn't really point to a commit introducing a
failure / regression, but rather to a commit that implemented a simple
workaround for this problem.

Cc: Jason Gunthorpe <jgg@mellanox.com>
Fixes: df7a5f73e9ce ("lib/scatterlist: Provide a DMA page iterator")
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/gpu/drm/vmwgfx/vmwgfx_drv.h
drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c