The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Pratyush Yadav <pratyush@kernel.org>
To: mdshahid03@gmail.com
Cc: Andrew Morton <akpm@linux-foundation.org>,
	 Baoquan He <baoquan.he@linux.dev>,
	 Mike Rapoport <rppt@kernel.org>,
	 Pasha Tatashin <pasha.tatashin@soleen.com>,
	 Pratyush Yadav <pratyush@kernel.org>,
	 Dave Young <ruirui.yang@linux.dev>,
	 kexec@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dm: crash dump: remove redundant NULL check before kvfree()
Date: Fri, 03 Jul 2026 14:03:32 +0200	[thread overview]
Message-ID: <2vxzbjcogu0b.fsf@kernel.org> (raw)
In-Reply-To: <20260703112642.65498-1-mdshahid03@gmail.com> (mdshahid's message of "Fri, 3 Jul 2026 16:56:42 +0530")

On Fri, Jul 03 2026, mdshahid03@gmail.com wrote:

> From: Mohammad Shahid <mdshahid03@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@gmail.com>

Reviewed-by: Pratyush Yadav <pratyush@kernel.org>

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

[...]

-- 
Regards,
Pratyush Yadav

  reply	other threads:[~2026-07-03 12:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-03 11:26 [PATCH] dm: crash dump: remove redundant NULL check before kvfree() mdshahid03
2026-07-03 12:03 ` Pratyush Yadav [this message]
2026-07-03 13:28   ` Coiby Xu
2026-07-03 13:44     ` Pratyush Yadav

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2vxzbjcogu0b.fsf@kernel.org \
    --to=pratyush@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=baoquan.he@linux.dev \
    --cc=kexec@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mdshahid03@gmail.com \
    --cc=pasha.tatashin@soleen.com \
    --cc=rppt@kernel.org \
    --cc=ruirui.yang@linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox