All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mel Gorman <mgorman@suse.de>
To: David Hildenbrand <david@redhat.com>
Cc: Michal Hocko <mhocko@suse.com>,
	Patrick Daly <quic_pdaly@quicinc.com>,
	linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org,
	Juergen Gross <jgross@suse.com>
Subject: Re: Race condition in build_all_zonelists() when offlining movable zone
Date: Tue, 23 Aug 2022 12:09:46 +0100	[thread overview]
Message-ID: <20220823110946.o3eawk3kghaykcim@suse.de> (raw)
In-Reply-To: <0fc01e47-51f3-baf7-2d46-72291422f695@redhat.com>

On Tue, Aug 23, 2022 at 12:34:09PM +0200, David Hildenbrand wrote:
> > @@ -6553,7 +6576,7 @@ static void __build_all_zonelists(void *data)
> >  #endif
> >  	}
> >  
> > -	spin_unlock(&lock);
> > +	write_sequnlock(&zonelist_update_seq);
> >  }
> >  
> >  static noinline void __init
> > 
> 
> LGTM. The "retry_cpuset" label might deserve a better name now.
> 

Good point ...  "restart"?

> Would
> 
> Fixes: 6aa303defb74 ("mm, vmscan: only allocate and reclaim from zones
> with pages managed by the buddy allocator")
> 
> be correct?
> 

Not specifically because the bug is due to a zone being completely removed
resulting in a rebuild. This race probably existed ever since memory
hotremove could theoritically remove a complete zone. A Cc: Stable would
be appropriate as it'll apply with fuzz back to at least 5.4.210 but beyond
that, it should be driven by a specific bug report showing that hot-remove
of a full zone was possible and triggered the race.

-- 
Mel Gorman
SUSE Labs

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  parent reply	other threads:[~2022-08-23 11:11 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-17  3:42 Race condition in build_all_zonelists() when offlining movable zone Patrick Daly
2022-08-17  3:42 ` Patrick Daly
2022-08-17  6:38 ` Michal Hocko
2022-08-17  6:59   ` Michal Hocko
2022-08-17 10:40     ` Mel Gorman
2022-08-17 10:54       ` Michal Hocko
2022-08-17 11:26         ` Mel Gorman
2022-08-19  2:11           ` Patrick Daly
2022-08-19  2:11             ` Patrick Daly
2022-08-22 20:18           ` Patrick Daly
2022-08-22 20:18             ` Patrick Daly
2022-08-23  6:36       ` David Hildenbrand
2022-08-23  6:36         ` David Hildenbrand
2022-08-23  8:33         ` Mel Gorman
2022-08-23  8:52           ` David Hildenbrand
2022-08-23  8:52             ` David Hildenbrand
2022-08-23  9:49             ` Mel Gorman
2022-08-23  9:49               ` Mel Gorman
2022-08-23 10:34               ` David Hildenbrand
2022-08-23 10:34                 ` David Hildenbrand
2022-08-23 10:57                 ` Michal Hocko
2022-08-23 11:09                 ` Mel Gorman [this message]
2022-08-23 12:18                   ` Michal Hocko
2022-08-23 12:18                     ` Michal Hocko
2022-08-23 12:58                     ` Mel Gorman
2022-08-23 13:25                       ` Michal Hocko
2022-08-23 13:25                         ` Michal Hocko
2022-08-23 13:50                         ` David Hildenbrand
2022-08-23 13:50                           ` David Hildenbrand
2022-08-23 13:57                           ` Michal Hocko
2022-08-23 13:57                             ` Michal Hocko
2022-08-23 15:14                             ` Mel Gorman
2022-08-23 15:14                               ` Mel Gorman
2022-08-23 15:38                               ` Michal Hocko
2022-08-23 15:38                                 ` Michal Hocko
2022-08-23 15:51                                 ` David Hildenbrand
2022-08-23 15:51                                   ` David Hildenbrand
2022-08-24  9:45                                   ` Mel Gorman
2022-08-24  9:45                                     ` Mel Gorman

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=20220823110946.o3eawk3kghaykcim@suse.de \
    --to=mgorman@suse.de \
    --cc=david@redhat.com \
    --cc=jgross@suse.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@suse.com \
    --cc=quic_pdaly@quicinc.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.