On 1/19/26 09:53, Tiezhu Yang wrote:
> On 2026/1/16 下午6:03, Christian König wrote:
>> On 1/16/26 02:20, Tiezhu Yang wrote:
>>> On 2026/1/15 下午9:47, Christian König wrote:
>>>> On 1/15/26 02:28, Tiezhu Yang wrote:
>>>>> Currently, there are many Call Traces when booting kernel on LoongArch,
>>>>> here are the trimmed kernel log messages:
>>>>>
>>>>>     amdgpu 0000:07:00.0: amdgpu: hw_init of IP block <gfx_v6_0> failed 
>>>>> -110
>>>>>     amdgpu 0000:07:00.0: amdgpu: amdgpu_device_ip_init failed
>>>>>     amdgpu 0000:07:00.0: amdgpu: Fatal error during GPU init
>>>>>     amdgpu 0000:07:00.0: amdgpu: amdgpu: finishing device.
>>>>>     ------------[ cut here ]------------
>>>>>     WARNING: drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c:639 at 
>>>>> amdgpu_irq_put+0xb0/0x140 [amdgpu], CPU#0: kworker/0:0/9
>>>>>     ...
>>>>>     Call Trace:
> 
> ...
> 
>> The warning can basically only be triggered by two conditions:
>> 1. A fatal problem while loading the driver and the error handling is not 
>> 100% clean.
>> 2. A driver coding error.
>>
>> And we really need to catch all of those, so there is no real rational to 
>> limit the warning.
>>
>> I mean when you run into any of those they should potentially be fixed at 
>> some point.
> 
> I did the following change and it can fix the problem, given that I am
> not familiar with amdgpu driver, could you please check it? If it is OK,
> I will send a formal patch later.
> 
> ----->8-----
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c 
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
> index 8112ffc85995..ac19565e7c45 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
> @@ -138,6 +138,9 @@ void amdgpu_irq_disable_all(struct amdgpu_device *adev)
>                         if (!src || !src->funcs->set || !src->num_types)
>                                 continue;
> 
> +                       kfree(src->enabled_types);
> +                       src->enabled_types = NULL;
> +

Mhm, I need to double check that but that looks like not such a bad idea of 
hand.

Christian.

>                         for (k = 0; k < src->num_types; ++k) {
>                                 r = src->funcs->set(adev, src, k,
> 
> AMDGPU_IRQ_STATE_DISABLE);
> 
> Thanks,
> Tiezhu
> 

Reply via email to