From: Bartosz Golaszewski <brgl@bgdev.pl>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Christoph Lameter <cl@linux.com>,
Pekka Enberg <penberg@kernel.org>,
David Rientjes <rientjes@google.com>,
Joonsoo Kim <iamjoonsoo.kim@lge.com>,
Andrew Morton <akpm@linux-foundation.org>,
Vlastimil Babka <vbabka@suse.cz>,
Roman Gushchin <roman.gushchin@linux.dev>,
Hyeonggon Yoo <42.hyeyoo@gmail.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Subject: Re: [PATCH] slab: drop unneeded NULL-pointer check in kfree auto cleanup
Date: Tue, 12 Sep 2023 13:26:05 +0200 [thread overview]
Message-ID: <CAMRc=McXAmOhN-vqCjz72uPB4V0Srw2czWYiSpVH7mBfBCQJpg@mail.gmail.com> (raw)
In-Reply-To: <20230912104258.GA12405@noisy.programming.kicks-ass.net>
On Tue, Sep 12, 2023 at 12:43 PM Peter Zijlstra <peterz@infradead.org> wrote:
>
> On Tue, Sep 12, 2023 at 10:26:43AM +0200, Bartosz Golaszewski wrote:
> > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >
> > kfree() already accepts and silently ignores NULL-pointers, there's no
> > need to check it when running the auto cleanup routine.
>
> There is, because now the compiler can't help you anymore. Also see:
>
> https://lkml.kernel.org/r/169451499208.27769.5856056754166699857.tip-bot2@tip-bot2
Makes sense, thanks!
Bart
prev parent reply other threads:[~2023-09-12 11:26 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-12 8:26 Bartosz Golaszewski
2023-09-12 10:42 ` Peter Zijlstra
2023-09-12 11:26 ` Bartosz Golaszewski [this message]
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='CAMRc=McXAmOhN-vqCjz72uPB4V0Srw2czWYiSpVH7mBfBCQJpg@mail.gmail.com' \
--to=brgl@bgdev.pl \
--cc=42.hyeyoo@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=bartosz.golaszewski@linaro.org \
--cc=cl@linux.com \
--cc=iamjoonsoo.kim@lge.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=penberg@kernel.org \
--cc=peterz@infradead.org \
--cc=rientjes@google.com \
--cc=roman.gushchin@linux.dev \
--cc=vbabka@suse.cz \
/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