gpu: nvgpu: Move and rename gk20a_sgtable*

Move and rename the functions that build sgtables for nvgpu_mems into
the Linux specific DMA code.

One place outside of the Linux code do include the Linux DMA header.
That will be fixed in a subsequent patch.

JIRA NVGPU-12
JIRA NVGPU-30

Change-Id: Ie43c752b8f998f122af70f7c7eb727af0b0d98df
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: http://git-master/r/1464078
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Alex Waterman
2017-04-10 13:51:43 -07:00
committed by mobile promotions
parent 6a14d980cf
commit 126c735d30
7 changed files with 120 additions and 90 deletions

View File

@@ -51,6 +51,8 @@
#include <nvgpu/kmem.h>
#include <nvgpu/bug.h>
#include <nvgpu/linux/dma.h>
#include "gk20a/gk20a.h"
#include "gk20a/hal_gk20a.h"
#include "gk20a/platform_gk20a.h"
@@ -143,7 +145,7 @@ static void gk20a_tegra_secure_destroy(struct gk20a *g,
dma_free_attrs(&tegra_vpr_dev, desc->mem.size,
(void *)(uintptr_t)pa,
pa, __DMA_ATTR(attrs));
gk20a_free_sgtable(g, &desc->mem.priv.sgt);
nvgpu_free_sgtable(g, &desc->mem.priv.sgt);
desc->mem.priv.sgt = NULL;
}
}