Hi all, On Mon, 28 Oct 2024 11:10:58 +1100 Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx> wrote: > > Today's linux-next merge of the arm64 tree got a conflict in: > > include/linux/mm.h > > between commit: > > e87ec503cf2e ("mm/codetag: uninline and move pgalloc_tag_copy and pgalloc_tag_split") > > from the mm-unstable branch of the mm tree and commit: > > 91e102e79740 ("prctl: arch-agnostic prctl for shadow stack") > > from the arm64 tree. > > I fixed it up (see below) and can carry the fix as necessary. This > is now fixed as far as linux-next is concerned, but any non trivial > conflicts should be mentioned to your upstream maintainer when your tree > is submitted for merging. You may also want to consider cooperating > with the maintainer of the conflicting tree to minimise any particularly > complex conflicts. > > -- > Cheers, > Stephen Rothwell > > diff --cc include/linux/mm.h > index 086ba524d3ba,8852c39c7695..000000000000 > --- a/include/linux/mm.h > +++ b/include/linux/mm.h > @@@ -4166,4 -4174,65 +4178,8 @@@ static inline int do_mseal(unsigned lon > } > #endif > > -#ifdef CONFIG_MEM_ALLOC_PROFILING > -static inline void pgalloc_tag_split(struct folio *folio, int old_order, int new_order) > -{ > - int i; > - struct alloc_tag *tag; > - unsigned int nr_pages = 1 << new_order; > - > - if (!mem_alloc_profiling_enabled()) > - return; > - > - tag = pgalloc_tag_get(&folio->page); > - if (!tag) > - return; > - > - for (i = nr_pages; i < (1 << old_order); i += nr_pages) { > - union codetag_ref *ref = get_page_tag_ref(folio_page(folio, i)); > - > - if (ref) { > - /* Set new reference to point to the original tag */ > - alloc_tag_ref_set(ref, tag); > - put_page_tag_ref(ref); > - } > - } > -} > - > -static inline void pgalloc_tag_copy(struct folio *new, struct folio *old) > -{ > - struct alloc_tag *tag; > - union codetag_ref *ref; > - > - tag = pgalloc_tag_get(&old->page); > - if (!tag) > - return; > - > - ref = get_page_tag_ref(&new->page); > - if (!ref) > - return; > - > - /* Clear the old ref to the original allocation tag. */ > - clear_page_tag_ref(&old->page); > - /* Decrement the counters of the tag on get_new_folio. */ > - alloc_tag_sub(ref, folio_nr_pages(new)); > - > - __alloc_tag_ref_set(ref, tag); > - > - put_page_tag_ref(ref); > -} > -#else /* !CONFIG_MEM_ALLOC_PROFILING */ > -static inline void pgalloc_tag_split(struct folio *folio, int old_order, int new_order) > -{ > -} > - > -static inline void pgalloc_tag_copy(struct folio *new, struct folio *old) > -{ > -} > -#endif /* CONFIG_MEM_ALLOC_PROFILING */ > - > + int arch_get_shadow_stack_status(struct task_struct *t, unsigned long __user *status); > + int arch_set_shadow_stack_status(struct task_struct *t, unsigned long status); > + int arch_lock_shadow_stack_status(struct task_struct *t, unsigned long status); > + > #endif /* _LINUX_MM_H */ This is now a conflict between the mm-stable tree and Linus' tree. -- Cheers, Stephen Rothwell
Attachment:
pgpcoGJXeefKt.pgp
Description: OpenPGP digital signature