On 7/1/26 18:17, Timur Kristóf wrote:
> The retry CAM can filter interrupts which occur repeatedly,
> such as page fault interrupts when retry faults are enabled.
> This makes processing those interrupts much more efficient,
> because the CPU won't have to deal with processing the same
> interrupt repeatedly.
> 
> Signed-off-by: Timur Kristóf <[email protected]>

Reviewed-by: Christian König <[email protected]>

> ---
>  drivers/gpu/drm/amd/amdgpu/ih_v6_0.c | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/ih_v6_0.c 
> b/drivers/gpu/drm/amd/amdgpu/ih_v6_0.c
> index a97c85b0cb99..bbe399f9e233 100644
> --- a/drivers/gpu/drm/amd/amdgpu/ih_v6_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/ih_v6_0.c
> @@ -397,6 +397,16 @@ static int ih_v6_0_irq_init(struct amdgpu_device *adev)
>  
>       pci_set_master(adev->pdev);
>  
> +     if (!(adev->flags & AMD_IS_APU)) {
> +             /* Enable IH Retry CAM */
> +             tmp = RREG32_SOC15(OSSSYS, 0, regIH_RETRY_INT_CAM_CNTL);
> +             tmp = REG_SET_FIELD(tmp, IH_RETRY_INT_CAM_CNTL, ENABLE, 1);
> +             tmp = REG_SET_FIELD(tmp, IH_RETRY_INT_CAM_CNTL, CAM_SIZE, 0xF);
> +             WREG32_SOC15(OSSSYS, 0, regIH_RETRY_INT_CAM_CNTL, tmp);
> +
> +             adev->irq.retry_cam_enabled = true;
> +     }
> +
>       /* enable interrupts */
>       ret = ih_v6_0_toggle_interrupts(adev, true);
>       if (ret)

Reply via email to