mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-23 09:57:08 +03:00
gpu: nvgpu: Use bootstrap base for WPR address
Use the bootstrap base address for calculating the address of WPR. The bootstrap base is dynamic and depends on amount of memory, so we should not hard code any address. Bug 200244445 Change-Id: Ia700d24c8d572a25946f7b1847faec72c40c6796 Signed-off-by: David Martinez Nieto <dmartineznie@nvidia.com> Reviewed-on: http://git-master/r/1242252 Reviewed-by: David Martinez Nieto <dmartineznie@nvidia.com> Reviewed-by: Alex Waterman <alexw@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-on: http://git-master/r/1267125 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
This commit is contained in:
committed by
Deepak Nibade
parent
206a5c2d39
commit
bfc12d25a4
@@ -40,7 +40,7 @@ typedef int (*get_ucode_details)(struct gk20a *g,
|
||||
/* Both size and address of WPR need to be 128K-aligned */
|
||||
#define WPR_ALIGNMENT 0x20000
|
||||
#define GP106_DGPU_NONWPR NVGPU_VIDMEM_BOOTSTRAP_ALLOCATOR_BASE
|
||||
#define GP106_DGPU_WPR (GP106_DGPU_NONWPR + 0x400000)
|
||||
#define GP106_DGPU_WPR_OFFSET 0x400000
|
||||
#define DGPU_WPR_SIZE 0x100000
|
||||
|
||||
/*Externs*/
|
||||
@@ -79,8 +79,8 @@ static get_ucode_details pmu_acr_supp_ucode_list[] = {
|
||||
|
||||
static void gp106_wpr_info(struct gk20a *g, struct wpr_carveout_info *inf)
|
||||
{
|
||||
inf->wpr_base = GP106_DGPU_WPR;
|
||||
inf->nonwpr_base = GP106_DGPU_NONWPR;
|
||||
inf->nonwpr_base = g->mm.vidmem.bootstrap_base;
|
||||
inf->wpr_base = inf->nonwpr_base + GP106_DGPU_WPR_OFFSET;
|
||||
inf->size = DGPU_WPR_SIZE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user