Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-25 Thread philip yang
On 2021-11-25 2:03 a.m., Christian König wrote: Am 24.11.21 um 21:20 schrieb Felix Kuehling: Am 2021-11-24 um 10:23 a.m. schrieb philip yang:      #define amdgpu_ih_get_wptr(adev, ih)

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread Christian König
Am 24.11.21 um 23:52 schrieb philip yang: On 2021-11-24 10:33 a.m., Christian König wrote: Am 24.11.21 um 16:23 schrieb philip yang: [SNIP]   +/** + * amdgpu_ih_process1 - interrupt handler work for IH ring1 + * + * @adev: amdgpu_device pointer + * @ih: ih ring to process + * + * Interrupt

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread Christian König
Am 24.11.21 um 21:20 schrieb Felix Kuehling: Am 2021-11-24 um 10:23 a.m. schrieb philip yang:     #define amdgpu_ih_get_wptr(adev, ih) (adev)->irq.ih_funcs->get_wptr((adev), (ih))   #define amdgpu_ih_decode_iv(adev, iv) \   (adev)->irq.ih_funcs->decode_iv((adev), (ih), (iv)) +#define amdg

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread philip yang
On 2021-11-24 10:33 a.m., Christian König wrote: Am 24.11.21 um 16:23 schrieb philip yang: [SNIP]   +/** + * amdgpu_ih_process1 - interrupt handler work for IH ring1

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread Felix Kuehling
Am 2021-11-24 um 10:23 a.m. schrieb philip yang: >>>     #define amdgpu_ih_get_wptr(adev, ih) >>> (adev)->irq.ih_funcs->get_wptr((adev), (ih)) >>>   #define amdgpu_ih_decode_iv(adev, iv) \ >>>   (adev)->irq.ih_funcs->decode_iv((adev), (ih), (iv)) >>> +#define amdgpu_ih_decode_iv_ts(adev, ih,

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread Christian König
Am 24.11.21 um 16:23 schrieb philip yang: [SNIP]   +/** + * amdgpu_ih_process1 - interrupt handler work for IH ring1 + * + * @adev: amdgpu_device pointer + * @ih: ih ring to process + * + * Interrupt handler of IH ring1, walk the IH ring1. + * Returns irq process return code. + */ +int amdgpu

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread philip yang
On 2021-11-24 4:37 a.m., Christian König wrote: Am 23.11.21 um 20:22 schrieb Philip Yang: IH ring1 is used to process GPU retry fault, overflow is enabled to drain retry fault because we want receive other interrupts while

Re: [PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-24 Thread Christian König
Am 23.11.21 um 20:22 schrieb Philip Yang: IH ring1 is used to process GPU retry fault, overflow is enabled to drain retry fault because we want receive other interrupts while handling retry fault to recover range. There is no overflow flag set when wptr pass rptr. Use timestamp of rptr and wptr t

[PATCH v5] drm/amdgpu: handle IH ring1 overflow

2021-11-23 Thread Philip Yang
IH ring1 is used to process GPU retry fault, overflow is enabled to drain retry fault because we want receive other interrupts while handling retry fault to recover range. There is no overflow flag set when wptr pass rptr. Use timestamp of rptr and wptr to handle overflow and drain retry fault. Ad