[PATCH 2/3] mm: kmemleak: drop wrong comment

Luiz Capitulino posted 3 patches 9 months, 2 weeks ago
[PATCH 2/3] mm: kmemleak: drop wrong comment
Posted by Luiz Capitulino 9 months, 2 weeks ago
Newly created objects have object->count == 0, so the comment is
incorrect. Just drop it.

Signed-off-by: Luiz Capitulino <luizcap@redhat.com>
---
 mm/kmemleak.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/mm/kmemleak.c b/mm/kmemleak.c
index e6df94c7b032..06baa3475252 100644
--- a/mm/kmemleak.c
+++ b/mm/kmemleak.c
@@ -322,8 +322,6 @@ static void hex_dump_object(struct seq_file *seq,
  *		sufficient references to it (count >= min_count)
  * - black - ignore, it doesn't contain references (e.g. text section)
  *		(min_count == -1). No function defined for this color.
- * Newly created objects don't have any color assigned (object->count == -1)
- * before the next memory scan when they become white.
  */
 static bool color_white(const struct kmemleak_object *object)
 {
-- 
2.49.0
Re: [PATCH 2/3] mm: kmemleak: drop wrong comment
Posted by Catalin Marinas 9 months, 1 week ago
On Wed, Apr 30, 2025 at 04:59:46PM -0400, Luiz Capitulino wrote:
> Newly created objects have object->count == 0, so the comment is
> incorrect. Just drop it.
> 
> Signed-off-by: Luiz Capitulino <luizcap@redhat.com>

Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>