[PATCH] drm/amd/amdgpu: Fix logic bug in fatal error handling
SHANMUGAM, SRINIVASAN
SRINIVASAN.SHANMUGAM at amd.com
Thu Mar 23 13:55:49 UTC 2023
[AMD Official Use Only - General]
Thanks a lot Luben!, much appreciate for your help!
-----Original Message-----
From: Tuikov, Luben <Luben.Tuikov at amd.com>
Sent: Thursday, March 23, 2023 7:24 PM
To: Koenig, Christian <Christian.Koenig at amd.com>; SHANMUGAM, SRINIVASAN <SRINIVASAN.SHANMUGAM at amd.com>; Deucher, Alexander <Alexander.Deucher at amd.com>; Limonciello, Mario <Mario.Limonciello at amd.com>; Zhang, Hawking <Hawking.Zhang at amd.com>
Cc: amd-gfx at lists.freedesktop.org
Subject: Re: [PATCH] drm/amd/amdgpu: Fix logic bug in fatal error handling
On 2023-03-23 09:29, Christian König wrote:
> Am 23.03.23 um 13:04 schrieb Srinivasan Shanmugam:
>> CC drivers/gpu/drm/amd/amdgpu/amdgpu_ras.o
>> drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c:2567:28: error: bitwise or with non-zero value always evaluates to true [-Werror,-Wtautological-bitwise-compare]
>> if (adev->ras_hw_enabled | AMDGPU_RAS_BLOCK__DF)
>> ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
>>
>> Presumably the author intended to test if AMDGPU_RAS_BLOCK__DF bit
>> was set if ras is enabled, so that's what I'm changing the code to.
>> Hopefully to do the right thing.
>
> That looks like a nice catch to me, but I don't really know the ras
> code that well.
>
> Hawking, Luben or whoever is more familiar with that should probably
> comment as well.
Thanks Christian--yeah, it looks like a typo. Fix is already committed into amd-staging-drm-next.
--
Regards,
Luben
More information about the amd-gfx
mailing list