Skip to contentSkip to conversation

mm-next: manual merge of the akpm/mm-unstable branch

PATCH David Hildenbrand (Arm) 3 participants 4 messages Nov 23 – Nov 24

Subsystems (3)
lore
Share & tools
lore

David Hildenbrand (Arm)

author reviewer
#0 lore raw

Hi,

today's mm-next merge of the akpm/mm-unstable branch tree got a conflict in:

include/linux/alloc_tag.h

between the commit:

dbbc5a3d50f9 mm: vmscan: tell direct reclaim the allocation is ALLOC_NOFRAGMENT

from the page_alloc/page_alloc/for-next branch and the commit:

2cc623f19566 mm/vmscan: move vmscan tracepoints to a local header

from the akpm/mm-unstable branch.

The conflict doesn't make any sense, because we're really touching something very unrelated. It's likely a merge config problem on my end.

I resolved the conflicts manually for now and shall investigate:

mm/vmscan.c +0 -0
index e94d58aa2626..1b3acbbfed15 100644
@@ -72,8 +72,7 @@

#include "swap.h"

#define CREATE_TRACE_POINTS
-<<<<<<< HEAD
-#include <trace/events/vmscan.h>
+#include "trace_vmscan.h"

 struct scan_control {
      /* How many pages shrink_list() should reclaim */
@@ -185,9 +184,6 @@ struct scan_control {
      /* for recording the reclaimed slab by now */
      struct reclaim_state reclaim_state;

};
-=======
-#include "trace_vmscan.h"
->>>>>>> akpm/mm-unstable

#ifdef ARCH_HAS_PREFETCHW
static inline void prefetchw_prev_lru_folio(struct folio *folio,

Signature · 3 lines
Cheers,

David
maintainer
#1 lore raw
Quoted 10 lines · On Mon, 23 Nov 2026 18:33:36 +0100 "David Hildenbrand (Arm)"…

today's mm-next merge of the akpm/mm-unstable branch tree got a conflict in:

include/linux/alloc_tag.h

between the commit:

dbbc5a3d50f9 mm: vmscan: tell direct reclaim the allocation is ALLOC_NOFRAGMENT

from the page_alloc/page_alloc/for-next branch and the commit:

Quoted 8 lines

2cc623f19566 mm/vmscan: move vmscan tracepoints to a local header

from the akpm/mm-unstable branch.

The conflict doesn't make any sense, because we're really touching something very unrelated. It's likely a merge config problem on my end.

I resolved the conflicts manually for now and shall investigate:

Ridong's series "mm/vmscan: move tracepoints to mm/ and add MGLRU tracepoints" is large and contains a lot of optional code movement.

So I think at this time we should drop it and ask Ridong for a much smaller and tighter patch[set] which just adds those MGLRU tracepoints. wdyt?

author reviewer
#2 lore raw
Quoted 12 lines · Andrew Morton
Quoted 10 lines · On Mon, 23 Nov 2026 18:33:36 +0100 "David Hildenbrand (Arm)"…

today's mm-next merge of the akpm/mm-unstable branch tree got a conflict in:

include/linux/alloc_tag.h

between the commit:

dbbc5a3d50f9 mm: vmscan: tell direct reclaim the allocation is ALLOC_NOFRAGMENT

from the page_alloc/page_alloc/for-next branch and the commit:

Quoted 8 lines
Quoted 8 lines

2cc623f19566 mm/vmscan: move vmscan tracepoints to a local header

from the akpm/mm-unstable branch.

The conflict doesn't make any sense, because we're really touching something very unrelated. It's likely a merge config problem on my end.

I resolved the conflicts manually for now and shall investigate:

Scrap the above, it's more complicated. I managed to confuse myself ... and I learned just the hard way the limitations of git rerere :)

The following would be the right email:

----------

Hi,

today's mm-next merge of the akpm/mm-unstable branch tree got a conflict in:

mm/vmscan.c

between the commits:

dbbc5a3d50f9 mm: vmscan: tell direct reclaim the allocation is ALLOC_NOFRAGMENT

from the page_alloc/page_alloc/for-next branch and the commit:

2cc623f19566 mm/vmscan: move vmscan tracepoints to a local header b87fab0ca9ce mm/vmscan: move struct scan_control to a dedicated header

from the akpm/mm-unstable branch.

I resolved the conflicts manually:

mm/vmscan.c +0 -115
index e94d58aa2626..672b339c7bc5 100644
@@ -72,122 +72,7 @@
 #include "swap.h"
 
 #define CREATE_TRACE_POINTS
-<<<<<<< HEAD
-#include <trace/events/vmscan.h>
-
-struct scan_control {
-     /* How many pages shrink_list() should reclaim */
-     unsigned long nr_to_reclaim;
-
-     /*
-      * Nodemask of nodes allowed by the caller. If NULL, all nodes
-      * are scanned.
-      */
-     const nodemask_t *nodemask;
-
-     /*
-      * The memory cgroup that hit its limit and as a result is the
-      * primary target of this reclaim invocation.
-      */
-     struct mem_cgroup *target_mem_cgroup;
-
-     /*
-      * Scan pressure balancing between anon and file LRUs
-      */
-     unsigned long   anon_cost;
-     unsigned long   file_cost;
-
-     /* Swappiness value for proactive reclaim. Always use sc_swappiness()! */
-     int *proactive_swappiness;
-
-     /* Can active folios be deactivated as part of reclaim? */
-#define DEACTIVATE_ANON 1
-#define DEACTIVATE_FILE 2
-     unsigned int may_deactivate:2;
-     unsigned int force_deactivate:1;
-     unsigned int skipped_deactivate:1;
-
-     /* zone_reclaim_mode, boost reclaim */
-     unsigned int may_writepage:1;
-
-     /* zone_reclaim_mode */
-     unsigned int may_unmap:1;
-
-     /* zone_reclaim_mode, boost reclaim, cgroup restrictions */
-     unsigned int may_swap:1;
-
-     /* Not allow cache_trim_mode to be turned on as part of reclaim? */
-     unsigned int no_cache_trim_mode:1;
-
-     /* Has cache_trim_mode failed at least once? */
-     unsigned int cache_trim_mode_failed:1;
-
-     /* Proactive reclaim invoked by userspace */
-     unsigned int proactive:1;
-
-     /*
-      * Cgroup memory below memory.low is protected as long as we
-      * don't threaten to OOM. If any cgroup is reclaimed at
-      * reduced force or passed over entirely due to its memory.low
-      * setting (memcg_low_skipped), and nothing is reclaimed as a
-      * result, then go back for one more cycle that reclaims the protected
-      * memory (memcg_low_reclaim) to avert OOM.
-      */
-     unsigned int memcg_low_reclaim:1;
-     unsigned int memcg_low_skipped:1;
-
-     /* Shared cgroup tree walk failed, rescan the whole tree */
-     unsigned int memcg_full_walk:1;
-
-     unsigned int hibernation_mode:1;
-
-     /* One of the zones is ready for compaction */
-     unsigned int compaction_ready:1;
-
-     /* The allocation may not steal from other migratetypes' blocks */
-     unsigned int nofragment:1;
-
-     /* There is easily reclaimable cold cache in the current node */
-     unsigned int cache_trim_mode:1;
-
-     /* The file folios on the current node are dangerously low */
-     unsigned int file_is_tiny:1;
-
-     /* Always discard instead of demoting to lower tier memory */
-     unsigned int no_demotion:1;
-
-     /* Allocation order */
-     s8 order;
-
-     /* Scan (total_size >> priority) pages at once */
-     s8 priority;
-
-     /* The highest zone to isolate folios for reclaim from */
-     s8 reclaim_idx;
-
-     /* This context's GFP mask */
-     gfp_t gfp_mask;
-
-     /* Incremented by the number of inactive pages that were scanned */
-     unsigned long nr_scanned;
-
-     /* Number of pages freed so far during a call to shrink_zones() */
-     unsigned long nr_reclaimed;
-
-     struct {
-             unsigned int dirty;
-             unsigned int congested;
-             unsigned int writeback;
-             unsigned int immediate;
-             unsigned int taken;
-     } nr;
-
-     /* for recording the reclaimed slab by now */
-     struct reclaim_state reclaim_state;
-};
-=======
 #include "trace_vmscan.h"
->>>>>>> akpm/mm-unstable
 
 #ifdef ARCH_HAS_PREFETCHW
 static inline void prefetchw_prev_lru_folio(struct folio *folio,
mm/vmscan.h +3 -0
index c2cea36289f3..6a8f5981235f 100644
@@ -77,6 +77,9 @@ struct scan_control {
      /* One of the zones is ready for compaction */
      unsigned int compaction_ready:1;
 
+     /* The allocation may not steal from other migratetypes' blocks */
+     unsigned int nofragment:1;
+
      /* There is easily reclaimable cold cache in the current node */
      unsigned int cache_trim_mode:1;
 

---

Quoted 3 lines

Ridong's series "mm/vmscan: move tracepoints to mm/ and add MGLRU tracepoints" is large and contains a lot of optional code movement.

Yes, the move to vmscan.h is the real problem.

Quoted 4 lines

So I think at this time we should drop it and ask Ridong for a much smaller and tighter patch[set] which just adds those MGLRU tracepoints. wdyt?

It's a good learning experience on my end ;) I don't care carrying the fixup forward.

We'll just have to let Linus know about it.

Later, for changes that go through my tree (PULL requests from other components to me), I can just fix that up when merging and nobody will ever now.

Signature · 3 lines
Cheers,

David
#3 lore raw
Quoted 17 lines · David Hildenbrand (Arm)

On 11/23/26 19:34, Andrew Morton wrote:

mm/vmscan.h +3 -1
@@ -77,6 +77,9 @@ struct scan_control {
      /* One of the zones is ready for compaction */
      unsigned int compaction_ready:1;
 
+     /* The allocation may not steal from other migratetypes' blocks */
+     unsigned int nofragment:1;
+
      /* There is easily reclaimable cold cache in the current node */
      unsigned int cache_trim_mode:1;
 
---
Quoted 3 lines
Quoted 4 lines
Quoted 2 lines

Ridong's series "mm/vmscan: move tracepoints to mm/ and add MGLRU tracepoints" is large and contains a lot of optional code movement.

Yes, the move to vmscan.h is the real problem.

I guess this one not optional for the series if the structure needs to be visible to multiple .c files.

Quoted 9 lines
Quoted 4 lines

So I think at this time we should drop it and ask Ridong for a much smaller and tighter patch[set] which just adds those MGLRU tracepoints. wdyt?

It's a good learning experience on my end ;) I don't care carrying the fixup forward.

We'll just have to let Linus know about it.

Yeah Linus always says merge conflicts are fine so I'd only start dropping things when there's something more serious e.g. a semantic conflict. We need to learn to live with this.

Thanks!

Quoted 3 lines

Later, for changes that go through my tree (PULL requests from other components to me), I can just fix that up when merging and nobody will ever now.