drm/amdgpu: pass xcc mask to ras ta
Subsystems (2)
PATCH v2 1/3 drm/amdgpu: pass xcc mask to ras ta
pass xcc mask to ras ta, ras ta will compare
the mask with the one from chiplet topology.
Changed from V1:
Remove IP version checking.
Set ras_cmd->ras_init_message.init_flags.xcc_mask directly due to xcc_mask is common structres to all the devices.
Signed-off-by Stanley.Yang <[email protected]>
Reviewed-by Tao Zhou <[email protected]>
Reviewed-by Hawking Zhang <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 2 ++ drivers/gpu/drm/amd/amdgpu/ta_ras_if.h | 1 + 2 files changed, 3 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +2 -0
@@ -1662,6 +1662,8 @@ int psp_ras_initialize(struct psp_context *psp) ras_cmd->ras_in_message.init_flags.poison_mode_en =1 ;if (!adev->gmc.xgmi.connected_to_cpu) ras_cmd->ras_in_message.init_flags.dgpu_mode =1 ; + ras_cmd->ras_in_message.init_flags.xcc_mask = + adev->gfx.xcc_mask; ret =psp_ta_load (psp, &psp->ras_context.context);
drivers/gpu/drm/amd/amdgpu/ta_ras_if.h +1 -0
@@ -129,6 +129,7 @@ struct ta_ras_trigger_error_input {struct ta_ras_init_flags {uint8_t poison_mode_en;uint8_t dgpu_mode; +uint16_t xcc_mask; };struct ta_ras_output_flags {
Signature · 1 line
2.17.1
PATCH v2 2/3 drm/amdgpu: support check vcn jpeg block mask
Support VCN/JPEG instance mask checking, pass logical mask directly except GFX/SDMA/VCN/JPEG blocks.
Changed from V1:
correct a typo
Signed-off-by Stanley.Yang <[email protected]>
Reviewed-by Tao Zhou <[email protected]>
Reviewed-by Hawking Zhang <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +5 -1
@@ -360,8 +360,12 @@ static void amdgpu_ras_instance_mask_check(struct amdgpu_device *adev,case AMDGPU_RAS_BLOCK__SDMA : mask =GENMASK (adev->sdma.num_instances -1 ,0 );break ; +case AMDGPU_RAS_BLOCK__VCN : +case AMDGPU_RAS_BLOCK__JPEG : + mask =GENMASK (adev->vcn.num_vcn_inst -1 ,0 ); +break ;default : - mask =0 ; + mask = inst_mask;break ; }
Signature · 1 line
2.17.1
PATCH v2 3/3 drm/amdgpu: convert vcn/jpeg logical mask to physical mask
In reply to Stanley.Yang Changed from V1:
Remove amdgpu_ras_logical_mask_to_physical_mask due to GET_MASK provides same feature. Support convert VCN/JPEG logical mask to physical mask.
Signed-off-by Stanley.Yang <[email protected]>
Reviewed-by Tao Zhou <[email protected]>
Reviewed-by Hawking Zhang <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +4 -0
@@ -1698,6 +1698,10 @@ int psp_ras_trigger_error(struct psp_context *psp,case TA_RAS_BLOCK__SDMA : dev_mask =GET_MASK (SDMA0 , instance_mask);break ; +case TA_RAS_BLOCK__VCN : +case TA_RAS_BLOCK__JPEG : + dev_mask =GET_MASK (VCN , instance_mask); +break ;default : dev_mask = instance_mask;break ;
Signature · 1 line
2.17.1