Skip to content

Commit e90230e

Browse files
committed
amdgpu: use BAR not register to locate carved-out RAM, in vram_gtt_location too
1 parent a0a78b3 commit e90230e

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1327,12 +1327,16 @@ static void gmc_v9_0_vram_gtt_location(struct amdgpu_device *adev,
13271327
amdgpu_gmc_gart_location(adev, mc);
13281328
amdgpu_gmc_agp_location(adev, mc);
13291329
}
1330+
#if 0
13301331
/* base offset of vram pages */
13311332
adev->vm_manager.vram_base_offset = adev->gfxhub.funcs->get_mc_fb_offset(adev);
13321333

13331334
/* XXX: add the xgmi offset of the physical node? */
13341335
adev->vm_manager.vram_base_offset +=
13351336
adev->gmc.xgmi.physical_node_id * adev->gmc.xgmi.node_segment_size;
1337+
#else
1338+
adev->vm_manager.vram_base_offset = pci_resource_start(adev->pdev, 0);
1339+
#endif
13361340
}
13371341

13381342
/**

0 commit comments

Comments
 (0)