From: "Vlastimil Babka (SUSE)" <vbabka@kernel.org>
To: kernel test robot <lkp@intel.com>,
"Lorenzo Stoakes (ARM)" <ljs@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev,
David Hildenbrand <david@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Linux Memory Management List <linux-mm@kvack.org>,
mm-commits@vger.kernel.org,
Suren Baghdasaryan <surenb@google.com>
Subject: Re: [akpm-mm:mm-unstable 33/408] mm/mmap_lock.c:572:14-33: WARNING: atomic_dec_and_test variation before object free at line 574.
Date: Wed, 25 Nov 2026 11:56:45 +0100 [thread overview]
Message-ID: <cbd03e3c-94ce-4eeb-92d4-45dbee4a098d@kernel.org> (raw)
In-Reply-To: <20261125102827.xQ94ZCi1-lkp@intel.com>
On 11/25/26 10:34, kernel test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-unstable
> head: c8117bff684306f5c1f959d055cc2b24dd67b1eb
> commit: 549e0b6c9835de4cc4e8e4a56459ef09febfc2f7 [33/408] mm/vma: drop mm asynchronously in vma_start_read()
> config: sh-randconfig-r2100-20261125 (https://download.01.org/0day-ci/archive/20261125/20261125102827.xQ94ZCi1-lkp@intel.com/config)
> compiler: sh4-linux-gcc (GCC) 12.5.0
>
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes: https://lore.kernel.org/oe-kbuild-all/20261125102827.xQ94ZCi1-lkp@intel.com/
>
> cocci warnings: (new ones prefixed by >>)
>>> mm/mmap_lock.c:572:14-33: WARNING: atomic_dec_and_test variation before object free at line 574.
So AFAIU this is a suggestion to use refcount_t instead of atomic_t in new
code, but this is a move of an existing code and intended to be a minimal
fix. So we can ignore.
(this is intended for saving Lorenzo a reply, let's see if he can resist :)
> vim +572 mm/mmap_lock.c
>
> 569
> 570 void mmdrop_async(struct mm_struct *mm)
> 571 {
> > 572 if (unlikely(atomic_dec_and_test(&mm->mm_count))) {
> 573 INIT_WORK(&mm->async_put_work, mmdrop_async_fn);
> > 574 schedule_work(&mm->async_put_work);
> 575 }
> 576 }
> 577
>
prev parent reply other threads:[~2026-11-25 10:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-25 9:34 [akpm-mm:mm-unstable 33/408] mm/mmap_lock.c:572:14-33: WARNING: atomic_dec_and_test variation before object free at line 574 kernel test robot
2026-11-25 10:56 ` Vlastimil Babka (SUSE) [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=cbd03e3c-94ce-4eeb-92d4-45dbee4a098d@kernel.org \
--to=vbabka@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=david@kernel.org \
--cc=linux-mm@kvack.org \
--cc=ljs@kernel.org \
--cc=lkp@intel.com \
--cc=mm-commits@vger.kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=surenb@google.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.