drm/amdkfd: enable heavy-weight TLB flush on Vega20
Subsystems (3)
PATCH 1/1 drm/amdkfd: enable heavy-weight TLB flush on Vega20
It is to meet the requirement for memory allocation optimization on MI50.
--- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +2 -1
@@ -1582,7 +1582,8 @@ static int kfd_ioctl_free_memory_of_gpu(struct file *filep,static bool kfd_flush_tlb_after_unmap (struct kfd_dev *dev) {return KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,2 ) || (KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,1 ) && - dev->adev->sdma.instance[0 ].fw_version >=18 ); + dev->adev->sdma.instance[0 ].fw_version >=18 ) || +KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,0 ); } static int kfd_ioctl_map_memory_to_gpu(struct file *filep,
Signature · 1 line
2.25.1
Quoted 5 lines · Eric Huang
It is to meet the requirement for memory allocation optimization on MI50.
Signed-off-by Eric Huang <[email protected]>
Assuming there is no firmware version requirement, the patch is:
Quoted 21 lines
--- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +2
-2@@ -1582,7 +1582,8 @@ static int kfd_ioctl_free_memory_of_gpu(struct file *filep,static bool kfd_flush_tlb_after_unmap (struct kfd_dev *dev) {return KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,2 ) || (KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,1 ) && - dev->adev->sdma.instance[0 ].fw_version >=18 ); + dev->adev->sdma.instance[0 ].fw_version >=18 ) || +KFD_GC_VERSION (dev) ==IP_VERSION (9 ,4 ,0 ); } static int kfd_ioctl_map_memory_to_gpu(struct file *filep, --2.25.1
Chen, Guchun
Acked-by Alex Deucher[Public]
Hi Eric,
Are you sure that there is no FW requirement for this patch on Vega20? KFDMemory test failed by this commit.
Regards,
Guchun
-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, January 25, 2022 4:08 AM
To: Huang, JinHuiEric <[email protected]>
Cc: amd-gfx list <[email protected]>
Subject: Re: [PATCH] drm/amdkfd: enable heavy-weight TLB flush on Vega20
Quoted 5 lines · Eric Huang
It is to meet the requirement for memory allocation optimization on MI50.
Signed-off-by Eric Huang <[email protected]>
Assuming there is no firmware version requirement, the patch is:
Quoted 22 lines
--- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +2
-2@@ -1582,7 +1582,8 @@ static int kfd_ioctl_free_memory_of_gpu(struct file *filep, static bool kfd_flush_tlb_after_unmap(struct kfd_dev *dev) { return KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 2) || (KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 1) && - dev->adev->sdma.instance[0].fw_version >= 18); + dev->adev->sdma.instance[0].fw_version >= 18) || + KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 0); } static int kfd_ioctl_map_memory_to_gpu(struct file *filep, --2.25.1
Hi Guchun,
SDMA FW team confirms MI50/VG20 doesn't have the same bug as MI100, which cases asic hang issue when running RVS test. If this change makes KFDMemoryTest failed, please fill a Jira and assign to me.
Thanks,
Eric
Quoted 46 lines · Guchun
[Public]
Hi Eric,
Are you sure that there is no FW requirement for this patch on Vega20? KFDMemory test failed by this commit.
Regards,
Guchun-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, January 25, 2022 4:08 AM
To: Huang, JinHuiEric <[email protected]>
Cc: amd-gfx list <[email protected]>
Subject: Re: [PATCH] drm/amdkfd: enable heavy-weight TLB flush on Vega20Quoted 4 lines · Eric Huang
It is to meet the requirement for memory allocation optimization on MI50.
Signed-off-by Eric Huang <[email protected]>Assuming there is no firmware version requirement, the patch is:
Acked-by Alex Deucher <[email protected]>Quoted 22 lines
--- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +2
-2@@ -1582,7 +1582,8 @@ static int kfd_ioctl_free_memory_of_gpu(struct file *filep, static bool kfd_flush_tlb_after_unmap(struct kfd_dev *dev) { return KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 2) || (KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 1) && - dev->adev->sdma.instance[0].fw_version >= 18); + dev->adev->sdma.instance[0].fw_version >= 18) || + KFD_GC_VERSION(dev) == IP_VERSION(9, 4, 0); } static int kfd_ioctl_map_memory_to_gpu(struct file *filep, --2.25.1