Skip to contentSkip to conversation

Set vm_update_mode=0 as default for Sienna Cichlid in SRIOV case

PATCH Superseded Danijel Slivka 2 participants 2 messages Oct 4, 2022

Subsystems (2)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Set vm_update_mode=0 as default for Sienna Cichlid in SRIOV case

CPU pagetable updates have issues with HDP flush as VF MMIO access protection is not allowing write during sriov runtime to mmBIF_BX_DEV0_EPF0_VF0_HDP_MEM_COHERENCY_FLUSH_CNTL

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +3 -1
index 83b0c5d86e48..32088ac0666c 100644
@@ -2338,7 +2338,9 @@ void amdgpu_vm_manager_init(struct amdgpu_device *adev)
 	 */
 #ifdef CONFIG_X86_64
 	if (amdgpu_vm_update_mode == -1) {
-		if (amdgpu_gmc_vram_full_visible(&adev->gmc))
+		if (amdgpu_gmc_vram_full_visible(&adev->gmc) &&
+		    !(adev->asic_type == CHIP_SIENNA_CICHLID &&
+		    amdgpu_sriov_vf(adev)))
 			adev->vm_manager.vm_update_mode =
 				AMDGPU_VM_USE_CPU_FOR_COMPUTE;
 		else
Signature · 1 line
2.25.1
#1 lore raw

Am 04.10.22 um 16:08 schrieb Danijel Slivka:

Quoted 3 lines

CPU pagetable updates have issues with HDP flush as VF MMIO access protection is not allowing write during sriov runtime to mmBIF_BX_DEV0_EPF0_VF0_HDP_MEM_COHERENCY_FLUSH_CNTL

The subject should have a drm/amdgpu prefix and in general Felix need to take a look at this.

Regards,
Christian.

Quoted 21 lines
---
  drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 4 +++-
  1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +3 -1
index 83b0c5d86e48..32088ac0666c 100644
@@ -2338,7 +2338,9 @@ void amdgpu_vm_manager_init(struct amdgpu_device *adev)
  	 */
  #ifdef CONFIG_X86_64
  	if (amdgpu_vm_update_mode == -1) {
-		if (amdgpu_gmc_vram_full_visible(&adev->gmc))
+		if (amdgpu_gmc_vram_full_visible(&adev->gmc) &&
+		    !(adev->asic_type == CHIP_SIENNA_CICHLID &&
+		    amdgpu_sriov_vf(adev)))
  			adev->vm_manager.vm_update_mode =
  				AMDGPU_VM_USE_CPU_FOR_COMPUTE;
  		else