Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/amdgpu: reserved buffer is not needed with ip discovery enabled

When IP discovery enabled, the reserved buffer has been alloacted.

Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Aaron Liu and committed by
Alex Deucher
bea75349 e15a5fb9

+7 -4
+7 -4
drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
··· 790 790 { 791 791 /* Some ASICs need to reserve a region of video memory to avoid access 792 792 * from driver */ 793 + adev->mman.stolen_reserved_offset = 0; 794 + adev->mman.stolen_reserved_size = 0; 795 + 793 796 switch (adev->asic_type) { 794 797 case CHIP_YELLOW_CARP: 795 - adev->mman.stolen_reserved_offset = 0x1ffb0000; 796 - adev->mman.stolen_reserved_size = 64 * PAGE_SIZE; 798 + if (amdgpu_discovery == 0) { 799 + adev->mman.stolen_reserved_offset = 0x1ffb0000; 800 + adev->mman.stolen_reserved_size = 64 * PAGE_SIZE; 801 + } 797 802 break; 798 803 default: 799 - adev->mman.stolen_reserved_offset = 0; 800 - adev->mman.stolen_reserved_size = 0; 801 804 break; 802 805 } 803 806 }