[PATCH] dm: crash dump: remove redundant NULL check before kvfree()
Pratyush Yadav
pratyush at kernel.org
Fri Jul 3 06:44:04 PDT 2026
On Fri, Jul 03 2026, Coiby Xu wrote:
> On Fri, Jul 03, 2026 at 02:03:32PM +0200, Pratyush Yadav wrote:
>>On Fri, Jul 03 2026, mdshahid03 at gmail.com wrote:
>>
>>> From: Mohammad Shahid <mdshahid03 at gmail.com>
>>>
>>> kvfree() safely handles NULL pointers, so the explicit NULL check
>>> before calling kvfree() is unnecessary.
>>>
>>> This issue was reported by ifnullfree.cocci.
>>>
>>> Signed-off-by: Mohammad Shahid <mdshahid03 at gmail.com>
>>
>>Reviewed-by: Pratyush Yadav <pratyush at kernel.org>
>
> Hi Pratyush,
>
> Thanks for reviewing this patch!
>
>>
>>BTW, Sashiko [0] pointed out a bunch of problems in the surrounding code,
>>and they seem to look legit. If you're interested, help in fixing them
>>would be much appreciated.
>>
>>[0] https://sashiko.dev/#/patchset/20260703112642.65498-1-mdshahid03@gmail.com
>
> I'll send a new version of
> https://lore.kernel.org/kexec/20260501234342.2518281-1-coiby.xu@gmail.com/
> soon which can address Sashiko's feedback scrutinized by Sourabh.
Oh, great. Thanks!
--
Regards,
Pratyush Yadav
More information about the kexec
mailing list