Skip to content

Commit 6a37539

Browse files
YiPeng Chaialexdeucher
authored andcommitted
drm/amdgpu: Fix the issue of missing ras message on sriov host
This code only applies to amdgpu processing poison consumption after uniras is enabled, but not to sriov. Signed-off-by: YiPeng Chai <YiPeng.Chai@amd.com> Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 2b198d4 commit 6a37539

2 files changed

Lines changed: 10 additions & 15 deletions

File tree

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

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@
3636
#include "amdgpu_ras.h"
3737
#include "amdgpu_umc.h"
3838
#include "amdgpu_reset.h"
39-
#include "amdgpu_ras_mgr.h"
4039

4140
/* Total memory size in system memory and all GPU VRAM. Used to
4241
* estimate worst case amount of memory to reserve for page tables
@@ -747,20 +746,6 @@ void amdgpu_amdkfd_ras_pasid_poison_consumption_handler(struct amdgpu_device *ad
747746
enum amdgpu_ras_block block, uint16_t pasid,
748747
pasid_notify pasid_fn, void *data, uint32_t reset)
749748
{
750-
751-
if (amdgpu_uniras_enabled(adev)) {
752-
struct ras_ih_info ih_info;
753-
754-
memset(&ih_info, 0, sizeof(ih_info));
755-
ih_info.block = block;
756-
ih_info.pasid = pasid;
757-
ih_info.reset = reset;
758-
ih_info.pasid_fn = pasid_fn;
759-
ih_info.data = data;
760-
amdgpu_ras_mgr_handle_consumer_interrupt(adev, &ih_info);
761-
return;
762-
}
763-
764749
amdgpu_umc_pasid_poison_handler(adev, block, pasid, pasid_fn, data, reset);
765750
}
766751

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

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
#include <linux/sort.h>
2525
#include "amdgpu.h"
2626
#include "umc_v6_7.h"
27+
#include "amdgpu_ras_mgr.h"
2728
#define MAX_UMC_POISON_POLLING_TIME_SYNC 20 //ms
2829

2930
#define MAX_UMC_HASH_STRING_SIZE 256
@@ -273,6 +274,15 @@ int amdgpu_umc_pasid_poison_handler(struct amdgpu_device *adev,
273274
}
274275

275276
amdgpu_ras_error_data_fini(&err_data);
277+
} else if (amdgpu_uniras_enabled(adev)) {
278+
struct ras_ih_info ih_info = {0};
279+
280+
ih_info.block = block;
281+
ih_info.pasid = pasid;
282+
ih_info.reset = reset;
283+
ih_info.pasid_fn = pasid_fn;
284+
ih_info.data = data;
285+
amdgpu_ras_mgr_handle_consumer_interrupt(adev, &ih_info);
276286
} else {
277287
struct amdgpu_ras *con = amdgpu_ras_get_context(adev);
278288
int ret;

0 commit comments

Comments
 (0)